Let's Make Robots!

Connecting multiple uC wirelessly

Beat_Slayer has built a dual Arduino for his robot. He was talking about adding an nrf radio to communicate with it. That led me to wonder if there would be any use for having systems that have pairs, or, more of uC that only communicate via radio.

The thought that came to me was "left brain" "right brain" and the cross polination from more than one "whole brain". I am sure someone will help me flesh out or utterly kill the idea. :D

Any suggestions to help this make more sense to more people are readily accepted.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

An Arduino library exists to "network" the nRF24L01 modules: https://github.com/maniacbug/RF24Network

I have played with it, but it's not the easiest library. I have only blinked a couple of leds so far... http://www.bajdi.com/?attachment_id=758 I would like to control my different robots from one master connected to my PC. But I have a long way to go...

I have a bunch of wireless projects. My favorite transceiver is the Nordic nRF24L01+ module. Here's a place where you can buy ten for $11.50 (that's about the same as the price of ten XBee's right?).

SparkFun used to sell a little key fob with a built in Nordic. One of my projects included a couple of these fobs and a several other "panic button" distributed through out a house (my in-laws). The idea was to make sure someone staying in a guest room would be alerted if any one of the buttons was pressed. I had each device resend any incoming messages to make sure the message would reach its distination. It would add its own ID to the message to indicate it had transmitted it. If a device received a message it had already transmitted, it would not transmit it a second time (otherwise you'd end up with messages endlessly looping around the network).

I have a bunch of different robots (more than I've posted to LMR), I've always thought it would be cool if they could communicate with each other. I also think it would be cool if I could use one remote on multiple robots. I've spent a lot of time trying to figure out a protocol that would let me use one remote on multiple robots. It's amazing how complicated this stuff gets. Do you worry about lost transmissions? How many times do you resend data? How do you make sure old data isn't seen as new data?

Adding message hopping adds a whole new layer of difficulty. While message hopping can be a challenge to work out (without using more expensive transceivers that keep track of this stuff for you), it adds a lot to any sensor network. One of the great things about a sensor network with message hopping is it uses much less power than to get a message from one place to another if it makes several hops along the way than if the message were transmitted directly.

This is one of subject I keep intending on spending more time on. I'd like to wire up most of our household appliances to a wireless sensor network so I could see if my toast is done while I'm using the drill press (maybe that's not the best example). I do want include a control to our sprinkler system on my robot remote.

I'm pretty sure Gareth is working on something with a bunch of cheap Nordic transceivers. It will be fun to see what he does.

As bdk6 suggested, I wouldn't use wireless unless a wired link presents a problem.

The two or more processor idea is a good one. There are lots and lots of ways that could be useful.  Not so sure about the wireless connections between them, though.  I can only think of a few places where that seems like a good idea.  Maybe wheel-mounted sensors or something like a scout bot that goes out from the main bot.  

But for the multi-processors I can think of a lot of ways that would be useful.  In fact, it is widely done now and not just in robotics.  Modern cars have dozens of processors in them.  The first idea, and probably most common, is master-slave.  Specialized processors that handle smaller, specialized tasks to offload the main computer.  Things like sensor controllers or actuator controllers.  Stepping up a notch, how about a processor that handles low-level and local navigation:  obstacle avoidance, local route planning, controlling the drivetrain, reading the sensors.  Another computer does the large-scale planning.  I think Beat_Slayer touched on another idea:  two similar processors performing basically the same function but with different algorithms and parameters.  They come up with different plans, then negotiate which to use (is better).  

Lots of possibilities.  

Well, initially I hadn't understood your idea, but after reading here more explained, I thought of why not to build a triduino (3 x ATMEG328), use the master uC to make the actual moving, interfacing and sensoring, but use the left/right uCs to interpretate the data from sensors and make decision calculations with different considerations, and then the master uC will choose one of the two decions made by the right/left uCs.

The master uC could even make some tracking of which of the brain sides had a good or bad decision for some situation and then when he reached a similar situtaion he would weigh in in favour of the side with the best outcome so far in that particular situation.

Well, I guess it's time to start thinking (sparing money) of buying some atmegas and a SD card module, and try the concept.

I would like to say that my thought was more wide ranging than a single entity though. Imagine the the "right brain" of Robo1 sends a message to whoever will listen. Maybe it is the "left brain" of Robo1, or, another part of a different "brain". Maybe a hive mind that encompasses two different ideologies.

Am I making more sense, or, just muddying the water?

You mean something like: uCs streaming data, and whichever uCs collects that data, interprets it and streams out is avaliation/conclusion, and so goes...

Something like a Rmesh on a feedforward backpropagation artificial neural network.

I think this is one of those solutions in search of a problem.  The only context I have to a system like this is the "Allosaurus" system I've played with, where I was trying to use an ATTiny for sensors on a PIbot over i2c (since the Pi doesn't have any ADCs) but I tested it on Arduino, so it was roughly like having two Arduinos.  It can work, it's just a matter of what "working" means I guess.  This would be more of a medula/cerebellum analogy than right/left brain.  I don't know that you'd get a "medulla" or anything from the junction of two μcontrollers, but if you're just short of enough pins for kinematics on a walker and want to add sensors it might be a way to go.