Got your parts for the Make: Robot Build contest, and want to build something with them, but not sure exactly what yet? Strapped for time, and want some results fast? Then we have the perfect tutorial for you: The one hour coasterbot! This basic design probably won’t win you many awards, but it will get your bot moving! The tutorial is broken into to two phases, control system and chassis. In the control system portion, we’ll cover how to take the electrical parts from the Jameco Robot Parts Bundle (reminder: it’s optional, you don’t need to purchase it to participate in the contest!) and build a working control system out of it. Then, in the chassis portion, we’ll cover the quickest way to assemble the parts into a functional robot, in order to get things going. So, ready to get your bot on? Lets begin!
Assembling the Control System
Required parts:
- Modified servos (x2)
- 9v battery connector and battery
- AAA battery pack and batteries
- Mini breadboard
- Ardweeny, assembled
- Breadboard Power Regulator, assembled
- L293DNE H-bridge
- 22 AWG, solid core wire (misc)
Tools:
- Soldering iron + solder
- Pliers (optional, for bending wires)
- 5v FTDI programming cable
These instructions assume that you have already assembled your Ardweeny and Breadboard Power Regulator kits, and have modified your servos for continuous rotation. If you haven’t done these steps yet, now is the perfect time!
Note: To make the photos easier to follow, I am using colored wires instead of the black spool that comes in the kit. Feel free to use either. Also note that I put heat shrink tubing over the wires on the motors and battery holders, to help keep them organized. That is purely optional, but can help keep the wiring neat.
Before we begin, here is a drawing of the circuit we are going to make, showing the exact placement of each component and wire:
It’s a basic motor controller circuit, and will allow the Ardweeny to use the L293D motor controller to drive our hacked servo motors.
Step 1: Solder the 9v battery connector leads to the Breadboard Power Regulator
We’ll use a 9V battery to power the Breadboard Power Regulator. To hook it up, solder the positive (red) wire to the metal tab on the back of the power jack (as shown above), and the negative (black) wire to the metal tab on the side. Plug in the 9V battery, and flip the switch on the Breadboard Power Regulator to the ‘on’ position. If you’ve got it right, the red LED on the board should light up. Flip the switch back off for now.
Note: When you set up your power regulator, you had two choices for how the power lines would be connected, and you could set them by putting a little blob of solder across two copper pads. For this tutorial, we’re assuming you have the second set wired up. If you’re not sure, check to make sure they are the same as in the above photo.
Step 2: Examine the breadboard
The breadboard acts as as big interconnect for the electrical parts, allowing you to easily hook up power and other control signals without running too many wires. It is divided up into three sections: two side rails for power, and one main section for connecting things up.
In the photo above, we have highlighted how the holes are connected together. Each shaded area represents a separate circuit, and all of the holes in that circuit are shorted together. Each one of these sections can be used to make a single connection, or ‘node’ in a circuit diagram. The two side sections are reserved for power- anything plugged into the black areas becomes connected to ground, and anything plugged into the red areas becomes connected to power. For a more in-depth discussion about breadboards, see Tom Igoe’s breadboard page.
Step 3: Plug the components into the breadboard
The next step is to plug the components into the breadboard. It’s hard to tell exactly where to plug everything by looking at the photo, so if you are confused check out the layout diagram that was in the introduction.
Step 4: Add ground wires
Once the components are placed, the next step is to place jumper wires to ground any component leads that need grounding. These are shown in black.
Step 5: Add 5v power wires
In a similar manner, use jumper wires to connect the pins that require 5v power. These are shown in red.
Step 6: Add motor control lines
The final set of jumper wires runs between the Ardweeny and the L293D, and allows the Ardweeny to control the motors. I used orange wires for my actual board, but they are blue in the drawing.
Step 7: Connect motors
Now, you are ready to connect the leads from the continuous rotation servos to the L293D motor driver chip. Connect one motor to each side of the chip. We’ll sort out which direction is which in the software later!
Step 8: Add AAA battery box
The last thing to hook up is the AAA battery box, which will power the motors. This plugs directly into ground and the 8th pin on the L293D motor controller.
Note: I forgot to take a picture of this step on my final build, so the above one from a slightly messier version of the circuit!
Step 9: Download sample code
All right! That’s all the wiring you need to do to build a control system brain for your robot! The final step is to try downloading a program to the Ardweeny, and see if you can make the robot work! Make sure you have the Arduino software set up on your computer, then grab
, and upload it to your bot. If everything is set up correctly, the motors should start to spin in a pattern!
Assembling the Chassis
Having a working control system is fun, but it’s way cooler when it is actually attached to a chassis, so that it can start to move. To get you going as quickly as possible, we present our patented method for making a quick robot: double-sided tape! For this simple chassis, we’ll skip the screws and glue, and use double-sided foam tape to patch everything together. It should work great for prototyping, however you will probably want to think of a more permanent solution. Once you do, just pull the components off of this temporary body and use them in your next chassis!
Required parts:
- Assembled control system parts (from above)
- 2 CDs or DVDs
- Double-sided foam tape
Tools:
- Scissors (to cut the tape)
Step 1: Cut two pieces of sticky tape and stick them to one of the servo motors
Step 2: Stick the servo near the edge of one of the CDs
Step 3: Repeat for the second Servo, making sure to leave enough space between them to fit the AAA battery pack
Step 4: Add some more tape to the top of each servo motor
Step 5: Stick down the second CD, making sure to align it with the first one
Step 6: Stick tape on back side of the breadboard
Step 7: Wedge in the 9V battery, using tape to hold it in place
That’s it- if you plug the motors and batteries back in, the spinning motor test code from before should now let your robot do a little jig! We suggest you do one as well to celebrate!
Conclusion
If you’ve made it this far, you hopefully now have a functional robot body to start playing with. Next steps include shoring up the mechanical design (maybe use the spaces instead of tape?), adding sensors, and perfecting that code. If you ran into any issues, be sure to hit the Robot Build Forum for some help with troubleshooting. Happy building!
ADVERTISEMENT