

Matter thread relay r1
An Ardunio project for Apple Home matter/thread board to drive four relays
- Size
- 92.2 × 66.4 mm
- Copper layers
- 2
- Thickness
- 1.6 mm
- Parts
- 48
- Nets
- 46
- Pads
- 174
- Tracks, vias
- 320, 81
- Pours
- 2
- Routed
- Yes
- KiCad
- KiCad 9.0 (file 20241229)
- Created
- 2 Jun 2026
- Updated
- 7 Jun 2026
Overview
Matter thread relay r1 is an open-source printed circuit board by jerryok826, from the jerryok826/ardunio_matter_thread_relay repository on GitHub, published under the MIT licence. It is a 2-layer board of 92.2 × 66.4 mm with 48 parts on 46 nets, routed with 320 tracks and 81 vias.
It is built around the 1N4448W and DMG2302U. Its parts include 19 resistors, 6 capacitors, 4 diodes, 4 switches and 3 ICs. It belongs with the home automation and IoT boards and the AVR (ATmega, ATtiny) boards of this library.
Main components
2README
README.mdMatter-over-Thread 4-Channel Intelligent Relay Controller


The board shown below is an Arduino Matter/Thread relay controller designed for use with an Apple HomeKit network. It uses an Arduino Nano Matter processor to control four onboard relays, which can be used to operate motors, lights, valves, or other electrical loads.
Each relay can be controlled locally using the onboard pushbuttons, allowing users to manually enable or disable individual outputs. Through the Apple Home app on an iPhone, each relay can also be monitored and controlled remotely from anywhere with internet access.
An integrated OLED display provides system status information, including Thread network signal strength. During initial setup, the display presents a QR code that can be scanned to quickly add the device to the Apple Home app.
The board also includes an I²C Qwiic connector for attaching external sensors and peripherals. For example, a rain sensor could be connected to automatically disable irrigation valves during rainfall, helping conserve water and prevent overwatering.
Status: The board completely supports relay control. The I²C Qwiic connector is wired wrong. There are other physical placements that need updating. So the board will be turned. Gerber files will be punished after these changes.
An industrial-grade, ultra-low-latency 4-Channel Relay Controller built using the Arduino Nano Matter (Silicon Labs MGM240S core). This project connects natively with Apple Home, Home Assistant, and other Matter ecosystems over a self-healing Thread mesh network.
Featuring an asynchronous hardware override architecture, non-blocking FreeRTOS thread watchdogs, and an integrated I2C OLED display that acts as a standalone RF Survey & Walk-Testing Tool, this project is designed for robust, long-term smart home panel automation.
✨ Key Features
- Ecosystem Unified Build: Native Matter protocol integration that auto-populates as four independent, sequential switch endpoints in your smart home application.
- Zero App Dependence Override: Local manual buttons run entirely on edge-triggered Asynchronous Hardware Interrupts. Relays switch locally within microseconds even if your smart home hub is offline or entirely destroyed.
- Anti-Race Watchdog: Implements a non-blocking 50ms throttled execution pacing engine to prevent Matter application layer data collisions and loop freezing.
- Failsafe Boot Protection: Firmware forces relay pins to an explicit
LOWstate prior to opening output drivers. Combined with physical pull-down networks, this eliminates clicks or accidental appliance cycles during microcontroller reboots. - Dual-OLED Matrix Engine: Dynamic runtime support for both SH1106 and SSD1306 I2C displays via a simple preprocessor toggle.
- Standalone RF Survey Tool: Displays a dynamic pairing QR code on boot, then transitions automatically into a real-time system dashboard mapping your Thread Node Role and precise signal attenuation metrics (
dBm) on a fast 3-second cycle.
🛠️ Hardware Requirements & Pinout
Core Microcontroller
- Arduino Nano Matter (Silicon Labs MGM240S)
Supported Displays
- 0.96" I2C OLED Display (SH1106 Recommended for native border alignment, or SSD1306)
Physical Netlist Connection Map
| Arduino Pin | Hardware Component | Electrical Specification / Circuit Design |
|---|---|---|
| D2 | Relay 1 Trigger Output | Active-HIGH Latch (Must use 10kΩ external Pull-Down to GND) |
| D3 | Relay 2 Trigger Output | Active-HIGH Latch (Must use 10kΩ external Pull-Down to GND) |
| D4 | Relay 3 Trigger Output | Active-HIGH Latch (Must use 10kΩ external Pull-Down to GND) |
| D5 | Relay 4 Trigger Output | Active-HIGH Latch (Must use 10kΩ external Pull-Down to GND) |
| D6 | Manual Button 1 Input | Short-to-GND Momentary Switch (Relies on internal INPUT_PULLUP) |
| D7 | Manual Button 2 Input | Short-to-GND Momentary Switch (Relies on internal INPUT_PULLUP) |
| D8 | Manual Button 3 Input | Short-to-GND Momentary Switch (Relies on internal INPUT_PULLUP) |
| D9 | Manual Button 4 Input | Short-to-GND Momentary Switch (Relies on internal INPUT_PULLUP) |
| A4 / SDA | OLED Serial Data Line | I2C Data (Include physical 4.7kΩ external Pull-Up to 3.3V) |
| A5 / SCL | OLED Serial Clock Line | I2C Clock (Include physical 4.7kΩ external Pull-Up to 3.3V) |
| BTN_BUILTIN | Factory Reset Trigger | Physical button on Nano Matter. Hold 10s to wipe Matter Fabric. |
⚠️ CRITICAL DEVELOPER WARNING: The Arduino Nano Matter GPIO pins safely output a maximum of 4mA to 8mA. Standard mechanical relay coils draw between 70mA and 100mA. Do not wire relay coils directly to the Arduino pins. You must use transistor switches (e.g., 2N2222) or optocouplers (e.g., PC817) on your custom PCB to isolate the driver currents.
💻 Firmware Installation & Configuration
1. Prerequisites
Ensure your Arduino IDE environment is properly updated:
- Open the Arduino IDE, go to Tools > Board > Boards Manager and install the Arduino Nano Matter board package.
- Go to Tools > Manage Libraries and install these exact dependencies:
SSD1306Ascii(by Bill Greiman)QRCode(by Richard Moore)
2. IDE Compilation Configuration
Before flashing the firmware, you must configure the low-level stack settings:
- Go to Tools > Protocol Stack and select Matter.
- Note: If this is left on "None", the compiler will completely ignore all Matter initialization sequences.
3. Display Selection Toggle
At the very top of the primary sketch file, uncomment the specific preprocessor definition that matches your physical OLED module hardware:
// UNCOMMENT ONLY ONE of the options below to match your physical OLED panel:
#define DISPLAY_TYPE_SH1106 // Use this if your screen has an SH1106 controller
// #define DISPLAY_TYPE_SSD1306 // Use this if your screen has a true SSD1306 controller📱 Provisioning & First-Time Setup
- Flash the firmware to your board and open your serial monitor at 115200 baud.
- Upon boot, the board will automatically check its secure enclave storage rows. If it is uncommissioned, a custom Version 3 QR Matrix will automatically render on the left side of your OLED screen.
- Open your native smart home app (e.g., Apple Home) on your iPhone.
- Tap Add Accessory and point your camera at the OLED glass panel.
- Alternative Manual Flow: If the camera cannot capture the display grid due to enclosure glare, tap More Options / I Don't Have a Code, select the module from the nearby Bluetooth list, and manually input the static 11-digit setup passcode:
text Manual Setup Code: 3497-0259-332 - Keep your phone close to the hardware for the first 30 seconds. The initial handshake executes over Bluetooth Low Energy (BLE) before moving the board permanently to your home's Thread Mesh Network.
Parts
48| Qty | Value | Footprint | References |
|---|---|---|---|
| 6 | 10K | Resistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolder | R1, R2, R12, R13, R14, R15 |
| 4 | 100R | Resistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolder | R16, R17, R18, R19 |
| 4 | 560R | Resistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolder | R4, R5, R6, R7 |
| 4 | MountingHole_Pad | MountingHole:MountingHole_3.2mm_M3_ISO7380_Pad_TopBottom | H1, H2, H4, H6 |
| 4 | TS29-1212-1-R-300-D | jerrys_library:SW_TS29-1212-1-R-300-D | S1, S2, S3, S4 |
| 3 | 0.1uF | Capacitor_SMD:C_0805_2012Metric_Pad1.18x1.45mm_HandSolder | C1, C2, C6 |
| 3 | GND | TestPoint:TestPoint_THTPad_D2.0mm_Drill1.0mm | GND1, GND2, GND3 |
| 2 | 1N4448W | Diode_SMD:D_SOD-123 | D3, D4 |
| 2 | RED LED | LED_SMD:LED_1206_3216Metric_Pad1.42x1.75mm_HandSolder | D1, D2 |
| 2 | o.1uF | Capacitor_SMD:C_0805_2012Metric_Pad1.18x1.45mm_HandSolder | C4, C5 |
| 1 | +5V Pwr | TerminalBlock_CUI:TerminalBlock_CUI_TB007-508-02_1x02_P5.08mm_Horizontal | J2 |
| 1 | 100K | Resistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolder | R10 |
| 1 | 10R | Resistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolder | R11 |
| 1 | 10uF | Capacitor_SMD:C_0805_2012Metric_Pad1.18x1.45mm_HandSolder | C3 |
| 1 | 1K | Resistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolder | R8 |
| 1 | 2.7K | Resistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolder | R3 |
| 1 | 3.3K | Resistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolder | R9 |
| 1 | Buzzer | Buzzer_Beeper:Buzzer_12x9.5RM7.6 | BZ1 |
| 1 | Conn_01x04 | Connector_JST:JST_SH_SM04B-SRSS-TB_1x04-1MP_P1.00mm_Horizontal | J1 |
| 1 | DMG2302U | Package_TO_SOT_SMD:SOT-23 | Q1 |
| 1 | SH1106 | jerrys_library:SH1106 | U3 |
| 1 | SN74AHCT125DR | Package_SO:SO-14_5.3x10.2mm_P1.27mm | U2 |
| 1 | arduino_nano_matter | Module:Arduino_Nano | U1 |
| 1 | relay driver pins | TerminalBlock_CUI:TerminalBlock_CUI_TB007-508-04_1x04_P5.08mm_Horizontal | J3 |
Similar boards
- 4 layers154 × 159 mm

- 2 layers69 × 72 mm

MMv3
MrCroesus/MMv3
MMv3 is the 3rd generation robot platform used to teach the IEEE Micromouse DeCal at UC Berkeley. It was designed with usability, manufacturability, size, and cost in mind.
47 parts16Apache-2.0 - 4 layers40 × 19 mm

- 4 layers45.7 × 90.3 mm

- 2 layers101.6 × 31.8 mm

Pico 12vrgb controller
bluekeyes/pico-12vrgb-hid-controller
4-pin RGB controller using the Pi Pico and USB HID
20 parts9MIT - 2 layers54.1 × 48.6 mm

E Fidget V3
miameows/E-Fidget
Hi there! There's a lot of moving parts with this project right now, so why don't you check out my latest blog post for more info?
29 parts6MIT - 2 layers75.1 × 100 mm

- 2 layers240 × 100 mm

Kha bgt extend
kiu/kha
Overengineered Modular RS-485 Multi-Master 19" Subrack Home Automation / Control
69 parts5
Questions
How big is the Matter thread relay r1 PCB?
It measures 92.2 × 66.4 mm and has 2 copper layers, 1.6 mm thick.
What parts does the Matter thread relay r1 use?
48 parts, built around the 1N4448W and DMG2302U. The full list of its parts is on this page, with links to each part's symbol and footprint where PCBKit's library has them.
Where can I download the Matter thread relay r1 KiCad files?
From the jerryok826/ardunio_matter_thread_relay repository on GitHub, at the commit this page was made from: the board is Hardware/matter_thread_relay_r1.kicad_pcb and its schematic Hardware/matter_thread_relay_r1.kicad_sch. PCBKit opens the board in the browser, with nothing to install.
Can I use the Matter thread relay r1 design in my own project?
Its repository publishes it under the MIT licence: you may reuse it on that licence's terms (keep the author's notice, and for a copyleft licence share your changes alike).