Connect 2 Motoron M2U550 to Raspberry Pi 5

Hi
I want to connect two Motoron M2U550 to a Raspberry Pi 5. Since the Motoron is communicating via UART I’m not sure if its possible to do that. I asked ChatGPT about it and it said that I should use the RST Pin to deactivate one to use the other. But that dosent work because I have to have the option to run motors connected to different Motorons at the same time. So what are my options? Since the Raspberry Pi has that new debug port which also uses UART maybe that will work but I dont know and didnt test it because I dont have the right cable to do so.

What are possible solutions for this situation?
Thanks in advance

Hello.

If you are not already committed to the Motoron controllers with serial interfaces, you might consider the Motorons with I2C interfaces (such as the M2T550) since connecting multiple I2C Motorons to your Raspberry Pi will be easier. We even have some Motorons that are designed to plug into the GPIO header on a Raspberry Pi, like the M3H550.

If you are committed to the serial M2U550, then you can still control both boards with your Raspberry Pi by daisy chaining them. Start by connecting each Motoron to your Raspberry Pi one at a time and use the serial_setup_example.py program from our Motoron Motor Controller library for Python/MicroPython to configure different device numbers for each board. Then you can connect your Raspberry Pi TX pin to both of the RX pins Motoron’s and try something like the serial_simple_multi_example.py program.

If you eventually want to be able to read data back from the Motoron controllers, please note that you will need to connect the TX lines on each of the boards to the Raspberry Pi RX pin through an AND gate.

- Patrick

I dont get it to work. I sent with the serial_setup_example.py the command “a 18 -1” and then “r” and checked with “i” but nothing was detected. When I tried running the serial_simple_multi_example.py then nothing happened. In the description it says that JMP1 must be low but I dont know what that means. I did nothing with that pin so maybe thats the mistake.

Im not fully commited to the serial version but I would prefer that one because I have a few other devices connected to I2C so I dont have a really good feeling about connecting to many devices to I2C but I dont know if that fear is reasonable. And the M3H550 is also not an option because I need to connect 4 motors at the same time.

You can set JMP1 low by connecting it to ground (GND).

If you continue having trouble using the setup example, please post some pictures that show all of your connections as well as screenshots showing how you are using the program and what it is returning.

By the way, I2C is intended to support connecting many devices, but if you are concerned about it, you can post a list of the other I2C devices you are using (plus how many of each you are using), and I can take a look at it to see if there are any obvious concerns.

- Patrick

I still have trouble.

I soldered a Pin into JMP1 so it is always connected to GND when using a Breadboard (what I use to test). The connections are the same as in Motoron M2U550 + Raspberry Pi 5 - #8 by Mael. The only change to connect two Motorons that I made is, the TX cable from the Pi goes into a seperate connector on the breadboard and from this I have a cable connected to each Motoron (Rx).

The python setup program works without an error. wenn I send “a 18” it says somthing in the lines of “setting Devicenummer to 18” so as you would expect it. (when I send those commands the TX is only connected to one Motoron at the time). And then when I want to check if it worked and send “i” it only says “Done” without listing any Motoron. I tried rebooting the Motoron (disconnect from Power) and sending “r” via the python program but the result from “i” doesnt change.

I decided that I dont want to use I2C for the Motoron.

What am I doing wrong?

It sounds like you are leaving the JMP1 pin connected to ground all the time, but you should only have that pin connected when you are setting the device number. After you set the device number, disconnect JMP1 and leave it disconnected from anything.

- Patrick