If you need low-cost, low-speed, high-precision positioning for a load under 500g-cm, a ULN2003 stepper motor setup is the standard starting point. The ULN2003 is not a smart chopper driver; it is a Darlington transistor array that acts as a high-current switch for unipolar stepper coils. It demands a unipolar motor (almost always the ubiquitous 28BYJ-48), a microcontroller to sequence the GPIO pins, and an external power supply capable of delivering at least 1A at 5V.
While it is the most common motor driver included in beginner kits, misapplying it to loads that require high running torque or dynamic acceleration will result in immediate stalling. Below is a complete guide to selecting, wiring, and sizing this specific drive architecture.
Motor Type Selection: Where the ULN2003 Stepper Motor Fits
Before committing to the ULN2003, you must verify that a unipolar stepper matches your load profile. The ULN2003 cannot drive bipolar steppers (which require H-bridges to reverse current flow) and cannot perform true microstepping. Here is how the unipolar stepper compares to other common actuator types in embedded projects.
| Motor Type | Torque Curve Profile | Control Complexity | Typical Cost (2026) | Best Load Profile |
|---|---|---|---|---|
| Unipolar Stepper (ULN2003) | High holding torque, steep drop-off at speed. Max ~300 RPM. | Low. Requires 4 GPIO pins for step sequencing. | $2.00 - $4.00 | Low-speed, high-precision, low-inertia loads (dials, light dampers). |
| Bipolar Stepper (A4988/TMC2209) | Flat torque curve up to mid-speed. Capable of 1000+ RPM. | Medium. Requires Step/Dir pins and current-limit tuning. | $8.00 - $15.00 | CNC, 3D printers, high-speed linear actuators. |
| Brushed DC Motor | Max torque at stall, drops linearly with speed. | Low for speed, High for position (requires encoder). | $3.00 - $8.00 | Wheels, conveyors, high-speed/low-precision rotation. |
| RC Servo | High torque within a limited 180°/360° arc. | Very Low. Single PWM pin for absolute position. | $5.00 - $25.00 | Robotic arms, camera gimbals, RC linkages. |
Which motor type fits this load profile? Choose the ULN2003 stepper motor setup when you need open-loop positional accuracy (knowing exactly where the shaft is without an encoder) at very low speeds, and your budget is strictly constrained. If your application requires rapid acceleration, high RPM, or driving a heavy lead screw, you must upgrade to a bipolar stepper with a chopper driver like the TMC2209.
ULN2003 and 28BYJ-48 Wiring & Terminal Identification
The ULN2003 chip itself is just a 16-pin DIP IC, but in embedded projects, it is almost exclusively used on a red breakout board paired with a 28BYJ-48 unipolar stepper. Understanding the internal wiring of the motor is critical to avoid shorting the coils.
The 28BYJ-48 Internal Wiring
The 28BYJ-48 is a 5-wire unipolar motor. It contains two center-tapped coils. The center taps are tied together internally and brought out as the Red wire. The remaining four wires connect to the ends of the coils.
- Red: Common center tap (VCC / Positive)
- Pink & Orange: Coil 1 ends
- Yellow & Blue: Coil 2 ends
ULN2003 Breakout Board Terminals
| Pin / Header | Function | Connection Target |
|---|---|---|
| IN1, IN2, IN3, IN4 | Logic Inputs (Active HIGH) | Microcontroller GPIO pins (e.g., ESP32 D5, D4, D3, D2) |
| VCC (Screw terminal) | Motor Power Positive | External 5V Power Supply Positive |
| GND (Screw terminal) | Motor Power & Logic Ground | External 5V PSU Ground & Microcontroller GND |
| Motor Connector (White) | 5-pin JST output | 28BYJ-48 motor plug (Red wire goes to the pin marked with a 'V' or '+') |
| Power Jumper | Bridges VCC to motor common | Leave ON for 5V. Remove if using a 12V variant of the motor. |
Sizing Rules, Load Profiles, and Failure Signatures
The most common mistake makers make with the ULN2003 stepper motor is assuming the 'holding torque' specification translates to 'running torque'. It does not.
Sizing Rule of Thumb and Worked Example
The Rule: Size your motor so that the required running torque is no more than 50% of the motor's rated holding torque. This provides a safety factor of 2 to handle friction, inertia, and voltage drops.
Worked Load Example: You are building a motorized camera slider. The camera rig weighs 300g (0.3 kg). It rests on a friction-drive wheel with a radius of 2 cm (0.02 m) attached directly to the 28BYJ-48 shaft.
Force (F) = mass × gravity = 0.3 kg × 9.81 m/s² = 2.94 N.
Required Torque (T) = F × radius = 2.94 N × 0.02 m = 0.0588 N·m (or 58.8 mN·m).
The 28BYJ-48 datasheet lists a holding torque of roughly 34.3 mN·m (often marketed as 300-350 g-cm). However, its pull-out (running) torque at even a modest 100 RPM drops to approximately 15 mN·m. Because your load requires 58.8 mN·m, this motor will instantly stall. To make this work with a ULN2003, you must add a gear reduction (e.g., a 10:1 worm gear) to multiply the torque at the expense of speed, or switch to a NEMA 17 bipolar stepper.
Failure Signatures and Diagnostics
When a unipolar stepper driven by a ULN2003 fails, it rarely fails silently. Look for these specific signatures:
- Humming / Whining without movement: This is a stall or resonance issue. If it happens at startup, your acceleration ramp is too aggressive. If it happens at a specific mid-range speed, you have hit the motor's mechanical resonance frequency. Fix: Switch from a 4-step full-step sequence to an 8-step half-step sequence to smooth the torque delivery and dampen resonance.
- Overheating (Chip and Motor): The ULN2003 uses Darlington pairs, which have a high collector-emitter saturation voltage (Vce(sat)) of about 1V to 1.5V. At 500mA per coil, the chip dissipates up to 1W of heat per channel. Furthermore, if your code leaves the coils energized at a standstill, the motor will draw continuous current. Fix: Implement a 'sleep' or 'coast' function in your code that sets all GPIO pins LOW when the motor reaches its target position, cutting power to the coils.
- Erratic Stepping / Missed Steps: Often caused by voltage sag. If your 5V power supply dips below 4.5V under load, the ULN2003 logic thresholds and coil magnetic fields collapse. Fix: Measure the VCC screw terminal with a multimeter while the motor is running. If it drops, upgrade your power supply or add a 470µF electrolytic capacitor across the VCC and GND terminals.
Microcontroller Integration and Drive Logic
The ULN2003 demands a microcontroller to handle the step sequencing. Unlike modern drivers that only need a 'Step' and 'Direction' pulse, the ULN2003 requires you to manually toggle the four coil phases in the correct order.
For Arduino and ESP32 environments, do not write your own blocking delay() loops to sequence the motor. This will freeze your main program and cause missed steps if other tasks (like reading sensors or handling WiFi) interrupt the timing. Instead, use the AccelStepper library, which handles non-blocking acceleration ramps and half-stepping natively.
Crucial 28BYJ-48 Gear Ratio Gotcha
If your project requires precise angular positioning (e.g., turning exactly 90 degrees), you must account for a known manufacturing quirk. The 28BYJ-48 is marketed with a 1/64 gear reduction ratio. In reality, the physical gear train yields a ratio of 1/63.684.
If you command 2048 steps (the nominal amount for one full 360° revolution), the shaft will actually rotate slightly more than 360°. Over multiple revolutions, this error compounds, causing severe positional drift. For precise closed-loop applications, calibrate your steps-per-revolution constant to exactly 4096 half-steps (or 4075.77 if mathematically correcting for the exact physical ratio) in your library initialization.
By respecting the torque limitations, providing adequate external current, and utilizing non-blocking half-step sequencing, the ULN2003 stepper motor remains an unbeatable, low-cost solution for light-duty embedded positioning tasks.






