I built this for an independent-study project in Computer Engineering (my major). The rationale for it is that something similar to this could conceivably be used by SWAT teams or the military to enter buildings where bad people are and shoot/Taser them (of course, my robot can't climb stairs, but you get the idea. Also, I realize it may not strictly be a 'robot' because it's not autonomous, but I use a loose definition of robot because it makes me feel better about myself.)
Here's a brief summary of how it works:
It has a video camera and transmitter; the camera is in line with the gun, so you can aim with it. The transmitter sends the video back wirelessly to a receiver, which gives it to my computer through a video capture card. I watch that video to control the robot while it's wreaking havoc in another room. I had intended to draw crosshairs on the video to help with aiming, but I never figured out how. So right now, you basically guess that the airsoft gun will shoot in the center of the camera field of view. I might add crosshairs or a laser sight later.
The controls for the robot are the same as tanks in Battlefield 1942: w,a,s, and d to move, the mouse aims, and the left mouse button fires. I wrote a program, using DirectX, that takes input from my computer's mouse and keyboard, translates it into short pieces of text, and sends that text out through the serial port. The serial port is connected to a little $40 radio that sends and receives serial data. The robot has another such radio that it uses to listen to the commands (the two radios just take the place of a serial cable.) The robot's radio is connected to a Microchip PIC, which is a little, $6, programmable computer.
The PIC just runs a simple program where it listens for the serial commands, and when it receives one, it does the appropriate action. For example, it sends signals to H-bridges to control the motors that move the robot and the step motors that aim the gun. It switches a simple transistor to control the motor that pulls the trigger.
The wheels are driven by geared motors meant for power windows in cars; they were $18 at a surplus site, www.sciplus.com. When I want to move slowly, the PIC turns the motors on and off rapidly (that makes the puttering sound in the video. I probably should have used a higher frequency for the switching, but I added the feature at the last minute and haven't changed it yet). To go fast, I hold down the shift key, and it keeps the motors on.
The aiming is done with step motors, which are really great devices for robotics. They are not too expensive, and they can turn a precise number of degrees. Read about them on Wikipedia; they're really useful. I've seen small step motors for under a dollar at Jameco.com, but the two motors I used are large and a little more expensive; they were $49 and $65 at an online supplier. The motors use belts and pulleys from McMaster-Carr to turn the turntable and to aim the gun assembly up and down. My vertical aiming mechanical device was originally made by the ECE Machine Shop at the University of Illinois (they help the electrical and computer engineers to build mechanical things that actually work). Later I had to extend the mechanism to fit the larger, full-automatic Airsoft gun that you see in the video. (That's why it's now half wood and half metal rather than all metal.)
The trigger actually took me a while to figure out. I had originally wanted to tie a string to the trigger, tie the other end to the shaft of a small electric motor, and then make the motor spin to wind up the string and pull the trigger. My motor wasn't strong enough at all, so I attached a lever to the trigger, and that made it work. The lever is an Allen wrench attached to the trigger with cable ties. (A surprisingly large amount of the robot is held together with cable ties). I had to grind off the side of the trigger guard to let the lever extend down without hitting it, but the system works pretty reliably now.
I've made some other things too; check out the rest of my site if you liked this. If you want to build things like this, and you're pre-college, think about engineering as a major. I'm a computer engineer, and a lot of real robotics researchers are, too. Computer engineering is a good major for robotics because you learn about both electricity and programming, and you have a lot of freedom to choose technical elective courses you're interested in (at the University of Illinois that's how it is, at least). If you are a student in electrical or computer engineering, there's a link to the left with my methods for building things.