Wednesday, September 14, 2011

5X7 Matrix Driven By picAxe 18m2

It started as a simple way to communicate with a robot.  I wanted my robots to have faces...  I could have one that showed a grumpy face when it got stuck, or when batteries got too low, or just to have a fun looking little "bot" of some kind or another.


Of course, all this tinkering around with lights led me to a LED Matrix display I had lying around the junk box.  I got a couple of them for a dollar a few months(/years) ago, just cause I thought they would make good indicators for experimenting with robots.

There I sat staring at the new picAxe 18M2's that I got when I blew my 18X and wanted to keep experimenting.   The M2 versions of picAxe are "real" chips.  That means, they have enough memory to do some more interesting things with.  And there is the whole faster bus thing, and extra timers, and all that.  The chip is designed to run four (4) processes simultaneously.  Sort of a stubby propellor (8 processors) of course, you have to use different and interesting design processes.   The point is, when you run it in "normal" mode, not multi processing, you can really crank up the processor's operating frequency.

So now I am eyeballing the 5X7 dot matrix display with an idea in mind to using the 18M2 at 32mHz (instead of 4) so I can actually handle the timing of Rows and Columns in the 2057 LED arrays.  Oh boy, this looked like fun.  I could build a 5X7 unit for just over the price of the 18M2 because of the surplus 2057's.   I would let the drivers in the chip supply plus voltage so I could use the same chip to sink (20ma per pin on the chip - plenty for the 2057.

Now I know, I could have gotten the 20M2 (20 pins) and had enough pins to drive the 5X7 display with extra pins to drive more than one 2057 displays.  Like having only one display with a 20M2 on it while having more displays simple wired to the chip.

Things I learned:
  • Average current drain is low when you are switching the power by sequentially enabling the Column lines.  The whole 5X7 array averages well below 20ma probably over time roughly 15ma, even though you are driving 35 LEDs in various configurations of on's and off's.
  • Flickering becomes an issue at low speeds, some the videos are using 4mHz speeds, so you can see the flicker.  Since I switched to running at 32mHz, each pattern looks nearly flicker free.   That could be improved too.
  • PicAxe's just got better for home hacker/experimenters.
  • 20M2's can be had for less than four bucks!  More pins!  I'm switching! (I know, the socket costs more and all that, but it's pennies for the total parts costs.
How to build your own:
  • Of course, the whole build it yourself project with the schematics and some "get started" software are online at CwhatIcanDo.com
  • Go follow the guidelines and build one of these to put into something practical...


Wednesday, April 27, 2011

Weekend Project: Get Started With Robots

Well, it was time for a lot of cleanup. Google videos transferred to You Tube. I discovered early development videos as I attempted to get the dogbot to find the opening to a door, to running the bottom of a little $4 junkbot I picked up used.

It makes for a mighty interesting thing, the flat robot running around the room, seemingly headless.


This in turn reminded me of the handiest tool in my robot workbench. It's a motor driver board with an IR detector attached. Sometimes, I just hand wire it to an old robot or RC car chassis, adjust some software, and I can test about any platform available.

Simple yet handy tool. If you have a servo tester, then you are playing at the level that could use this subassembly.

Why the picAxe? Cheapest and quickest way to get going. That's about all.

Later, I'll do something with some of the other chips. It's not that I don't like programming in C...