Last night, I did some good progress on Spazzie – I completed two of the three things I have left to do with him before I can start finalizing his circuitry and getting a real idea of how I can lay it all out on a PCB instead of the bulky breadboard.
I am excited to announce that I have finally begun shrinking down old Spazzie’s guts, making him at least about 60% smaller! Same great taste, less filling!
I finally got a chance to test my xbee explorer/shield combo I bought from Sparkfun. They were out of the retail package when I went to order it, I made a wishlist that contains everything in the kit, you can see it here. Although I did manage to get the xbee radios talking, they are set up identically, so it is not so useful. For anyone else using Arduino and/or xbees on a Mac (I have OSX 10.6.7), you should know that I had a strange problem with both my Lilypad and my xbee Explorer: Neither was detected by Arduino or my Terminal program (CoolTerm). Even though I could see that both were powered up by the USB, nothing was appearing in serial ports. I thought it was maybe my miniUSB cable, but it was not, I tried many. The solution: Install this driver http://www.ftdichip.com/Drivers/VCP.htm. Also, for the xbee radios, you need a program that will allow you to configure them on your Mac. I used a program called CoolTerm, which worked great. Read More »
Watching ol’ Spazzie run around, it is obvious to me that the key to making him better, and in fact allowing more to be done with him technically (like adding a joystick to control him with, and XBees to allow this control) requires that the current functionality be accomplished with a much smaller form factor, and a lighter weight.
With this in mind, I revisited the first motor driver I purchased. When I first got the little Motor Driver 1A Dual TB6612FNG, I had no idea what to make of the schematics, much less figure out how the hell to make it work. Well, today I figured it out! I am not sure I am wiring it up correctly, but I managed to one of my little tiny vibration motors working on it with dual direction control, standby mode, and of course some good old PWM action. This was pretty exciting because it was the first step I had in getting the Ardumoto Shield working. This is awesome, because the size of the little TB6612FNG (~2cm x ~2cm) compared to the Ardumoto Shield (~5.5cm x ~6cm) is a huge savings in size. Check it out:
Not much new under the hood, except that I have tried to calculate the movements of the robot so that I can limit them to 60 degrees at a time(take ~340 ms) when it turns. Externally, I got it a new enclosure ( a index card holder, lol!) and new feet because it needed traction.
I began to see that one big problem I was having was the huge sandwich of silicone, wires on top of the robot were really messing it up! It could not balance well, and some of the stuff was not really needed. So I removed the Protoshield (I just put in a mini breadboard by itself), and moved everything into a small box I found. I was also able to just screw the Sharp Sensor into the box which was great too. I also removed the original “head”, and jury rigged a new base for the box (a flat one!) from an old applesauce container. Now it has a much lower profile. I set it free, and it moves better, although something is making it veer off to one side all the time, and unfortunately, it does not seem that it is weight right now, but I could be(hope I am) wrong. If need be, I could always offset the veer by making it turn slightly in the other way while it walks.
Here is what it currently has under the hood. Notice the super awesome Ardumoto shield, which was the key to getting this thing running. Also, notice there is no motor supply plugged in. This is because the board is managing to power both motors no problem, using the same 5v it sends to the logic board. Awesome for me!
I also took a chance to see what my lab partner thought of it – you can see that here:
The more I mess with the robot, the more I realize that the thing I love about the original design is that it has an innate personality. When you see one of these things sitting there, it has this very evil mechanical spider sort of vibe going on, but as soon as it starts moving around, it really gives off a different vibe: part cute, part goofy, but definitely somehow endearing. Everyone who has ever seen them at my office, or at my house has the same reaction no matter who they are – they think it is cute and really cool looking.
I was thinking about why I chose to try to make this robot move around for the project, when I could have just as easily bought a much larger scale kit that would have come with instructions, and a guarantee that it would work. But I can’t find anything that has a comparable “personality” (if you can call it that) without getting into the thousands of bucks territory. This is why I think that the Hexbug Spider was actually a great platform to learn on. Although the size of the thing limits what you can do to it, the simplicity of the design and the super easy power requirements make it really easy to work with. Of course I had to figure this out, but now that I know there is no reason why anyone else trying to do something similar would have to!
The Face of a Future Version
I put together a simple test platform for seeing how it would look if I used an LCD as a face to convey some sort of mood to people looking at the robot, and hopefully lure them into playing with it. As I mentioned above, the size constraints of the robot make it so that I cannot easily mount it on the thing as it stands now, so I mocked it up on a breadboard (if you want to know how to make a LCD work in Arduino, LadyAda has a super well done tutorial.
Here is a video of the faces program in action!
Want to see the code? It is on Google Docs, here. All you need is an Arduino, and LCD screen with 16 pins, and a sensor (I used a force sensor, you can always switch it up for whatever you want).
Since I started out on this project, several things have changed, so I have updated the project plan accordingly.
I would say that the main changes have been the relative ease of setting up the robot to get moving on it’s own (once you know what to do), my increased comfort level with hooking up hardware, and the very inspiring sight of the robot clumsily navigating it’s environment, and the reaction of people who see it move.
While simply turing the robot into a more advanced RC toy, the real interesting thing to me now is the idea of creating a program that brings the platform to life, simulating some sort of sentience. I like the idea of the robot as a pet. I have not totally ditched the idea of making the robot remote controlled, I have just decided that should be a secondary goal, the primary one being to turn it into some sort of weird little companion pet.
This project started as my final project for Programming for Interactivity - NYU Dcomm Spring 2011
I will continue to work on the project as it has become a super fun hobby! It will remain focused on Arduino, Robotics, and of course, the HexBug Spider.
Hopefully, I will get my hands on a larger spider bot soon...