DC Motor Control - GitHub Gist Code
A small fan was connected to a DC motor which was then connected through an H-bridge to an Arduino. A button was used to swap the rotation of the DC motor and thus change the direction the fan was spinning in. When the button was pressed, the fan spun counter-clockwise, and spun clockwise when the button wasn't pressed.
Stepper Motor Control - GitHub Gist Code
A stepper motor is connected to an Arduino through an H-bridge. The 28BYJ-48 stepper motor makes 64 steps per revolution and has a speed of 60 rpm. Thus, the stepper motor rotates one revolution at a time, pauses, then makes another revolution.
Back to Top