Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Connection problem using XBee on Arduino with SoftPWM library

I am trying to control 4 DC motors with Flyduino-A 12 Servo Controller(SKU:DFR0136) by comunicating with XBee module. There was no problem when I compiled the program with functions like delayMilisecunds and digitalWrite. The problem was when I put the calculating of the motors voltages on the arduino controller because the delay is larger than defined. Then I found the Arduino/Wiring SoftPWM Library and implemented it in the code. When I tried to run it, the message appears:

Unable to sync with device; possible link problem or link software version mismatch such as hydro rosserial_python with groovy Arduino

I suspect the problem being in interrupt sequencing because ROS on XBee uses interrupts to refresh the variables in my code and SoftPWM library uses interrupts with timer2 to calculate the exact value on the motors at all time. Can I set the priority list on these to variables and is that even the problem here?