I admit that the spinners I had built off of the solar engine instructions in the Junkbots... book were built off of instructions, and I really had little Idea of even how the solar engines worked at that point. so, I got a bit serious on discovering things on my own, so that I would know about them without trying to remember lessons learned by rote, or comprehend the paragraphs I just read on things I didnt fully understand yet- that was why I wanted hands-on personal experience.
So, where to begin? Transistors. I knew there were two basic types. NPN and PNP, each with varying performances and attributes, that could be looked up on datasheets online. But I had no need for trivia. I knew most things I build would be low voltage, trickle charged, or running off of a 9volt at most.
So, I set up my little power supply, set it to 3V, and placed an NPN transistor in the center, and put 3 jumper wires inline with the 3 rows the prongs were stuck into. I kind of figured that N stood for Negative, and P for Positive, so I tried putting + to the P part (middle pin), Then an LED to one pin to power, to ground, then the other side, until I got to a point where the darn thing switched the LED on and off with me pulling the middle pin out. I eventually figured out that the two side pins were basically like NO (Normally open) contacts on a relay (which I understood as an electrician), with the middle pin being the "coil". With that figured out I now knew that transistors were tiny little switches.
This is a re creation of my eventual "Eureka!" moment, of getting the transistor(lost between the jumper prongs) to "do its thing"
Doing a little more "exploring and trying everything" I found out that the NPN transistor didnt really matter which way the current flowed through the ends (collector and base), and it was basically a "conductor". What was odd in my "try everything" was that with power to the base, and either side having the LED, the light would still come on... without anything on the other prong. I didnt know what to do with this little tidbit of knowledge (still cant think of any reason to), but the point is that now I DO know it, and its a part of my experience, not just something I read. So its with me now.
Next I looked into the "amplification" factor of transistors; how a weak change in the Base makes a BIG change in the mainline power flowing through the ends. Trying to keep robotics in mind, I used a photoresistor to drive a small motor at different speeds with different light levels. It didnt work very well by itself. The resistance was just too high for the 5V to push through the resistor AND drive the little motor. So I tried the photresistor as a variable current into the base of an NPN, to see if this "amplification" thing would do what I thought. It didnt. The resistor varied the current to the base, but this only resulted in an on, or off state to the motor, which did in fact drive now, just all the time, using the transistor as a pathway for the power.
It was time to do some thinking. I had read up in a "beginning electronics" book about "voltage dividers" and knew a bit about the ohms law theory of it all (electrician, remember); about how the voltage drops were divided up evenly along the different loads in a series circuit. This gave me a little lightbulb moment: "maybe I dont adjust the current to the base, but rather the VOLTAGE!" I eagerly put the photoresistor from power to base, like it was before, only now added a 1k ohm resistor from that base to ground.. this should vary the voltage to the base as the resistance of the photresistor changes between its 10k ohm and 2k ohm range. It worked GREAT!
After making a system that worked, I then went on to make something to keep my interest going: I made a Robot Eye.
Point of note: it was built to look like an eye- with "neuron" blob solder joints, to tangled optic nerve wires- on PURPOSE. :) It is really as simple as a photoresistor, a NPN transistor, a 1k ohm resistor, and 3 color coded wires: Red= + voltage, Green= Ground, Black= Motor power lead.
Having a purpose to strive for made all the puzzling out less tedious. I now had an Eye that could vary the speed of a wheeled motor. Cross connect the eyes to the opposite motors, and the eye facing the light would make the opposite wheel go faster, making it follow/chase a light around. THAT is the far off goal that keeps me at it!
Oh, how about a video of the Eye driving a wheel?
So yeah, progress was made rather quickly with simple level electronics aimed at doing something "neat". That wheel/geared motor, by the way, used to be a TrekBot.
http://www.mydeskpets.com/trekbot/
These are found at RadioShack, and are pretty much mass produced BEAM bots all in themselves. I bought a couple of these, played with them the prerequisite amount, then promptly tore them apart for parts, and a rather cool hubless wheel design.
I asked the People at DeskPets if it was ok to "hack" their toys, in order to make other things with them, and that I was intereted in making some of them into BEAM photovores instead of remote control. They replied that it was perfectly fine, they love BEAM hacking too, and even gave me the pinouts of the tiny chip inside that drives the H-bridges to fwd or reverse the wheels!!! That was above and beyond what I expected, those guys are awesome! and make some pretty cool gizmos, as well.
The SkitterBot, TrekBot, and TankBot are my favorite. I have bought (and frankenstein monster'ed) many of them over the months.
No comments:
Post a Comment