Introduction: Quick Notebook PC Robot Base
As a collaboration between TeleToyland and RoboRealm, we built a quick base for a notebook PC based robot using the Parallax Motor Mount & Wheel Kit. For this project, we wanted to keep it quick and simple, and we wanted to leave the top of the robot totally clear for the notebook PC. Hopefully this will show how easy it is to setup, and inspire more creative robots!
As with any good robot base, we have the all important motor power switch and a handle!
Step 1: Materials
For the motors, we used the Motor Mount & Wheel Kit with Position Controller from Parallax (www.parallax.com) (item #27971). These provide a nice assembly of motor, optical encoder and position controller. In our first rev., we aren't actually using the position controller, but for most robots, it is a very nice feature.
We also used the Caster Wheel Kit from Parallax (item #28971). We strongly prefer robots with two drive wheels and a caster over skid steering robots! In our experience, skid steering (4 powered wheel) robots have trouble turning on some rugs and patios.
For the motor controls, we used two of the Parallax HB-25 Motor Controllers. (item #29144)
For the Servo controller, we used the Parallax Servo Controller (USB). (item #28823)
For the rest, we used a 12"x10" piece of 1/2" plywood, 8" of 1x3 pine, and some screws and bolts. The main ones were 2.5" Flat Head 1/4"x20 bolts. The flat head bolts were used throughout to keep the surface of the robot flat.
Step 2: Building the Base
The base was very easy to make. We assembled the Wheel and Motor Kits and decided to use them with the motors above the axle for the best clearance. So we needed some standoffs to clear the motors. To do this, we used a 4" piece of 1x3 pine with two 1/4" holes drilled 2" apart to match the mounting holes on the Wheel and Motor Kits. We used a drill press to make those holes straight, so if you only have a hand drill, you can mark and drill from both sides to meet in the middle, or drill a larger hole to allow for some wiggle room.
The flat part of the base was made from 1/2" plywood - we used 12" wide and 10" long to fit our mini-notebooks, but the size can really be anything here. We drilled the 1/4" holes to match the standoff and Wheel Kits - 1/2" from the side and 2" apart as before. The leading edge matched the standoff, so the tires stick out just a bit. We did that to have them hit the wall before the base, but that's not too big a deal. On the top of the board, we used a counter-sink bit to make room for the flat head of the 1/4"x20 bolts (2.5" long).
The bolts need to be actually a bit shorter than 2.5" to fit just right, so we just cut about 1/4" off the ends with a Dremel tool. If you use 3/4" plywood, they might fit without being cut off.
Once that was complete, we bolted the Wheel and Motor Kits to the base.
Step 3: Adding the Caster Wheel
We mounted the Caster Wheel Kit in the middle of the back of the robot - centered one of the three holes on the mount on the base about 1/2" from the edge of the board, then used a square to make the other two holes parallel to the back of the board. In this configuration, the caster wheel can extend beyond the base when the robot is moving forward. We used #6 flat head bolts and nuts for this - used washers to cover the socket holes in the caster kit - again to keep the top obstruction free.
The only change to the kit was that we extended the shaft to make the base level. For our setup, we made a new shaft from 1/4" aluminum rod that was 1 3/4" longer than the one with the kit. We used a Dremel tool to make a notch in our newer longer shaft to match the one in the kit.
Step 4: Motor Controllers, Batteries and Switches
For the Motor control, we mounted the HB-25s behind the motors to leave room for the batteries. Again, we used the #6 flat head bolts.
To mount the motors to the HB-25s, we cut the motor wires to length and used crimped connectors. We left some slack in the motor wires, but not so much that we needed zip ties to hold them. Once we crimped the connectors on, we soldered them too - hate to have a loose connection there! :-)
For the batteries, we were in a hurry, and used NiMH C cells. Realy anything to get you to 12v is fine. We've used Lead Acid Gel cells, but those seem to fail after a few years since we don't manage them as well as we could, and having standard cells allows us to use alkalines as a backup before events and demos!
Yes, there are better C cell holders - what can we say? We were busy, and Radio Shack was close. :-)
We added a lighted power switch. Again, mounted below the base to keep the top clear, and we extended it just past the back to make is easier to get to. We'll be adding a handle, so backing up and hitting the switch is less likely.
We added second switch and battery pack for the servo control board, but the USB power may be enough for the HB-25s since they don't draw much power on the signal side.
The switch brackets were just made from some angle aluminum we had around.
Step 5: Servo Control and Handle
Controlling the HB-25s can be done a lot of ways, but since RoboRealm supports the Parallax Servo Controller (USB), and we had one around, we used that.
Note that for now, we are not using the motor controllers on the Wheel and Motor Kits. The controllers are very nice, but for RoboRealm, we are using vision to drive the robot right now and don't need them. We may add that capability in the future, and for any other kind of control, using the controllers would make it easy to have the robot drive in a straight line etc.
Every robot needs a handle!
For ours, we bent some scrap aluminum and screwed it to the back. We drilled pilot holes since screwing into the side of 1/2 plywood is usually a mess. We're sure this can be done better! :-)
Step 6: Computing
In front of the robot base two Creative Notebook cameras are mounted on top of each other in order to provide as similar an image in both cameras. These cameras are used to look in front of the robot for obstacles that might be in its path. The two cameras are connected to the onboard PC via USB and are fed directly into RoboRealm.
The notebook PC used is an MSI-Winbook that fits very nicely on top of the robotic base. We chose this laptop due to its small size and low cost (~$350) The laptop running RoboRealm is connected to the Parallax Servo Controller via USB to control the motor movements. Luckily the MSI has 3 USB ports so a USB hub is not needed in this platform. Note that the MSI current runs on its own battery. It would be possible to merge the two power systems together but for convenience and portability they were left separated.
Step 7: Software
The MSI laptop is running the RoboRealm machine vision software. The purpose of the demonstration was to use focus in order to indicate the presence of an obstacle in front of the robot. Both cameras were manually focused at different focal lengths. One is focused such that near objects are in focus and far objects are out of focus. The other camera (just above) is focused in reverse. By comparing the two images we can tell if something is either near or far depending on which image is more in focus than the other. The "focus detector" can be though of a filter that determines which image has more detail than the other in a given area. While this technique works it is not very precise with regards to the object distance but it is a very fast technique in terms of CPU computation.
The images below show the two camera images as they look out towards a coke can and a DrPepper can. You can see the focal difference between the two images and also the vertical disparity between the two cameras despite being mounted very close to each other. This disparity can be reduced by using a prism to split a single view into two views for two cameras but we found the quick method of using two webcams close to each other to be sufficient.
Note on the left side of the image the close Coke can is out of focus and the far DrPepper can is in focus. In the right side image the situation is reverse. If you look at the edges of this image you can see the edge strengths reflect the focus of the object. The white lines signal a higher edge transition which means the object is more in focus. The bluer lines signal a weaker response.
Each image is broken into 3 vertical sections. Left, middle and right. We use these areas to determine if an obstacle exists in those areas and if so steer the robot away. These bands are highlighted back into one side of the original image so that we can verify their correctness. The lighter areas in these images signal that the object is close. This tells the robot to move away from that direction.
The downside to this technique is that objects need texture. From the next image we can see two red blocks which are placed in the same position as the cans but they do not respond to this technique. The issue is that the red blocks do not have any internal texture. This feature requirement is similar to that needed for stereo and optical flow techniques.
Step 8: Thanks!
Hopefully, this Instructable gives you some ideas about how to use the Motor Mount & Wheel Kit with Position Controller from Parallax. We found it very easy to set up and customize for our needs, making a very simple notebook controlled robot.
You can download RoboRealm and try experimenting with Machine Vision by going to RoboRealm <http://www.roborealm.com/>.
Have a nice day!
The RoboRealm Team.
Vision for Machines
and TeleToyland - control real robots from the web.
Participated in the
Craftsman Workshop of the Future Contest