For this project, you’ll need:
A full size breadboard with a GPIO T-connector to connect to the Raspberry Pi’s GPIO
A 28BYJ-48 stepper motor with a ULN2003 driver board
6 jumper wires (male-to-female)
A breadboard power supply
A 9V battery with 5.5mm barrel jack connector
Begin by installing the breadboard power supply as shown, applying even pressure on both sides to avoid bending any of the pins.
Plug the battery into the barrel jack of the power supply. Ensure the red LED (red arrow) is turned off. If not, press big white button next to it to turn it off. When on, the battery will supply power to the board, which we don’t want to do until everything is plugged in. Don’t forget to turn it back on before running the supplied code!
Ensure the yellow jumper pin (circled) is placed across the pins shown. This sets the output voltage to 5V, which is what the 28BYJ stepper motor runs on.
Connect the power inputs on the ULN2003 stepper driver board to the breadboard with 2 jumper wires, noting the +/- polarity labels.
Using the 4 remaining jumper wires, connect the 4 remaining pins on the driver board to the GPIO T-connector as follows:
IN1 (orange) à GPIO 23
IN2 (yellow) à GPIO 24
IN3 (green) à GPIO 25
IN4 (blue) à GPIO 26
Closer view of the jumper connections on the GPIO T-connector.