Overview
The ENM-223-R1 is a configurable smart I/O module designed for 3-phase power quality and energy metering. It includes 3 voltage inputs, 3 current channels (CTs), 2 SPDT relays, 4 buttons, and 4 LEDs, with configuration via USB-C WebConfig and communication via RS-485 (Modbus RTU). It connects to a MicroPLC/MiniPLC for use in energy monitoring, automation, and smart building applications.
Getting Started
Quick Setup Process
Mount & Wire – Install on 35mm DIN rail, connect 24V DC power, sensors, and relay loads.
Configure – Plug in USB-C, open the WebConfig tool in Chrome/Edge, set Modbus address and I/O mapping.
Integrate – Connect to your controller via RS-485 and start automation.
What You Need
ENM-223-R1 module
24V DC SELV power supply
RS-485 cable (twisted pair)
USB-C cable for configuration
Chromium browser (Chrome/Edge)
Web Configuration Steps
Connect USB-C to module and PC
Click "Connect" and select serial port
Set Modbus address (default: 3) and baud rate (default: 19200 8N1)
Configure input actions, mapping, LED modes, and button functions
Settings save automatically to flash
Tech Specs
| Parameter | Details |
|---|---|
| Microcontroller | RP2350, Dual-core ARM Cortex-M0+ |
| Operating Voltage | 3.3V, 5V (logic), 24V DC input |
| Voltage Inputs | 3 (L1/L2/L3–N, 85–265V AC) |
| Current Inputs | 3 (CTs, 333mV/1V RMS) |
| Relay Outputs | 2 (SPDT, 5A @ 250V AC) |
| User Buttons | 4 (configurable) |
| User LEDs | 4 (configurable) |
| Communication | RS-485 (Modbus RTU) |
| Configuration Interface | USB-C (Web Serial) |
| Operating Temperature | 0–40°C |
| Dimensions (W×H×D) | 70 × 90.6 × 67.3 mm |
Documentation
The ENM-223-R1 is open-source hardware! You can build your own board using the following files:
Hardware Design Files
Field Board Schematic: ENM-223-R1-FieldBoard.pdf
MCU Board Schematic: ENM-223-R1-MCUBoard.pdf
System Block Diagram: ENM_SystemBlockDiagram.png
Field Board Diagram: FieldBoard_Diagram.png
MCU Board Diagram: MCUBoard_Diagram.png
Firmware & Software
Firmware Source Code: ENM-223-R1/Firmware/
WebConfig Tool: ConfigToolPage.html
ESPHome Integration Package: default_enm_223_r1_plc.yaml
Mechanical Files:
Dimensional Drawing: ENMDimensions.png
All design files and documentation are available in the HomeMaster GitHub repository.
Input and Output
Voltage & Current Inputs:
3 voltage channels (L1/L2/L3–N)
3 CT inputs (external split-core CTs)
Isolated measurement via ATM90E32AS metering IC
Configurable gains/offsets via WebConfig
Relay Outputs (2 channels):
SPDT contacts (NO/NC/COM)
5A @ 250V AC rating
Controlled via Modbus coils or alarm logic
RC/TVS snubbers recommended for inductive loads
User Interface:
4 Buttons: Configurable for relay override, toggle, alarm acknowledgment
4 LEDs: Configurable steady or blink modes, linked to alarms/overrides
Status LEDs: PWR (power), TX/RX (Modbus activity)
Communication Interfaces
Protocol: Modbus RTU
Role: Slave device
Default Settings: Address 3, 19200 baud, 8 data bits, No parity, 1 stop bit
Supported Functions: Read Coils (0x01), Read Discrete Inputs (0x02), Read Holding Registers (0x03), Read Input Registers (0x04), Write Single Coil (0x05), Write Single Register (0x06)
Modbus Address Map
Coils (Read/Write) – Function Codes 0x01, 0x05
| Address | Name | Type | Description | R/W |
|---|---|---|---|---|
| 00000 | R1_CMD | Coil | Relay 1 command (1=ON, 0=OFF) | R/W |
| 00001 | R2_CMD | Coil | Relay 2 command (1=ON, 0=OFF) | R/W |
| 00610 | ALARM_ACK_L1 | Coil | Acknowledge L1 alarm (write 1) | Write Only |
| 00611 | ALARM_ACK_L2 | Coil | Acknowledge L2 alarm (write 1) | Write Only |
| 00612 | ALARM_ACK_L3 | Coil | Acknowledge L3 alarm (write 1) | Write Only |
| 00613 | ALARM_ACK_TOT | Coil | Acknowledge Totals alarm (write 1) | Write Only |
Discrete Inputs (Read Only) – Function Code 0x02
| Address | Name | Type | Description |
|---|---|---|---|
| 10000 | LED1_STATE | Discrete Input | LED 1 state |
| 10001 | LED2_STATE | Discrete Input | LED 2 state |
| 10002 | LED3_STATE | Discrete Input | LED 3 state |
| 10003 | LED4_STATE | Discrete Input | LED 4 state |
| 10520 | BTN1_STATE | Discrete Input | Button 1 press state |
| 10521 | BTN2_STATE | Discrete Input | Button 2 press state |
| 10522 | BTN3_STATE | Discrete Input | Button 3 press state |
| 10523 | BTN4_STATE | Discrete Input | Button 4 press state |
| 10540 | RLY1_STATE | Discrete Input | Relay 1 actual state |
| 10541 | RLY2_STATE | Discrete Input | Relay 2 actual state |
Holding Registers (Read/Write) – Function Codes 0x03, 0x06, 0x10
| Address | Name | Type | Description | Range/Values |
|---|---|---|---|---|
| 40000 | MODEL_ID | Register | Module model identifier (0x0223) | Read Only |
| 40001 | FW_VERSION | Register | Firmware build YYYYMM | Read Only |
| 40002 | MB_ADDR | Register | Modbus address (1-255) | R/W (1-255) |
| 40003 | MB_BAUD | Register | Baud rate setting | 0=9600, 1=19200, 2=38400, 3=57600, 4=115200 |
| 40004 | MB_PARITY | Register | Parity setting | 0=None, 1=Even, 2=Odd |
| 40010 | SAMPLE_INT | Register | Sample interval (10-5000 ms) | R/W |
| 40011 | LINE_FREQ | Register | Line frequency | 50 or 60 Hz |
| 40012 | SUM_MODE | Register | Power sum mode | 0=algorithmic, 1=absolute |
| 40020-40025 | UGAIN_A-F | Register | Voltage gain A/B/C | 16-bit (0-65535) |
| 40030-40035 | UOFFSET_A-F | Register | Voltage offset A/B/C | S16-bit |
| 40040-40045 | IGAIN_A-F | Register | Current gain A/B/C | 16-bit (0-65535) |
| 40050-40055 | IOFFSET_A-F | Register | Current offset A/B/C | S16-bit |
Input Registers (Read Only) – Function Code 0x04
| Address | Name | Type | Description | Unit | Scaling |
|---|---|---|---|---|---|
| 00100-00102 | URMS_L1-L3 | Register | Voltage L1/L2/L3 | V | ×0.01 |
| 00110-00112 | IRMS_L1-L3 | Register | Current L1/L2/L3 | A | ×0.001 |
| 00200-00207 | P_L1-TOT | Register | Active Power (L1-L3, Totals) | W | 1 |
| 00210-00217 | Q_L1-TOT | Register | Reactive Power (L1-L3, Totals) | var | 1 |
| 00220-00227 | S_L1-TOT | Register | Apparent Power (L1-L3, Totals) | VA | 1 |
| 00240-00243 | PF_L1-TOT | Register | Power Factor L1-L3, Total | - | ×0.001 |
| 00244-00246 | ANGLE_L1-L3 | Register | Phase Angle L1-L3 | ° | ×0.1 |
| 00250 | FREQUENCY | Register | Frequency | Hz | ×0.01 |
| 00251 | TEMPERATURE | Register | Internal temperature | °C | 1 |
| 00300-00307 | AP_IMP_L1-TOT | Register | Active Energy import (+Wh) | Wh | 1 |
| 00308-00315 | AP_EXP_L1-TOT | Register | Active Energy export (-Wh) | Wh | 1 |
| 00316-00323 | RP_IND_L1-TOT | Register | Reactive Energy inductive (+varh) | varh | 1 |
| 00324-00331 | RP_CAP_L1-TOT | Register | Reactive Energy capacitive (-varh) | varh | 1 |
| 00332-00339 | APP_L1-TOT | Register | Apparent Energy (VAh) | VAh | 1 |
Home Assistant & ESPHome Integration Guide
Overview
The ENM-223-R1 integrates seamlessly with Home Assistant via ESPHome using the Modbus RTU protocol. This guide covers both quick integration using our pre-built package and manual configuration for advanced users.
Prerequisites
Before starting, ensure you have:
ESPHome device (HomeMaster MiniPLC/MicroPLC or any ESP32/ESP8266 with RS-485)
RS-485 connection between ESP device and ENM-223-R1
24V power to ENM-223-R1 module
Home Assistant with ESPHome add-on installed
RS‑485 Configuration
uart:
id: uart_modbus
tx_pin: GPIO17
rx_pin: GPIO16
baud_rate: 19200
parity: NONE
stop_bits: 1
modbus:
id: modbus_bus
uart_id: uart_modbus
Import ENM-223-R1 Package:
packages:
enm_223_r1:
url: https://github.com/isystemsautomation/HOMEMASTER
ref: main
files:
- path: ENM-223-R1/Firmware/default_enm_223_r1_plc.yaml
vars:
enm_prefix: "Main Panel" # Custom name for your entities
enm_id: main_module # Unique internal ID
enm_address: 3 # Must match WebConfig Modbus address
refresh: 1d
Customize Variables:
enm_prefix: Appears in entity names (e.g., "Main Panel Voltage L1")
enm_id: Internal identifier for the module
enm_address: Modbus address (must match WebConfig setting)
Example with Multiple ENMs:
packages:
enm_main:
url: https://github.com/isystemsautomation/HOMEMASTER
ref: main
files:
- path: ENM-223-R1/Firmware/default_enm_223_r1_plc.yaml
vars:
enm_prefix: "Main Panel"
enm_id: main_module
enm_address: 3
refresh: 1d
enm_solar:
url: https://github.com/isystemsautomation/HOMEMASTER
ref: main
files:
- path: ENM-223-R1/Firmware/default_enm_223_r1_plc.yaml
vars:
enm_prefix: "Solar"
enm_id: solar_module
enm_address: 4
refresh: 1d
Programming
Supported Development Environments
Arduino IDE with RP2350 support
PlatformIO with RP2350 toolchain
MicroPython (community builds available)
Firmware Flashing
Connect USB-C to PC
Hold Buttons 3 + 4 to enter BOOT mode
Hold Buttons 1 + 2 to RESET the module
Upload via:
UF2 drag-and-drop to mounted drive, OR
PlatformIO/Arduino IDE upload
Pin Mapping (Default Firmware)
| Pin/Net Name | GPIO/Port | Function | Type |
|---|---|---|---|
| Voltage Sensing | |||
| VA_IN | ADC1_CH0 | Phase A Voltage | Analog Input |
| VB_IN | ADC1_CH1 | Phase B Voltage | Analog Input |
| VC_IN | ADC1_CH2 | Phase C Voltage | Analog Input |
| Current Sensing | |||
| IA_IN | ADC1_CH3 | Phase A Current | Analog Input |
| IB_IN | ADC1_CH4 | Phase B Current | Analog Input |
| IC_IN | ADC1_CH5 | Phase C Current | Analog Input |
| Digital I/O | |||
| DI1 | GPIO6 | Digital Input 1 | Digital Input |
| DI2 | GPIO7 | Digital Input 2 | Digital Input |
| DO1 | GPIO8 | Relay Output 1 | Digital Output |
| DO2 | GPIO9 | Relay Output 2 | Digital Output |
| Communication | |||
| TX_485 | GPIO17 | RS-485 Transmit | UART |
| RX_485 | GPIO16 | RS-485 Receive | UART |
| USB_DM | USB_DM | USB Data- | USB |
| USB_DP | USB_DP | USB Data+ | USB |
Related products
These other products might interest you