Timeline for Arduino UNO(master read) + NANO(slave write) i2c buttons+stepper
Current License: CC BY-SA 3.0
7 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Mar 16, 2018 at 21:34 | comment | added | Jot | You could add a check in the receiveEvent if the howMany == 1. Since a single byte is expected it should be 1. Calling the motor.step from an interrupt function might cause problems. If possible, you should do such things in the Arduino loop(). Don't fill the i2c bus with 100% load. Add a delay in the master Arduino. Start at least with 100 ms. Work cleaner! with the code and explanation. You have now called the master the slave and the other way around. | |
Mar 16, 2018 at 21:25 | comment | added | Róbert Pollák | When I used it without i2c bus, only with the shield and one button(because only pin D2 is free on that shield and analog pins) it was working okay, but now, with this setup, its not working. | |
Mar 16, 2018 at 21:21 | comment | added | Jot | That is an other problem. Try to make a small test sketch (without using the i2c bus and the other board) to test it. It means there not enough power or the wrong driver or electrical noise that backfires into the arduino board. You know that the motor shield that you are using is the worst, cheapest, weakest motor shield there is? It can drive only a very, very, very small toy motor. Maybe not even that. | |
Mar 16, 2018 at 21:16 | history | edited | Jot | CC BY-SA 3.0 |
added 185 characters in body
|
Mar 16, 2018 at 21:15 | comment | added | Róbert Pollák | Avoid comments like "+1" or "thanks", but still, thank you @Jot. Anyways, I managed to write a code that's running, but the steppers are just vibrating, not rotating. Any solution for it? | |
Mar 16, 2018 at 21:12 | vote | accept | Róbert Pollák | ||
Mar 16, 2018 at 21:07 | history | answered | Jot | CC BY-SA 3.0 |