How Do I Use a Relay Module to Control Actuator Direction with Arduino?
A dual-relay module is the simplest way to control actuator direction from an Arduino — no H-bridge IC required. Relays switch the full 12 V / 24 V motor current directly, making them reliable for high-current applications like the PA-17.
When to Use Relays vs H-Bridge
| Feature | Relay Module | H-Bridge (L298N / IBT-2) |
|---|---|---|
| Max current | 10–30 A (depends on relay rating) | 2 A (L298N), 43 A peak (IBT-2) |
| PWM speed control | No — on/off only | Yes — variable speed via PWM |
| Cost | Very low (~$3–5 for dual relay module) | Low–moderate ($3–15) |
| Best for | High-current actuators, simple extend/retract, PA-17 | Speed control, feedback positioning, lower-current models |
Wiring a Dual-Relay DPDT Configuration
You need two SPDT relays wired to form a DPDT (double-pole double-throw) H-bridge equivalent. When Relay 1 is energised and Relay 2 is off, current flows in one direction through the motor. When Relay 2 is on and Relay 1 is off, current reverses.
⚠️ Never energise both relays simultaneously With both relays on, positive supply connects directly to negative — a dead short. Always ensure a brief delay (20–50 ms) between de-energising one relay and energising the other. This is called a "shoot-through prevention" delay.
%2013.58.36.png?width=625&height=579&name=Captura%20de%20Pantalla%202026-03-10%20a%20la(s)%2013.58.36.png)
Flyback Diode Protection
DC motors are inductive loads. When power is cut, the motor generates a voltage spike (back-EMF) that can damage relay contacts over time. Place a 1N4007 flyback diode across the motor terminals (cathode to positive terminal) to absorb these spikes and extend relay life.