I’m teaching a Critical Making course and a question came up regarding how to run a DC motor from the Arduino. It was a bit tricky to get figure out how to do this using the parts in the Economic Starter Kit that students were told to purchase from Creatron, our local purveyor of maker stuff. There were a couple of puzzles, how to use the parts we were given and which online tutorial to follow.
Arduino Uno (Rev 3)
Switching Diode (1N4148, 75V, 100mA)
N-channel Transistor (FQP30N06L)
If I’ve muffed up the diagram, let me know.
Things to notice or could go wrong.
1. Make sure the diode is going the right direction. If you’re not sure, try it both ways.
2. Make sure you are using a PWM (Pulse-Width Modulation) pin on the Arduino. In the code, it’s Pin 3 and that’s correct for an Arduino Uno
3. Make sure that bare wires are not touching.