Home › Lessons › Embedded (ESP32) › ULN2003 driver array for a stepper

ULN2003 driver array for a stepper

Embedded (ESP32) · Intermediate · about 15 minutes · part of Embedded & IoT

An ESP32 pin can give about 20 mA at 3.3 V; a stepper phase wants 100 mA at 5 V. The ULN2003 has seven Darlington switches, each pulling its output to ground when its input is high, with built-in flyback diodes to the COM pin.

ULN2003 driver array for a stepper: the circuit on the simulator's bench

Open this lesson in the labFree, in your browser, no account needed.

How it works

One half-step every 2 ms is 500 half-steps per second. With 4096 half-steps per output turn that is 500 × 60 ÷ 4096 = 7.32 RPM.

Try it on the bench

  1. Change STEP_MS in the sketch to 1: 1000 steps per second is past what the 28BYJ-48 can follow (about 900), so it misses steps.

Parts on the bench

In the course

Embedded & IoT, module “Actuators”.

More on embedded (esp32)