A Robotics Project Page
Google
 
Web    www.PhilBot.com
My other sites
  • OurCoolHouse
  • Phil's Resume
  • Web Portfolio

  • [Home] [Projects] [Hardware] [Software] [Books] [Links] [Downloads]


    BOB: The features.          [Back to BOB index]

    He may not be glamorous, but for a robot that is only four inches long, he's pretty packed with features.  So, let's run down that list of features and I'll describe the various design issues.  Maybe you would have picked a different set of features, but hey... go and build your own robot and we can duke it out :)

    OOPic for Brains

    We all know I like the OOPic processor because of the Object Oriented programming model, Yada, Yada, Yada. But hey.. every Robot should have at least one socially redeeming feature, and if it's the fact that it helps people to learn smart programming practices, then BOB's got it made.  If you want to read some more of my preaching on that subject, go to my [Software] page :)

    Split Voltage NiMH Battery System

    My first power decision was to NOT use disposable batteries.  I see no reason why my hobby should increase the amount of heavy metals that end up in landfills.  This meant choosing to go with high capacity rechargeable Nickel Metal Hydride (NiMH) batteries.  So when deciding on operational voltages I needed to keep in mind that NiMH batteries have a nominal voltage of 1.2V instead of the more typical 1.5V of  disposable batteries.

    BOB's electronics need a regulated 5V (five Volt) supply, therefore I needed to start with a battery voltage a couple of volts higher than this so that there was plenty of "overhead" when the fully charged voltage starts to drop.  A six cell AAA NiMH pack has a fully charged voltage of about 8.5V which runs down to about 7.2 before dying.   This is perfect for a typical voltage regulator on a moderate-power robot.

    Next were the motors themselves.  The small motors in the Tamiya gearbox are rated at 3V.  A Higher voltage will provide more speed and torque, but it will also cause the motors to draw much more current, and wear out a lot faster.  So I needed to keep close to 3V.  The H-Bridge driver that I'm using has an internal voltage drop of about 1.5V so that means I need a motor supply somewhere over 4.5V. 

    Some might suggest that I could just run it directly off the regulated 5V, but it's NEVER a good idea to run a robot's motors from the same supply that powers the computer logic.  Motors are very noisy (electrically speaking) and digital logic just isn't designed to take excessive noise.  Analog inputs are even more sensitive to noise.  So just say no! 

    The other alternative would be to run the motors from the full raw battery voltage.  This would probably be OK for the digital electronics (because of the regulator) but now the motors would see a much higher voltage.  Even if the motors survived, the other problem is that the increased motor current would cause the H-Bridge driver chip to overheat and possibly burn up.  What to do, what to do?

    Finally the solution presented itself.  If I tap into the batter pack between the 4th and 5th cells, I can get reduced voltage.  The first four cells would run both the motors and the electronics, and the last two would just run the electronics.  So with the aid of an extra battery wire, I can get both 8.5V and 5.5V from the battery and everyone is happy.  Perfect!! To recharge the cells, I just pop them out (keeping cells 5 and 6 together) and put them in a an economic multi-cell charger.  The cells are charged in pairs so they all end up fully charged.

    Serial Interface

    Bob has a three wire serial interface that can be used for programming the OOPic, and for diagnostics.  The DB9 connector is wired for a straight-thru serial cable.

    Twin Motor Gearbox with Quad Encoders

    BOB uses the popular Tamiya Twin Motor Gearbox (TMG) to drive the wheels.  The gearbox can be assembled with either a high or low gear reduction ratio.  The low-ratio is good for a faster BOB, or the high-ratio is good for a SUMO BOB.  I've modified two of the gears by adding a slot that acts as an interrupter for an optical switche.  To see more about the TMG modifications, check out my [TMG Encoder] page.  The Gearbox mounts to the bottom of the circuit board using two 1/8" spacers that come with the kit.

    There are four optical switches installed on the underside of BOB's circuit board that drop down and fit over one gear from each wheel.  As a motor spins, the gear rotates and the OOPic can count encoder clocks.  In the low-ratio mode, you get about 6 clocks per wheel rotation (or about 2 per inch), in the high-ratio mode you get about 18 clocks per wheel rotation.

    H-Bridge Motor Driver

    To control the direction of a simple DC motor, you need some sort of driver logic that can reverse the battery polarity, and some way to pulse it on and off to control the speed.  The OOPic has two Pulse Width Modulator (PWM) outputs that can be used to vary the motor's duty cycle, but you still need some high current switching logic.  BOB uses a popular chip from Texas Instruments called a Quad H-Bridge Driver. One Half-Bridge can switch a circuit between either supply voltage.  If you put a motor between two half bridges you get a full bridge that can cause the motor to run in either direction.  With two Full Bridges you can run two DC motors.  That's just what we have on BOB. Additional OOPic Digital Outputs are used to set each motor's direction and breaking.

    One tough decision with motor drivers is whether to put them in a socket or not.  If you mount them on the PCB without a socket, you get good heat transfer away from the chip.  This helps to prevent them from overloading.  However, if you do manage to blow one up, they are very hard to replace.  If you decide to mount them in a socket, they are much easier to replace, but they'll tend to get hotter, which will degrade their performance.  It's a tough call either way.

    I mentioned before that motors are very noisy, electrically.  This is true of any inductive load (one that uses some sort of coil).  BOB uses a couple of methods to keep this noise down.  Small capacitors are added across the motor terminals, and across the outputs of the Driver IC to minimize spikes.  In addition, I've added bidirectional Transient Voltage Suppressors (TVS's) with a voltage threshold of 10 volts.  This is a classic prevent and protect combination.

    Ball Caster

    A ball caster is just an easy way to add a third multi-directional wheel to a 'bot.  A single ball bearing and three roller bearings are mounted in a standoff-that bolts to the underside of the PCB.  The ball bearing touches the ground and can spin in any direction.  It's great for a relatively smooth surface.  I don't plan to go off-road with BOB.

    IR Line Sensors

    I wanted to be able to use BOB for Line Following so I needed at least three down facing reflective sensors.  The MarkIII used these excellent sensors from Fairchild, but they were connected to the controller board by "pigtails", which means there were loose wires that needed to be soldered to the board.  On my MarkIII's I attached connectors to these wires and mounted header to the PCB.  The Sensors themselves also needed to be bolted to the chassis somewhere so they could be positioned correctly.

    With BOB I wanted to eliminate the chassis, wires and connectors, so I needed a line sensor that could be mounted directly to the PCB, but that could still see the ground.  As it turned out, the same sensor comes in a PCB mount package that just happens to have leads that are long enough to reach the ground.  The picture at the right shows both the wired and PCB style sensor.  The E is the side with the light Emitter and the S is the Sensor side.

    Since this sensor works on reflected InfraRed light, it's not always predictable how bright the reflected light will be, so these sensors are wired into OOPic Analog inputs (unlike the wheel rotation encoders).  The OOPic program can take some measurements on startup and calculate what a good light/dark threshold voltage is.

    IR Proximity Sensors

    These are the coolest devices from Sharp.  I was so fascinated I had to find out how they worked.  The MarkIII uses a bolt-on version of this range finder (at left in picture) which generates a voltage to indicate how far away the reflective surface is.  How does it know?  Since different objects reflect differently, it couldn't just use the brightness to determine range.  I hunted down the datasheets and was impressed with what I found.  Just like the wheel encoder and line sensor, the rangefinder has an IR emitter and detector, but that's where the similarity ends.

    The Sharp rangefinder's emitter has an extremely narrow pencil beam (about 1 degree of spread) which points straight ahead.  The light from this beam hits a target and is reflected back.  The reflected light enters through the lens in front of the detector and is focused down to a small point. Instead of being a single sensor, the IR detector is actually a linear sensor array, than can tell where the focused spot is hitting.  Since the detector lens is off-center, the closer the target is to the emitter, the further away from the centerline the spot will be.  Throw in a bit of basic geometry and you can convert spot position to range.  Nice job Sharp. (I've included Sharp's description of these devices [here])

    Once again I had the problem of not wanting a bolt-on sensor with wires.  I wanted a PCB mount version.  Well, luckily they have one (shown at upper right of picture) but I needed to make some compromises.  Instead of generating an analog voltage to indicate range, these smaller sensors have a digital output that goes low when an object is less than 40cm away.  They use the same sensing technology, just with a single cutoff point.  There's actually a little slide on the unit that can be used to adjust the sensing range.  Great if you want to increase or decrease the range at which the sensor goes low.   Just for yucks I also added a place to put a third proximity sensor at the back of BOB.  I thought this might be useful for reversing situations, or to detect an opponent that is sneaking up from behind.

    The Next Step

    Now that you've know what features and components were use don BOB, it's time to see how I built the first  [prototype].

     

     

    Web content is copyright © PhilBot.com 2005, Deep Creek Lake, MD.
    Contact: Phil Malone 301.387.2331, webmaster@PhilBot.com