Solid state relay SSR-40DA (AC load) with ESP32
Supply 3-32 V
Bus GPIO
Pins and ESP32 wiring
| Pin | Role | ESP32 pin | Notes |
|---|---|---|---|
| 3(+) | Input (the ESP32 drives it) | D25 | Control + (3 to 32 V DC). Takes about 10 mA: HIGH = load on |
| 4(-) | Ground | GND | Control - |
| 1 | Not wired to the ESP32 | — | AC load terminal. Mains voltage is dangerous. Does not switch DC loads |
| 2 | Not wired to the ESP32 | — | AC load terminal |
Suggested wiring for the 30-pin ESP32 DevKit, avoiding flash, input-only and strapping pins. BoardPilot checks it for you as you wire.
Starter code (Arduino)
void setup() { pinMode(25, OUTPUT); } // 3(+)
void loop() {
digitalWrite(25, HIGH);
delay(500);
digitalWrite(25, LOW);
delay(500);
}
Sources
- Fotek SSR series datasheet, Input 3 to 32 VDC; output 24 to 380 VAC; zero-cross
Try it in 3D in BoardPilot
Related parts
18650 Li-ion cell in holder28BYJ-48 stepper + ULN2003 driver433 MHz transmitter (FS1000A)74HC595 shift registerA4988 stepper driverActive buzzer
Part data: CC BY 4.0, free to reuse with credit to BoardPilot.