Welcome to Robot Dialogs. This is a place where I will record my progress, mistakes, errors, failures, lessons learned and hopefully occasional success in my designs and implementations of robots and other technical endeavors. I will try to make it as educational, informative and entertaining as I can...

Tuesday, November 24, 2009

Best laid plans...

Well it seems that every attempt I make to reduce cost on this robot just comes back to bite me in the end. I think I've learned my lesson...buy new shit and don't try to cut corners. I'm referring to the motors and the motor controller... While investigations into the motor controller resulted in a good design (based on that of the Open Source Motor Controller) the cost and time needed is prohibitive at least for the motors I'm going to use. So I've ended up purchasing two 9A motor controllers (one for each drive motor).They work very well for these motors (they are way bigger than necessary). One issue came up when I mounted these to the chassis though... Two of the controller's mounting holes are attached to OUT A on the PCB as you can see in the picture. So when I bolted the things to the bot and started using them, a full 15V was applied to the chassis. This burnt out two cheap sensors (fortunately I had enough replacements on hand) and it wouldn't let the motors go in the same direction. I spent probably 6 hours looking for what was wrong with my test code. I finally asked the Sparkfun Forums again and went to sleep. The next day I checked the forums, but there were no helpful posts so I started testing from the beginning again and noticed the stupid way the board had been designed...ugh. A little hot glue to hold the two plastic standoffs in place (and electrically isolate the controller) and voilĂ  the bot could go forward/backward again!

When I first started writing this post (almost 10 days ago) I had intended to show more drawings from Google SketchUp. At the moment I only have the one below available. Much more is designed already, but because I'm keeping the weapon components a secret until d-day, I'm restricted to what components I can show... I'll have more detailed drawings in the next post, as I said this post is already 10 days in the making, there have been some updates.

Everything has exact dimensions by the way (long hours in SketchUp with a caliper).

There aren't any dimensions (shown) in this pic...It's about 7.75" wide and 9.5" long. I'm a bit concerned about controlling the bot at this point, mostly because of how wide it is. I wont have fine enough control (I think) to do a solely automated bot (this was never the intention, but it's definitely not happening now). I'm not even sure at this point whether I will allow it to line follow without guidance. I'm leaning towards remote controlling everything with a laptop (I don't subscribe to the standard RC controller/receiver paradigm). To this end I've purchased a set of XBee wireless transceivers and the breakout boards necessary to use them (XBee Explorer USB and XBee Explorer Regulated).
Once, in the past, I tried to use a different solution for wireless control on a different robot. I still have them but I've never been able to get them to work (which is sad, they should have a HUGE range and I'm out $100 for the pair). The XBee module's worked first try out of the box! I was floored. What these modules (both kinds) do is form a wireless serial link between the computer and and the robot. Its like having a serial cable without the cable. The XBee Explorer Regulated board allows my micro-controller running at 5V to work with the 3.3V XBee module. The XBee Explorer USB is a board that the XBee module plugs into and it serves as a USB to Serial converter (basically makes it so I can plug into the PC with USB, but the PC thinks it's using an old serial port and cable).

With these modules I can send data and text to the robot from up to 300 ft away! For now I'll be developing a simple (safe) command set to control the robot for the competition. I'll be developing a JAVA program w/ a simple GUI and serial solution to take keyboard/mouse input from the laptop, convert it to a serial commands and send it to the bot. More on this when I've documented it and cleaned up/commented the code that still gets changed every 5 minutes :). Some may wonder why I purchased the 1mW version instead of the newer 2mW or 900 series. The explanation is simple; these were cheaper and they are recommended by Nate (the SparkFun CEO) in a wireless boot-loading tutorial for an AVR micro-controller. I'm going to try to follow that tutorial after this competition, but modify it to work with my preferred micro-controller the ATMega32 (which I'm using for this robot by the way, and yes I know they're getting replaced by the ATMega32A). I wish I had time to do it now so I could get free from my current programming method (AVRISP mkII + AVR ISP Programming adapter).

Okay the post is officially way too long so I have only one more thing to say. If you ever question why I spew on about SparkFun, it's products, members, forums etc. I suggest you look at their news post here to get an idea of why.

No comments:

Post a Comment