Interfacing mutliple propeller boards to a PC
RoboTy
Posts: 5
Hello,
I'm trying to figure out how to interface several propeller boards to a PC running ROS (www.ros.org/wiki) The PC is not decided yet, maybe Roboard, Fit-PC, or gumstix). There's already ROS implementation in the Roboard and gumstix that I'm aware of.
All in all I'll have at least 20 joints with a motor and encoder + additional sensors. This means I'll have multiple propellers. USB is one option, and probably the easiest to implement hardware wise since all SBC and most propeller boards already have USB. One question I had is how does USB fare near motors. I was thinking to connect the PC to a hub, then daisy chain the propellers down the arms and legs. I'm worried about latency though. I'd assume I need to update at at least 100Hz, I'd prefer to go faster than that though.
Other off the shelf solutions such as dynamixel servos use RS-485, which I know is good for noisy environments, but I don't know how speeds compare and ease of programming. Also, I don't know of any propeller boards with RS-485 built in.
Any ideas? Thanks in advance.
I'm trying to figure out how to interface several propeller boards to a PC running ROS (www.ros.org/wiki) The PC is not decided yet, maybe Roboard, Fit-PC, or gumstix). There's already ROS implementation in the Roboard and gumstix that I'm aware of.
All in all I'll have at least 20 joints with a motor and encoder + additional sensors. This means I'll have multiple propellers. USB is one option, and probably the easiest to implement hardware wise since all SBC and most propeller boards already have USB. One question I had is how does USB fare near motors. I was thinking to connect the PC to a hub, then daisy chain the propellers down the arms and legs. I'm worried about latency though. I'd assume I need to update at at least 100Hz, I'd prefer to go faster than that though.
Other off the shelf solutions such as dynamixel servos use RS-485, which I know is good for noisy environments, but I don't know how speeds compare and ease of programming. Also, I don't know of any propeller boards with RS-485 built in.
Any ideas? Thanks in advance.
Comments
If you keep the baud rate low then it will go long distances. Eg 19200 baud might go tens of metres, but 1200 will go kilometres.
Then on each propeller, use a max3232 for RS232 to 3V propeller pins.
One can debate the merits of RS485 vs RS232. It is quite a complex subject. For starters there are two sorts of RS485 - 4 wire + gnd, which is very simple to convert to and from RS232, and 2 wire + gnd, which is more complex as you have to be able to handle data clashes.
Converting propeller pins to RS485 is as simple as a $3 chip but there are a few 'gotchas', so if you want to go down this road we can discuss those.
Could I use the usb connection with the actual usb protocol? I've seen posts on these forums talking about a 2+ MB/s connection to a PC. Does USB pick up motor noise over short runs, 3 inches or so? Is it simple to wire up the USB for daisy chaining?
So the converter-chip does all the high-speed USB protocol stuff.
Using the software USB-solution inside the propeller will cost you 1 or 2 cogs per connection.
Parallax uses FTDI-chips as USB-2-serial-adapters. Take a look into the
specification of the chips how high you can raise the baudrate.
Anyway the prop has to be that fast to.
best regards
Stefan
Has anyone tried to decode a PCI port address for simple read/write capability to from a PC port? I'd be very interested in the project.
Using fiber optic connections was the only way to avoid the noise. We also used wired differential communication methods.
I designed a pcb that went from a pc's usb to a ftdi chip with a very short usb cable(6 inches) to my pcb, then to 5mbps fiber transmitter, which then traveled 10 feet over fiber to the motor drive. Im sure today you can find cheap fiber tx/rx pairs with optical wire.
Most of my USB runs will only be 6" or so, but a few daisy chained could add up to 24". They also could end up going right next to a motor. They are smaller DC motors, 18.5 to 24v, Max 5A stall, probably closer to 3 but I'm not sure yet. Any guesses how bad this actually is?
I was thinking of running USB all the way to the controller board where there's a FTDI chip (like Stefan said), unless there will be noise problems.
If I did the optical wire method are you saying I could probably run optical wire all the way to the USB port on the PC then terminate in some sort of Fiber to USB connection (essentially a less than 1" USB cable at all hubs, and PC side)?
Beau, has anyone come up with some sort of PC104 to propeller connection? That might be useful. (Is that the same thing as what you're talking about?) I'm definitely not the person to try that for the first time.
Or you could just use usb to fiber and not have to really worry about it.
The fibers only transmit the serial signal, not the usb. The usb signal is converted to ttl serial first, then to fiber, this is done at 5v. The ftdi chip gets its power from the usb 5v bus, so do the fiber rx/tx) Because this method uses fiber, the prop side can directly interface with other side of the fiber without any worries about 5v to 3.3v issues.
Also the benefit of fiber isolation keeps you from worrying about your motors and drive circuitry killing/messing with the pc if it were to blow up.
A cheaper method would be differential. (rs-485)