Sprinkler3 irrigation controller
A 15-zone ESP32 sprinkler controller that works with Home Assistant but doesn't depend on it. Schedules live on the device, so the lawn still gets watered when Wi-Fi is down.

I wanted a sprinkler controller that works with Home Assistant but doesn’t depend on it. Schedules live on the device, time comes from a battery-backed RTC, and a 20×4 LCD with four buttons covers everyday use. If Wi-Fi or Home Assistant goes down, the lawn still gets watered on time.
hardware
- Board: ESP32 16-relay board (
ESP32_Relay_X16 V1.2), relays driven through two chained 74HC595 shift registers - Valves: 15 zone valves, plus a master valve on relay 16
- Clock: DS1307 RTC module, so the controller boots with valid time even with no network
- Display: LCD 2004 with a PCF8574 I2C backpack
- Input: 4-key tactile module (STOP/back, previous, next, OK). The labels engraved on the printed lid are from an earlier menu layout; it wasn’t worth a reprint just to rename them.
- Rain sensor: Rain Bird WR2 wireless sensor. It’s wired in, but the scheduler doesn’t use it yet
- Case: 3D-printed, written in OpenSCAD. It’s a remix of pbtec’s Stable and waterproof OpenSCAD case (CC BY-NC-SA). I added the LCD window and standoffs, the cutouts and bosses for the button module, and the engraved labels. Everything is parametric, so the whole front panel is a few variables.


how-it-works
- Runs offline. All the logic runs on the device. Sixteen schedule slots (time, days, target zone or group) are stored on the ESP32 and survive reboots. Time comes from SNTP or Home Assistant, with the RTC as fallback. It never waters when the clock is invalid.
- One zone at a time. A single queue drives every valve, so pressure stays steady, and the master valve opens only while a zone is running.
- Seasonal adjust and rain delay. One “water budget” multiplier (0–200%) scales every run. Rain delay skips N days.
- Usable without a phone. From the front panel you can start a zone, a group or all zones, edit schedules, zone durations and groups, set the water budget and rain delay, set the clock, and check network info or run a Wi-Fi scan.
- Still a smart-home device. Native Home Assistant API, a built-in web page, OTA updates, and a fallback hotspot with a captive portal.

software
- ESPHome: a YAML config, plus a C++ header (
sprinkler3_ui.h) for the front-panel menus