I’m trying to command 3 odrives over a wired network (ethernet). Currently my plan is to have a raspberry pi acting as an intermediary to translate the messages into serial that can then be sent to the odrives. The only issue is that the rpi only has one serial port. I want to avoid having multiple raspberry pis due to issues involved with synchronising motors controlled by different rpis. I’m thinking of two potential solutions:
-
Find some way of multiplexing the 3 signals onto 1 serial port. Other controllers like the RoboClaw accomplish this by having open collector outputs on their TX lines. Then the TX and RX lines of multiple motor controllers can be tied together and the controllers can be addressed independently using an addressing scheme. Is this something ODrives can do/be made to do? Alternatively the connection can be switched using a hardware multiplexer. If I can figure this out from a electrical perspective how does it work on the protocol end? Would the ODrives get confused? Would this work in the simplified case where the motors are being issued identical commands with no need for feedback (simply disconnect the ODrive’s TX lines)
-
Talk to one ODrive and have it relay the messages to the other ones over CAN/some other protocol. Personally haven’t looked at the ODrive firmware extensively, how difficult would this be given the code structure?