Multiple arduino on Raspberry Pi

Hello community,

I am trying to use 2 arduino UNO boards on a Raspberry Pi. Each of them are working well when connected independently via USB port, accessible via /dev/ttyACM0 The problem comes when I connect both via a small usb hub, only one of them is accessible via /dev/ttyACM0 and the system is pretty much unstable.

I tried to modify udev rules with the serial attribute of each one but unsuccessfull... They do are recognize each as Arduino Uno with the same and proper idvendor and idproduct...

Any ideas ?

Bests

Just for kicks, power each Arduino separately with external power. It may be you are overloading the capacity of the USB hub. The second Arduino should be on /dev/ttyACM1. I would suggest doing a tail -f /var/log/messages on a separate console, just to see what error messages the kernel is encountering.

You might try a different hub also, I've had them that wouldn't recognize two similar devices as different objects. TomJ

I think your usb hub is the problem. My last hub just splittes the cables to both ports, so they had the same tx/rx..

Hey guys, thanks for the fast answers ! I indeed replaced the hhub and worked perfectly with the new one.... Those usb hubs sometimes are real bad... Anyway FYI it it a self powered bus so nothing to do with power, especially that arduinos are self powered.

Thks.

BTW, you can grab a working image of RPi + arduino on my website...

Which USB hub did you guys use?

I wanna connect multiple Arduinos to one 'Central' Arduino.

visualxl: Which USB hub did you guys use?

I wanna connect multiple Arduinos to one 'Central' Arduino.

You can do it using I2C with one master and some slaves arduinos.

Nope. I can't use I2C.

The slave arduinos has a GSM shield as well as a GPS.

Unless if its just simple sensors, I can use I2C. Correct me if I am wrong.

visualxl: Nope. I can't use I2C.

The slave arduinos has a GSM shield as well as a GPS.

Unless if its just simple sensors, I can use I2C. Correct me if I am wrong.

Why is that? Ive never used I2C on Arduino but I though as long as you have free sdl and sda pins you could use it.

Another way is Spi.

I am not sure why either. I don't really understand those interrupt things.

But from the responses that I got regarding this, GSM and GPS, both uses interrupts. I2C does not work with slaves that uses interrupts.

Yeah. I just starting out SPI. Still reading it though. Haha.

But anyway, in theory, if it works on SPI, it should also work if I connect it using USB hub?

How can you communicate different Arduinoa with usb hub?

I don't know. I have not tested it. That is why I would like to know whether would it be possible to communicate through USB hub or USB host shield?

But from the responses that I got regarding this, GSM and GPS, both uses interrupts. I2C does not work with slaves that uses interrupts.

Rubbish.

@Grumpy_Mike

Instead of saying rubbish, why don't you have a look at my other post here and see whether you can give any suggestion.

http://forum.arduino.cc/index.php?topic=258020.0

At least, I am trying.

why don’t you have a look at my other post here

Because I was unaware of it because you never mentioned it.

At least, I am trying.

If you were trying you would have read the how to use this forum sticky which tells you not to hijack threads and to post in the correct section. In what way is the description of this section:-

For problems with Arduino itself, NOT your project

Applicable to your problem?

You do not have a problem with the Arduino itself, you have a problem with your project.
So post in the right section and do not hijack threads.
Show some manners and you will get respect, show non and you get this.