So here's my issue. I've got the arduino Duemilanove outputting through digital I/O pin 4 through a 1k resistor to the the base of a transistor (emitter hooked to Arduino GND) to switch a motor on and off. The motor runs off 9 volts which is hooked + through the collector of the transistor, the motor is between the emitter and the 9volt -.
Because the motor has it's own set of logic, it doesn't always turn on, even when digital I/O pin 4 is high. I want to be able to measure whether or not it is drawing current through the analog pin 0 on the Arduino. Then I can tell whether 1) if the digital i/o is high and the motor is not on, thus not drawing power and 2) if it is on and drawing power, how much is it drawing?
My problem is that I set up a resistor between the motor lead and the transistor emitter, and attempt to measure the voltage drop across it (to convert current to voltage) and the transistor goes up in magic smoke. The GND of the digital I/O and the GND of the analog I/O seem to be the same.
How do I simply measure the current draw on this motor? When i use a multimeter it works fine. When I use the arduino as a voltmeter separately from the logic (just touching the leads on a 9-volt) it works fine.