It’s alive!

by Kevin on March 9, 2009
in Robot Army

Just got the motor shield today, soldered it up and wired it into the chassis. A couple tweaks to the code and I have USB control.

Now, to strap my airsoft gun to it and go into mass production.

Robot updated again

by Kevin on March 1, 2009
in Robot Army

I have the code written for the motor shield that I am using. It is completely untested as the shield is still in America someplace. LadyAda did some fantastic work with the shield and the library for it. Makes it so simple to control motors.

Version 3 of the code here.

Robot Progress

by Kevin on February 28, 2009
in Robot Army

I have the motors moving on my robot chassis. Granted, it is me giving the motors power directly and not using any form of computer control but at least i know the motors work. My earlier hypothesis about the motor control circuitry was false. The switching part of the original circuit doesn’t make any sense to me (though my electronics-fu is poor) so I decided to probe the motors themselves. Switching direction is as simple as switching polarity. This makes my homebrew controller more difficult to create so I have decided to use the motor controller shield for the arduino. Yeah, its not as hacky as I would have liked but it is better than me accidently frying something.

Robot updated

by Kevin on January 21, 2009
in Robot Army

Just a quick post to say that my robot code has been updated to communicate with my arduino. Learned some more about Python as well, mostly relating to how badly I suck at it. Can’t get object orientation to work with modules but objects are not necessary for this. Straight procedural code is all that is required, for the moment.

Download robot code

Download arduino code

First draft motor control

by Kevin on November 30, 2008
in Robot Army

Just made an initial stab at some arduino software to control the motors of the tank thing. Nothing fancy, just some functions that move forward, back and do turning. I haven’t coded reverse turning yet, didn’t occur to me until now.

The syntax of the code is C style so those who can code in C, C++, Java etc should be able to read and understand this no problem.

There is no real code that does anything at the moment. I plan to add serial communication to the code so it can interface with the python code I wrote a while ago. Lacking an arduino makes development difficult and the kit I want is out of stock.

Spy Gear ATV-360 partial reverse engineer

by Kevin on November 30, 2008
in Robot Army

Warning, this post my be considered very geeky. If you are afraid of circuit boards, this is not for you.

Top case requires removal of 8 screws, phillips head.

Main circuit board:

atv guts

Click on the photo for notes on the Flickr page

3 pin headers:

  • Microphone – 2 pin, red and black for + and -
  • Antenna – 2 pin one used
  • Camera – 3 pin, red, black and yellow for +, – and signal respectively

Right next to the camera header is a daughterboard with a large shield and an antenna. I believe this is some sort of video processor and transmitter. Possibility for covert video capture and transmission when coupled with an amplifier

Motor control uses 6 wires grouped into 2 sets of 3, each triplet controlling one motor. Circuit board has designations for ground, m1+, m2+, m1- and m2- leading me to believe that the motors are either full forward, full reverse or off. This will make things easier as I do not need to worry about any speed control Load of crap.

I plan on using an Arduino for this project as it seems like a very capable microcontroller board. It has a range of digital I/O and analogue inputs as well as flexible power supply capabilities (usb, pin header or power socket).

Weee code!

by Kevin on April 21, 2008
in Robot Army

After reading the latest XKCD comic, showing it to my mates and then squeeing like a crazed fangirl I decided to make one. The current plans are to borrow a chassis that a mate may have, interface it with my eeepc via an arduino, somehow work out how to get the webcam working and then mount an airsoft gun to the whole thing.

<scientist type=”mad”>MUAHAHAHAHAHAHAHAH!!!!</scientist>

Ahem…

I have a first attempt at some sort of code to drive the robot. It is coded in Python (which I am falling in love with). Feel free to try it ou yourself (Disclaimer: if the code breaks something you agree to not hld me responsible. If it does any good, give credit)

#!/usr/bin/env python

def forward():
print “moving forward”

def reverse():
print “moving backwards”

def left():
print “turning left”

def right():
print “turning right”

while 1 == 1:
objectlocation = raw_input(“please enter the object location: “)
if not objectlocation == “front”:
forward()
else:
reverse()
if objectlocation == “left”:
right()
if objectlocation == “right”:
left()

Not very spectacular but it is a start. To use, run the script somehow on your system and type in stuff at the prompt. It only responds to front, left and right. Anything else is ignored.