Using digital out pin to toggle base of 2222 NPN transistor. DO via 2.2K resistor to base, GND to emitter, collector to motor to 5VDC w/ 1N5819 diode across motor (cathode to 5VDC). Scope shows DO going HI/LO @ 4.5/0.08VDC, scope shows collector bouncing 5.04/4.8VDC, emitter constant @ 80mVDC. Motor doesn't run.
What am I missing here?
Not enough current. Try 150 OHm resistor to base, see if it helps. Data sheet for a motor may be useful to save a transistor.
Almost certainly nowhere near enough base current. But since you haven't said how much current you're trying to switch, i.e. the motor stall/startup current, then its difficult to say what you do need on the base (or if that little transistor will even handle the current).
Did a quick web search for 3-5VDC 2 wire generic motor datasheet with no luck. I'll accept the insufficient start/breakaway current answer as the most likely. Removed the base resistor and still no start. The motor runs but the current drain is too much for the UNO so it will need external pwr supply. Fired up the bench pwr supply and this motor draws ~.5A no load and pulls voltage down to ~.5V also. No wonder it wouldn't start. Thanks for pointing me in the right direction guys. Obviously I was given some bad info on doing this exercise as it was laid out. Even with external power the 2222 won't start the motor. Learned from my errors.
A logic level MOSFET will work much better than an ordinary transistor. Even a darlington transistor like a TIP120 would work.
But it would help to know what motor you're trying to drive, even a picture of it might help.
Not sure how to pictures... but...
Best I can think of for now. Don't remember where I bought this lot, but this is what they are. I did solder some 6" M/M jump wires to the terminals.
O.k. they look like Mabuchi FA130 motors, basically intended for 3V use. On 5V expect a stall current of around 2.5A and a normal running current of up to 600mA depending on the load (if you go much over 500-600mA they burn out very quickly).
2.5A is way beyond a 2N2222's safe max current, note.