Friday, April 16, 2010

It Moves!


I finished most of the major hardware construction for the Coasterbot over the last few days, and got to test drive it this morning. Here's a recap of what's been completed.

Control schematics:
Top layer has master Arduino and voltage regulation, bottom layer has slave Arduino and motor control. No bumper sensors included yet.
The Quad H Bridge I'm using is the SN754410. It's good for 1 amp which is fine for the Lego 43362 motors I'm using. For more details on Lego motor performance, check out the testing done by Philippe Hurbain (Philo). His book 'Extreme NXT' written with Michael Gasperi shown on his home page is excellent, although maybe a bit dangerous to your NXTs...

Drivetrain
The drivetrain is completed on the bottom layer. The top of bottom layer has the motors and motor controls, the bottom has battery pack. Ground clearance is a little low, but this robot isn't intended for rough terrain so it should be OK. I deliberately showed up the Eneloop label on the rechargeable batteries - these work really well and have save me a lot of money compared to alkaline disposables. And kept a lot of batteries out of the landfill.

Test code for the drivetrain just runs the motors from 0% to 100% forward, 0% to 100% reverse, spins clockwise, spins counterclockwise, then repeats.

drivetrain (left), master controller (right) ready to be joined up.


battery pack with 6 Eneloop AA rechargeable batteries
low clearance, this is a smooth surface only robot

Top layer master control
The master control on the top layer is wired on the breadboard and mounted, but it really doesn't do much yet. All the code does is wait for the start switch to be pressed, then flashes the built in LED on the Arduino. The voltage regulator is assembled and tested, so I have 5V for logic and 9V for the motors.

I put the master breadboard on the back half of the top coaster for weight distribution so the robot doesn't fall on it's nose when stopping. It also gives me access to the spindle hole for running wiring between the two layers.

ready to test
every robot builder should have a grid pattern on their kitchen floor

To Do list
Even though the robot rolls, there's still plenty to do:
  • Mount and connect bumpers - either mechanical or digital distance sensors
  • Solder headers on Arduinos for I2C - the analog ports A4 and A5 used for I2C on the Arduino Pro Mini aren't on the edges, so I didn't put headers on them when I put the other headers on. 
  • Test motor balance at various speeds and develop a lookup table for the motor controller. The idea here is internally adjust a given input speed so that both motors turn at the same rate and the robot drives more or less straight. More on this later when I start to do the mapping.
  • Define the I2C messages the master and slave will use for communications. There will probably be a blog entry or two on this subject. And another chance to use my Saleae Logic analyzer!
  • Get I2C working between the master and slave.
  • Master control software for basic obstacle avoidance.
  • XBee communications back to PC for status messages. This is optional, I might just run out of time to do it before the end of the MAKE Coasterbot contest.
  • More stuff I'm sure I haven't considered yet.
But first, it's a beautiful day here in SE Michigan - time to go for a mountain bike ride!

Brian
The Black Dog



No comments:

Post a Comment