Motor controller in an I2C system
Posted: Sat Mar 05, 2022 10:53 pm
Hello,
I have tried to use a Roboclaw 2x60A or 2x7A in a project with three Arduinos. The Arduinos are communicating over I2C. If I connect the Roboclaw to an Arduino and send a command over serial TX/GND to S1/GND of the Roboclaw, the I2C blocks and does not works until a reset of the master Arduino.
I have tried to connect only the Roboclaw without motors and send the commands. This works without problems. But when I connect the motors and they are moving, the I2C blocks. With different motors, I have also different blockings on the I2C. Sometimes slower, sometimes faster. It is really not a problem of the code, it is a problem with the motor controller I guess. Only the motor controller connected works, but when the motors are connected to them and move to the commands that are sending, I have to reset the master Arduino.
It is like the motors will send back a signal that destroys the I2C signal and make it blocking.
Are any shematics available from the Roboclaws to see how they works or any known issues about that? Do you have tested to use a Roboclaw motor controller in an I2C communicating system with Arduinos? Could also only be a I2C display connected to one Arduino and the motor controller connected over serial and it will block the Arduino until resetting it!
Regards
Stef
I have tried to use a Roboclaw 2x60A or 2x7A in a project with three Arduinos. The Arduinos are communicating over I2C. If I connect the Roboclaw to an Arduino and send a command over serial TX/GND to S1/GND of the Roboclaw, the I2C blocks and does not works until a reset of the master Arduino.
I have tried to connect only the Roboclaw without motors and send the commands. This works without problems. But when I connect the motors and they are moving, the I2C blocks. With different motors, I have also different blockings on the I2C. Sometimes slower, sometimes faster. It is really not a problem of the code, it is a problem with the motor controller I guess. Only the motor controller connected works, but when the motors are connected to them and move to the commands that are sending, I have to reset the master Arduino.
It is like the motors will send back a signal that destroys the I2C signal and make it blocking.
Are any shematics available from the Roboclaws to see how they works or any known issues about that? Do you have tested to use a Roboclaw motor controller in an I2C communicating system with Arduinos? Could also only be a I2C display connected to one Arduino and the motor controller connected over serial and it will block the Arduino until resetting it!
Regards
Stef