Stepper Motor 28BYJ-48
with ULN2003 Driver & Arduino, Node MCU, ESP32
Stepper motor is a brushless DC motor that rotates in steps. This is very useful because it can be precisely positioned without any feedback sensor, which represents an open-loop controller. The stepper motor consists of a rotor that is generally a permanent magnet and it is surrounded by the windings of the stator. As we activate the windings step by step in a particular order and let a current flow through them they will magnetize the stator and make electromagnetic poles respectively that will cause propulsion to the motor. So that’ the basic working principle of the stepper motors.
However the most common method of controlling stepper motors nowadays is the Microstepping. In this mode we provide variable controlled current to the coils in form of sin wave. This will provide smooth motion of the rotor, decrease the stress of the parts and increase the accuracy of the stepper motor.
Another way of increasing the resolution of the stepper motor is by increasing the numbers of the poles of the rotor and the numbers of the pole of the stator.
Stepper motors fall somewhere between a conventional DC motor and a servo motor. They can rotate continuously like DC motors and be positioned precisely (in discrete steps) like servo motors. Stepper motor, 28BYJ-48 with a ULN2003-based driver board, making them very simple to use.
Stepper motors fall somewhere between a conventional DC motor and a servo motor. They can rotate continuously like DC motors and be positioned precisely (in discrete steps) like servo motors. Stepper motor, 28BYJ-48 with a ULN2003-based driver board, making them very simple to use.
ULN2003 Driver |
Arduino |
---|---|
IN1 |
8 |
IN2 |
9 |
IN3 |
10 |
IN4 |
11 |
GND |
GND |
Stepper motors use a cogged wheel and electromagnets to nudge the wheel round a ‘step’ at a time. Each high pulse sent energizes the coil, attracting the teeth closest to the cogged wheel and rotating the motor in precise and fixed angle increments known as steps. The number of steps that the stepper motor has in a 360 degree rotation is actually the number of teeth on the cog. The way you pulse these coils determines how the motor operates.
According to the data sheet, when the 28BYJ-48 motor is operated in full-step mode, each step corresponds to a rotation of 11.25°. This means there are 32 steps per revolution (360°/11.25° = 32).
In addition, the gearbox inside the motor has a 64:1 gear reduction. This results in 2048 (32*64) steps per revolution.
Connecting with: Stepper Motor 28BYJ-48 with ULN2003 Driver & Arduino:
Stepper Motor 28BYJ-48 with ULN2003 Driver are connected as shown. Driver board VCC and GND are connected to 5 volts DC and ground pin of Arduino. Connect the driver board’s IN1, IN2, IN3, and IN4 to Arduino digital pins 8, 9, 10, and 11, respectively. The stepper motor can be powered directly from the Arduino, but this is not recommended because the motor can generate electrical noise on its power supply lines, which may damage the Arduino. Hence the Stepper Motor 28BYJ-48 is connected to ULN2003 Driver which in turn is connected to Arduino.
Stepper Motor 28BYJ-48 with ULN2003 Driver & Node MCU:
Stepper Motor 28BYJ-48 with ULN2003 Driver are connected as shown. Driver board VCC and GND are connected to 3.3 volts DC and ground pin of Node MCU. Connect the driver board’s IN1, IN2, IN3, and IN4 to Node MCU digital pins GPIO8, GPIO9, GPIO10, and GPIO11, respectively. The stepper motor can be powered directly from the Node MCU, but this is not recommended because the motor can generate electrical noise on its power supply lines, which may damage the Node MCU. Hence the Stepper Motor 28BYJ-48 is connected to ULN2003 Driver which in turn is connected to Node MCU.
Stepper Motor 28BYJ-48 with ULN2003 Driver & ESP32:
Stepper Motor 28BYJ-48 with ULN2003 Driver are connected as shown. Driver board VCC and GND are connected to 3.3 volts DC and ground pin of ESP32. Connect the driver board’s IN1, IN2, IN3, and IN4 to ESP32 digital pins GPIO8, GPIO9, GPIO10, and GPIO11, respectively. The stepper motor can be powered directly from the ESP32, but this is not recommended because the motor can generate electrical noise on its power supply lines, which may damage the ESP32. Hence the Stepper Motor 28BYJ-48 is connected to ULN2003 Driver which in turn is connected to ESP32.