On 07/02/2014 09:27 AM, Luke Keyes wrote:
Mobile robots are self powered from self-contained power sources.
The most common power source is one or more batteries. The BEAM
robotics folks tend to use solar cells. It does not take much
imagination to think in terms of a fuel cell as well.
Mobile robots frequently have power distribution and management
issues. Inexpensive brushed DC motors tend to have two issues:
1) They can be "bursty" in the current draw.
2) The brushes tend to generate some high frequency electrical
noise that cause issues due to EMI (Electro-Magnetic
Interference) and inadequate power supply filtering.
DC motors can change their current draw very quickly. The simpler
motor control software is notorious for going from a dead stop
to full forward (or reverse) and causing a large spike of current
draw. These current spikes can do several things:
1) The current spike can cause a "ground bounce". The ground
return path from motor H-bridge has a resistance. The increased
current causes an increased voltage drop along the current
return path. This shows up at the microcontroller as a
drop in the power supply voltage. With enough ground bounce
the microcontroller will decide that it is in a brown out
situation or reset situation. This is more of a problem
with linear regulator chips (e.g. the 7805) than it is
with DC to DC converters.
2) The current spikes can cause ground loops where current
is flowing back and forth between the electronics in the
system. A bad ground loop can exceed the current capacity
of a wire and melt it.
It should also be mentioned that DC motors are not the only source
of large current spikes. For example, the Sharp GPD120 was notorious
for generating 250mA current spike with a quiescent current of 9mA.
Likewise, if you have a bunch of LED's that go from all off to all
on, a fairly surprising current spike can result.
The first decision point is whether to have one or two power
harnesses.
1) The single power harness solution has a single battery and
a single power harness to distribute the power. Your
logic electronics and your motors share the same power
terminals.
2) The dual power harness solution has one power harness to
power your devices with bursty current loads (e.g. DC Motors,
GPD120's, LED arrays, etc.) and another logic harness for
your devices with relatively smooth current draw (e.g
microcontrollers, bump switches, etc.) By keeping these
two power harnesses separate, you minimize the amount of
spurious microprocessor resets and brownouts.
The choice between one harness vs. two harnesses is a personal
choice. If you go down the one harness route, you need to be
more careful with your electronics design. Almost all
commercial products use the one harness design. They also
typically have one or more electrical engineers on staff to
get all the electronics right. If you go down the two harness
route, you have a different set of choices. In particular
you have to worry about communicating from devices on one
of the power harness to the other. This is typically done
with opto-isolators, pulse transformer, high impedance
operational amplifiers, etc.
In general, if you are an electrical engineer, you get to
make the call. If you are not an electrical engineer, I
recommend the two harness route for floor based robots or
larger. For table top robots, it probably does not matter
that much.
For the two harness strategy, you get to make some more
decisions:
1) Use two separate batteries and keep the power harness 100%
electrically isolated.
2) Use two separate batteries, but tie the ground wires of both
harnesses together at exactly one point that is very close
the minus terminals of both batteries.
3) Use one battery, but put a good DC to DC buck converted to
provide power to the logic harness. The motor harness is
attached directly to the plus and minus terminals of the
battery.
4) Use one battery to power both harnesses by connecting both
harnesses to the same plus and minus battery terminals.
Personally, I've done 1), 2), and 4). I tend to use 2) the most
since I can run the motor harness off of either a 12V or 24V
battery. The Logic harness tends to be run off of a 7.2 RC
battery. I've heard that 3) works pretty well, but I have
no direct experience with it. I no longer encourage anybody
to try 4), batteries are sufficiently cheap that there is
no reason not to use two. If you really, only want to use
one battery, go with 3). Pololu sells reasonably priced
step down voltage regulators.
When it comes to communicating between the two harnesses
there are a variety of technologies that can help out:
1) Classic opto-isolators. They are cheap, readily available
and easy to use. Their primary draw back is they tend
not to be very fast. They are just fine for driving an
H-Bridge.
2) There are higher frequency electrically isolated devices.
Analog Devices sells some devices that are based on pulse
transformers. In addition, Silicon Labs sells some that
are basically really small RF transmitters. The Silicon
Labs are good up to mega bit per second.
I mostly use opto-isolators, they are cheap and work just fine.
Now when it comes to EMI, the issues get fuzzier. Basically
our robots are made out of wires and those wires are perfectly
happy to behave like antennas and pick of radio frequency
signals.
In general, for EMI, there are several issues:
1) Signal Frequency. The higher the frequency the bigger the
problem. Remember AM radio occurs approximately from 500KHz
to 1500KHz. FM radio occurs from approximately 90MHz to 110MHz
2) Signal Slope. The squarer the pulses, the more high
frequency that comes out. Good signal transceivers are
slope controlled.
3) Signal Run Length. The longer the signal run, the more
opportunity there is to radiate and receive EMI.
4) Signal Transmission Strategy. In general, differential
transmission over wire pairs works better over longer distances.
For shorter distances, you can get by with simpler single wire
signal transmission works.
5) Shielding. The longer the signal run, the more you should consider
some sort of wire shielding. I used to live a 1/4 a mile away
from a fairly high powered radio transmitter and it caused a fair
amount of grief on my electronics projects. I tended to encase
my projects in metal boxes to provide a kind of Faraday
cage to keep the evil RF signals at bay.
6) Filtering. Sometimes you can put some filters in place to help
minimize high frequency noise. There is a whole sub area of
electrical engineering called Snubber circuits to try and
minimize the noise at the source. I use a simpler strategy
of putting ferrite beads on my motor power leads next to
the motor.
Dealing with EMI issues can be a bit like black magic.
------------
Now comes the section that is opinion. Note that below is
*my* opinion and reasonable people can have alternative opinions
that are perfectly valid.
For small Arduino based robots, I recommend the two battery
approach. Battery packs are cheap. Some of the Arduino
clones out there have poorly designed linear regulators,
so the dual battery approach may save some grief.
For larger robots, if you are an "electrical engineer", you should
understand the issues enough so that you get to make the call.
If you are not an "electrical engineer", I recommend the two harness
route. By the way, I put "electrical engineer" in quotes
to mean someone that is comfortable working with electronics.
I could care less if you have an official BSEE from some
sort of educational institution.
Again. These are my opinions. You are free to disagree.
Regards,
-Wayne