Sixteen Relays 2A/24V 8-Layer Stackable HAT for Raspberry Pi
Sixteen relays with status LEDs and Normal Open contacts; RS485 and Hardware Watchdog.
Overview
Sixteen-relay HAT for Raspberry Pi with stackable design for high-density load control. Sixteen normally-open relay contacts, bicolor status LEDs, RS485/MODBUS interface, and a hardware watchdog in a compact, stackable platform for industrial and building automation applications.
- Sixteen NO relay contacts rated 2A/24VAC/DC
- Eight bicolor status LEDs show the on/off state of all 16 relays
- Up to 8 cards stackable — 128 relays per Raspberry Pi
- RS485/MODBUS port for direct PLC/SCADA integration
- Hardware watchdog ensures continuous unattended operation
- Uses only I2C — all 24 remaining GPIO pins stay free
- Compatible with all Raspberry Pi versions from Zero to 5
Works with Open Automation Software
Compatible with widely used tools for control, monitoring, and system integration.
INTERFACES AND I/O
| I/O's | Communication | Software Integration |
|---|---|---|
| • Sixteen Relay Outputs (NO contacts, 2A/24VAC/DC) | • I2C Port to Raspberry Pi | • Command Line |
| • RS485/MODBUS Port | • Python Library | |
| • Node-RED nodes | ||
| • CODESYS Driver | ||
| • OpenPLC Module | ||
| • Home Assistant | ||
| • Arduino Library | ||
| Other Features | ||
| • Software relay self-test cycles all relays on and off at 0.5-second intervals | ||
| • Eight bicolor status LEDs show the on/off state of all 16 relays | ||
| • 5V onboard power supply also powers the Raspberry Pi | ||
| • General purpose reset pushbutton (GPIO 26) | • Pluggable Connectors 26–16 AWG wires | |
| • On Board Hardware Watchdog and resettable fuse | • Eight Level Stackable | |
DESCRIPTION
The Sixteen Relays HAT provides a simple and scalable way to control large numbers of loads with Raspberry Pi. Stackable to 8 layers, a single Raspberry Pi can manage up to 128 relays in a compact, modular form factor.
Sixteen normally-open relay contacts rated 2A/24VAC/DC, connected via pluggable screw terminals. Electrical endurance: minimum 105 cycles at full load; mechanical endurance: minimum 107 cycles.
Eight bicolor LEDs show the on/off state of all 16 relays — one color per relay per LED. A dedicated power LED confirms when the board is powered.
The hardware watchdog automatically power-cycles the Raspberry Pi if the software becomes unresponsive, ensuring continuous operation in unattended deployments.
Onboard RS485 port configurable as a MODBUS RTU slave — accessible by any PLC or SCADA without a Raspberry Pi — or as a direct RS485 bridge for the Raspberry Pi, via DIP switch.
A momentary pushbutton at the board edge routes to GPIO 26. A user script monitoring this pin can issue a clean shutdown command, preventing SD card corruption from hard power cuts.
A single command cycles each relay on and off at 0.5-second intervals. The relay clicking and LED activity confirm all 16 relays are functional before deployment.
An onboard 3A resettable fuse protects against accidental shorts on the power supply.
TECHNICAL DETAILS
CARD LAYOUT

MECHANICAL SPECIFICATIONS

DIP SWITCH AND STACKING
The onboard six-position DIP switch configures both the stack address and the RS485 port behavior. Cards of different Sequent HAT types can be freely mixed in the same stack.
| Switch | Name | Function |
|---|---|---|
| ID0 | Stack ID bit 0 | Binary stack address bit 0 (LSB) — sets card level 0–7 |
| ID1 | Stack ID bit 1 | Binary stack address bit 1 |
| ID2 | Stack ID bit 2 | Binary stack address bit 2 (MSB) |
| RX | RS485 RX select | ON: Raspberry Pi receives RS485 directly |
| TX | RS485 TX select | ON: Raspberry Pi drives RS485 directly |
| TERM | RS485 termination | Enable on the last card in an RS485 chain to prevent signal reflections |
ELECTRICAL SPECIFICATIONS
| Power | |
|---|---|
| Power supply | 5V/8A pluggable connector with reverse polarity protection |
| Power consumption (relays off) | 10 mA |
| Power per relay (energized) | ~80 mA |
| Onboard resettable fuse | 3 A |
| Relay Outputs | |
|---|---|
| Contact type | Normally Open (NO) |
| Contact rating | 2A / 24VAC/DC |
| Electrical endurance | Min. 105 cycles at 1,800 operations/hour, full load |
| Mechanical endurance | Min. 107 cycles at 18,000 operations/hour, no load |
POWER REQUIREMENTS
Power supply: The card requires 5V to operate and can be powered from the Raspberry Pi GPIO or from its own 2-pin pluggable connector. If power is applied to the board's connector, no separate Raspberry Pi power supply is needed. The board draws 10mA with all relays off; each relay coil requires approximately 80mA when energized.
PLUGGABLE CONNECTORS
All relay outputs connect via pluggable screw terminal connectors accepting wire gauges from 26 to 16 AWG. Connectors can be unplugged from the board for convenient field wiring and debugging without disturbing the rest of the installation.
COMMUNICATION INTERFACES
RESET PUSHBUTTON
Shutting down the Raspberry Pi by turning off the power can result in SD card failure. To prevent this, a shutdown command must be issued before cutting power — but that normally requires a monitor, keyboard, and mouse connected to the Pi.
A momentary pushbutton installed at the edge of the Sixteen Relays card provides a convenient way to shut down the Raspberry Pi. The button is routed to pin 37 (GPIO 26). Write a script that monitors this pin and, if held for more than a desired duration, issues the shutdown command.
HARDWARE WATCHDOG
The Sixteen Relays HAT includes a hardware watchdog that ensures your system automatically recovers if the Raspberry Pi software becomes unresponsive. The watchdog is disabled at power-up and activates after it receives the first reset command from the Raspberry Pi. The default running timeout is 120 seconds and the off period is 10 seconds; both are configurable from the command line.
| Watchdog Parameters | |
|---|---|
| Initial timeout period | Configurable — allows time for Raspberry Pi to boot and start the application |
| Running timeout period | Configurable — normal operating timeout (default: 120 seconds) |
| Off period | Configurable — duration the Raspberry Pi power is cut when timeout triggers (default: 10 seconds) |
| Reset counter | Stored in non-volatile flash; can be read or cleared at any time |
For a full list of watchdog commands, run: 16relind -h
COMPATIBILITY
| Interface | I2C |
| GPIO used | GPIO2 (SDA), GPIO3 (SCL) — 2 pins only; remaining 24 GPIO pins stay free |
| Max stack | 8 cards of each type; different Sequent HATs can be freely mixed with virtually no upper limit on total I/O |
| Compatible with | All Raspberry Pi versions from Zero to 5 (40-pin GPIO header) |
FIRMWARE UPDATE
The onboard microcontroller firmware can be updated in the field. The update tool downloads the latest firmware from Sequent Microsystems' servers and flashes it to the board over I2C.
Running the Update
~$ cd ~/16relind-rpi/update/
~/16relind-rpi/update$ ./update <id>
Replace <id> with the board stack address (0-7). Full instructions including recovery procedures are available at:
https://github.com/SequentMicrosystems/16relind-rpi/tree/master/update/README.md
DOWNLOADS
| User's Guide (PDF) | Schematics (PDF) | CAD | Software & Integrations |
|---|---|---|---|
| User's Guide V1.0 | Hardware Schematic V2.0 | 3D Printing Enclosure | Command Line |
| Hardware Schematic V4.1 | 2D CAD Drawing | Python Library | |
| V4.1 3D STEP Model | Node-RED nodes | ||
| MODBUS interface | |||
| CODESYS Library | |||
| Home Assistant | |||
| Arduino Library |
COMPLIANCE
RoHS and REACH Compliance Declaration
WHAT'S INCLUDED
When you purchase the card you will receive the following items:
| 1. Sixteen Relays HAT for Raspberry Pi |
|---|
![]() |
| 2. Mounting Hardware | |
|---|---|
![]() |
|
| 3. Connector Plugs for all Relay Outputs | |
|---|---|
![]() |
|
QUICK START
- Plug your card on top of your Raspberry Pi and power up the system.
- Enable I2C communication on Raspberry Pi using
raspi-config. - Install the software from GitHub:
~$ git clone https://github.com/SequentMicrosystems/16relind-rpi.git~$ cd /home/pi/16relind-rpi~/16relind-rpi$ sudo make install~/16relind-rpi$ 16relind
The program will respond with a list of available commands. To read more about the CLI, please refer to the README file. If you would rather use a different platform, you can access the same functionality through dedicated, ready-to-use integrations in the Downloads tab above.
Expand Your System
-
In stockEight 24-Bit Analog Inputs DAQ 8-Layer Stackable HAT for Raspberry Pi
Eight Differential or Common Ground 24 bit inputs software selectable to ±0.75V, ±1.5V, ±3V, ±6V, ±12V, ±24V with status LEDs; RS485, Watchdog. -
In stockEight Thermocouples DAQ 8-Layer Stackable HAT for Raspberry Pi
Read eight thermocouples type J, K, T, N, E, B, R and S; 0.1% accuracy through calibration; RS485, Watchdog. -
In stockSmart Fan HAT the Best Cooling Solution for Raspberry Pi
PWM controlled 40x40x10mm Fan keeps Raspberry Pi temperature constant; Stackable with any other HAT. -
In stockDIN-RAIL Kit Type1 Parallel Mount for Raspberry Pi
Install Raspberry Pi and multiple HATs parallel on the DIN-Rail; 90% rotation; Raspberry Pi 1 to 5.










