TapHome
Community Beta · unverified Energy & metering

Deye SUN-xK-SG04LP3-EU / SG05LP3-EU

Deye SUN-xK-SG04LP3-EU three-phase low-voltage hybrid inverter in TapHome over Modbus RTU on the RS-485 Modbus port (RJ45). Reads PV production, load, grid import and export, battery power and state of charge for the energy flow, plus temperatures, faults and warnings. Sets the work mode, solar sell, grid charging, battery current limits and a six-window Time of Use schedule.

DeyeModbus RTU49 devicesRevision 1.0 Last updated: November 10, 2026

Submitted by Martin Keller

Import into the TapHome appHardware › Modbus › Add from template

Download Template
On this page

Integration guide

The Deye SUN-xK-SG04LP3-EU is a three-phase (230 V / 400 V) low-voltage hybrid inverter with a battery input and two MPPT inputs for the PV array; the manufacturer’s manual covers the SUN-5K, 6K, 8K, 10K and 12K-SG04LP3-EU models. TapHome talks to the inverter over Modbus RTU on RS-485 (9600 baud, 8N1), using the RJ45 port labelled Modbus on the inverter’s communication board.

The template reads PV production, load, grid import and export, battery charge and discharge and battery state of charge, and provides the seven devices of the TapHome energy flow. It also reads battery, grid, PV string and inverter output values, decodes the inverter’s running state, warnings and fault codes into TapHome notifications, and writes the energy management mode, grid charging, battery current limits, generator port use and the six-window Time of Use (TOU) schedule.

Hardware connection

Only qualified personnel may install and wire the inverter. The communication ports sit inside the wiring compartment behind the metal cover; the AC and DC circuits must be disconnected separately before work starts, as described in the manufacturer’s manual.

Communication ports

The RJ45 communication ports are on the right side of the communication board: Parallel_A, Parallel_B, Meter-485, Modbus, BMS and DRM.

Deye SG04LP3-EU communication ports: Parallel_A, Parallel_B, Meter-485, Modbus, BMS and DRM RJ45 connectors with their roles.
PortRole according to the manufacturer
Parallel_A, Parallel_BParallel communication between inverters (CAN interface)
Meter-485Communication with the external energy meter (for example CHNT DTSU666 or Eastron SDM630)
ModbusLabelled “Reserved”; the pinout appendix describes it as the port for remote monitoring
BMSBattery communication (CAN / RS-485)
DRMExternal digital input signals
WIFI/RS232 (separate 9-pin port)Wi-Fi datalogger

TapHome connects to the Modbus port. Do not use the Meter-485 port (it serves the energy meter) or the BMS port (it serves the battery).

The manufacturer marks the Modbus port as “Reserved” and notes that for some hardware versions, this port is useless. Before running the cable, check that the Modbus port on the specific inverter answers; if it does not, the template cannot communicate through it.

Modbus port pinout

RJ45 pin definitions of the BMS, Meter-485 and Modbus ports of the Deye SG04LP3-EU inverter; Modbus port uses pins 1/8 as 485_B, 2/7 as 485_A, 3/6 as GND_485.
RJ45 pin (Modbus port)SignalTapHome RS-485 bus
1, 8485_BB
2, 7485_AA
3, 6GND_485GND
4, 5Not used—

Crimp an RJ45 plug on a twisted-pair cable and connect 485_A to the A terminal and 485_B to the B terminal of the TapHome RS-485 bus. A common GND connection (GND_485) is recommended for longer cable runs.

Only one Modbus master may poll the inverter on the RS-485 line connected to the Modbus port. If another Modbus monitoring device is wired to the same line, disconnect it or use an RS-485 splitter or hub. The manufacturer’s Wi-Fi datalogger uses its own WIFI/RS232 port.

Configuration

Setting the Modbus address

The Modbus address is the Modbus SN field on the inverter display:

  1. On the main screen, press the System Setup icon.
  2. Open Advanced Function and go to the page with Parallel, Modbus SN and EX_Meter For CT (Paral. Set3).
  3. Set Modbus SN and confirm with the tick button.

The template’s import parameter Modbus Slave ID (default 1) must match the Modbus SN. The manual’s screenshot of a single inverter shows 00; set a non-zero value, because Modbus address 0 is reserved for broadcast. In a parallel system the manual gives every inverter its own Modbus SN (01, 02, 03), so each inverter needs its own template import with its own Slave ID.

Communication parameters

ParameterValue
Baud rate9600
Data bits8
ParityNone
Stop bits1
Function codes0x03 (read), 0x10 (write multiple registers)
Modbus Slave ID1 (must match Modbus SN)

Write operations use function code 0x10; the inverter does not support function code 0x06 (write single register).

In TapHome, add a Modbus RTU interface with these parameters on the RS-485 bus the inverter is wired to and import the template with the matching Modbus Slave ID.

Never write to registers 80, 81, 91 and 92 (inverter on/off, factory reset, EEPROM) or to the battery type and protection registers (98–103, 111). The template exposes only user-configurable registers.

Device capabilities

Energy flow

The template provides the seven devices TapHome uses for a complete solar energy flow:

  • PV Production — sum of the PV input powers (registers 672–675) in kW, total energy from the 32-bit counter at registers 534–535.
  • Load — total load power (register 653) and total consumption (registers 527–528).
  • From Grid and To Grid — the signed grid power (register 625) is split: positive values feed From Grid, negative values (as positive numbers) feed To Grid. Total energy from registers 522–523 (from grid) and 524–525 (to grid).
  • From Battery and To Battery — the signed battery power (register 590) is split the same way. Total energy from registers 518–519 (discharge) and 516–517 (charge).
  • Battery (SOC) — battery state of charge, register 588, 0–100 %.

For the Energy Manager smart rule, select the meter Grid - power balance. It reports the signed grid power (register 625): positive when importing from the grid, negative when exporting surplus. From Grid and To Grid are always non-negative and must not be used as the Energy Manager meter.

Battery

  • Battery - temperature — register 586, formula (raw − 1000) / 10.
  • Battery - voltage — register 587; battery current (register 591) and battery power (register 590) as service attributes.
  • Battery - charge today — register 514; energy discharged today (register 515) as a service attribute.

Grid

  • Grid - power balance — signed total grid power (register 625); grid power on L1, L2 and L3 (registers 622–624) and energy bought and sold today (registers 520 and 521) as service attributes.
  • Grid - voltage L1 — register 598; grid voltage L2 and L3 (registers 599 and 600) and grid frequency (register 609) as service attributes.

PV and load

  • PV1 - voltage and PV2 - voltage — registers 676 and 678; the string current (registers 677 and 679) and string power (registers 672 and 673) as service attributes.
  • PV - production today — register 529.
  • Load - consumption today — register 526; load power on L1, L2 and L3 (registers 650–652) as service attributes.

Inverter

  • Inverter - output power total — register 636; output power per phase (registers 633–635), output voltage per phase (registers 627–629) and output frequency (register 638) as service attributes.
  • Backup - output power — register 643.
  • Generator port - power — register 667.
  • DC transformer temperature (register 540) and Heat sink temperature (register 541).

State, warnings and faults

The module shows the Running state (register 500: Standby, Self-check, Normal, Alarm, Fault, Activating), the device type (register 0) and the rated power (registers 20–21) as service attributes. Running state Alarm raises a warning and Fault raises an error.

The warning words (registers 553–554) are decoded into named warnings: fan warning, wrong grid phase sequence, meter communication failure, lithium battery lost and parallel communication quality. The fault words (registers 555–558) are decoded into named errors for fault codes F07, F10, F13, F18, F20, F22–F24, F26, F29, F35, F41, F42, F46–F49, F56, F58 and F62–F64; the meaning of each code and the manufacturer’s remedy are in the fault table of the inverter manual.

Operating settings

  • Settings - energy management mode — Selling first, Zero export to load or Zero export to CT (register 142). According to the manual, Zero export to CT needs the external current transformers on the CT-L1, CT-L2 and CT-L3 inputs.
  • Settings - solar sell — allows surplus PV energy to be sold to the grid in the zero export modes (register 145).
  • Settings - max sell power (register 143) and Settings - max solar sell power (register 340).
  • Settings - grid charging — grid charging of the battery on or off (register 130) and Settings - grid charge current (register 128).
  • Settings - max battery charge current (register 108) and Settings - max battery discharge current (register 109). The manual gives the allowed range per model: 0–120 A (5 kW), 0–150 A (6 kW), 0–190 A (8 kW), 0–210 A (10 kW) and 0–240 A (12 kW).
  • Settings - generator port use — Generator input, Smart load output or Micro-inverter input (register 133).

Time of Use schedule

The inverter’s Time of Use schedule has six windows. The template exposes for each window W1–W6:

  • TOU W1–W6 - start time — HHMM value (for example 1430 = 14:30), registers 148–153.
  • TOU W1–W6 - target SoC — battery target state of charge as a 0–100 % slider, registers 166–171.
  • TOU W1–W6 - grid charging — grid charging during the window on or off; the template changes only bit 0 of registers 172–177 and keeps the other bits.

TOU - enable switches the whole schedule on or off through bit 0 of register 146 and keeps the day-of-week selection (bits 1–7).

According to the manual, the inverter interprets the battery value of each window as a voltage or as a state of charge depending on the Use Batt V / Use Batt % choice in the Battery Setting menu. The target SoC devices are percentages, so the inverter should be set to Use Batt %. When the grid is present, the battery discharges only if Time of Use is ticked.

Troubleshooting

No data / communication failure

  • Check that the cable is in the Modbus port, not in Meter-485 or BMS.
  • Check the A/B polarity (pins 2/7 = 485_A, pins 1/8 = 485_B) and the GND connection.
  • Check that the template’s Modbus Slave ID matches the Modbus SN in Advanced Function and that the Modbus SN is not 0.
  • Check that no other Modbus master is active on the same RS-485 line.
  • The manufacturer states that on some hardware versions the Modbus port is useless. If wiring and address are correct and the inverter still does not answer, the port on that hardware version may not be usable.

Values look 1000× off or nonsensical

Confirm that the inverter is a low-voltage (LV) SG04LP3 or SG05LP3 variant. The high-voltage SG01HP3 family uses different scaling for battery voltage, battery power and PV input power; the template targets LV scaling only.

Battery (SOC) stuck at 0 %

Register 588 returns 0 during some self-check states. Wait until the Running state reaches Normal; the state of charge updates within the next poll interval.

Time of Use settings not applied

Make sure TOU - enable is on and that at least one window has a non-zero start time. Check that the inverter is set to Use Batt % if the target SoC values seem to be ignored.

Meter communication failure warning

The warning is reported by the inverter itself (warning word, register 553) and does not mean that the TapHome connection failed. The energy meter is connected to the Meter-485 port; check its wiring and, when an external meter is used with EX_Meter For CT, the Meter Select setting (CHNT or Eastron) in Advanced Function.

Available devices 49

These devices appear in TapHome after import.

Deye SUN-xK-SG04LP3-EU Module
Service Attributes
Running state
Device type
Rated power

Deye SUN-xK-SG04LP3-EU

Read (module)
VAR state := MODBUSR(H, 500, UInt16);
IF(state = 3, ADDWARNING(64, "Inverter alarm (running state 3)"));
IF(state = 4, ADDERROR(65, "Inverter fault (running state 4)"));

VAR w1 := MODBUSR(H, 553, UInt16);
IF(GETBIT(w1, 1), ADDWARNING(1, "Fan warning"));
IF(GETBIT(w1, 2), ADDWARNING(2, "Grid phase sequence wrong"));
IF(GETBIT(w1, 3), ADDWARNING(3, "Meter communication failure"));

VAR w2 := MODBUSR(H, 554, UInt16);
IF(GETBIT(w2, 14), ADDWARNING(14, "Lithium battery lost"));
IF(GETBIT(w2, 15), ADDWARNING(15, "Parallel communication quality"));

VAR f1 := MODBUSR(H, 555, UInt16);
IF(GETBIT(f1, 6), ADDERROR(6, "F07 DC/DC soft-start fault"));
IF(GETBIT(f1, 9), ADDERROR(9, "F10 Auxiliary power supply fault"));
IF(GETBIT(f1, 12), ADDERROR(12, "F13 Working mode changed"));

VAR f2 := MODBUSR(H, 556, UInt16);
IF(GETBIT(f2, 1), ADDERROR(17, "F18 AC over-current"));
IF(GETBIT(f2, 3), ADDERROR(19, "F20 DC over-current"));
IF(GETBIT(f2, 5), ADDERROR(21, "F22 Emergency stop - inverter locked"));
IF(GETBIT(f2, 6), ADDERROR(22, "F23 Leakage current fault"));
IF(GETBIT(f2, 7), ADDERROR(23, "F24 PV insulation resistance fault"));
IF(GETBIT(f2, 9), ADDERROR(25, "F26 DC bus unbalanced"));
IF(GETBIT(f2, 12), ADDERROR(28, "F29 Parallel CAN bus fault"));

VAR f3 := MODBUSR(H, 557, UInt16);
IF(GETBIT(f3, 2), ADDERROR(34, "F35 No AC grid"));
IF(GETBIT(f3, 8), ADDERROR(40, "F41 Parallel system stop"));
IF(GETBIT(f3, 9), ADDERROR(41, "F42 AC line low voltage"));
IF(GETBIT(f3, 13), ADDERROR(45, "F46 Backup battery fault"));
IF(GETBIT(f3, 14), ADDERROR(46, "F47 AC over-frequency"));
IF(GETBIT(f3, 15), ADDERROR(47, "F48 AC under-frequency"));

VAR f4 := MODBUSR(H, 558, UInt16);
IF(GETBIT(f4, 0), ADDERROR(48, "F49 Backup battery fault"));
IF(GETBIT(f4, 7), ADDERROR(55, "F56 DC bus voltage too low"));
IF(GETBIT(f4, 9), ADDERROR(57, "F58 BMS communication fault"));
IF(GETBIT(f4, 13), ADDERROR(61, "F62 DRM stop"));
IF(GETBIT(f4, 14), ADDERROR(62, "F63 Arc fault"));
IF(GETBIT(f4, 15), ADDERROR(63, "F64 Heat sink temperature too high"));
Service Attributes
Running state
IF(MODBUSR(H, 500, UInt16) = 0, "Standby", IF(MODBUSR(H, 500, UInt16) = 1, "Self-check", IF(MODBUSR(H, 500, UInt16) = 2, "Normal", IF(MODBUSR(H, 500, UInt16) = 3, "Alarm", IF(MODBUSR(H, 500, UInt16) = 4, "Fault", "Activating")))))
Device type
TOSTRING(MODBUSR(H, 0, UInt16))
Rated power
TOSTRING(MODBUSR(H, 20, LittleEndianUint32) / 10, "F1") + " W"
${deviceType_PVProduction} Electricity Meter

${deviceType_PVProduction}

Read total consumption
MODBUSR(H, 534, LittleEndianUint32) / 10
Read demand
(MODBUSR(H, 672, UInt16) + MODBUSR(H, 673, UInt16) + MODBUSR(H, 674, UInt16) + MODBUSR(H, 675, UInt16)) / 1000
${deviceType_PVLoad} Electricity Meter

${deviceType_PVLoad}

Read total consumption
MODBUSR(H, 527, LittleEndianUint32) / 10
Read demand
MODBUSR(H, 653, Int16) / 1000
${deviceType_PVFromGrid} Electricity Meter

${deviceType_PVFromGrid}

Read total consumption
MODBUSR(H, 522, LittleEndianUint32) / 10
Read demand
MAX(MODBUSR(H, 625, Int16), 0) / 1000
${deviceType_PVToGrid} Electricity Meter

${deviceType_PVToGrid}

Read total consumption
MODBUSR(H, 524, LittleEndianUint32) / 10
Read demand
MAX(-MODBUSR(H, 625, Int16), 0) / 1000
${deviceType_PVFromBattery} Electricity Meter

${deviceType_PVFromBattery}

Read total consumption
MODBUSR(H, 518, LittleEndianUint32) / 10
Read demand
MAX(MODBUSR(H, 590, Int16), 0) / 1000
${deviceType_PVToBattery} Electricity Meter

${deviceType_PVToBattery}

Read total consumption
MODBUSR(H, 516, LittleEndianUint32) / 10
Read demand
MAX(-MODBUSR(H, 590, Int16), 0) / 1000
${deviceType_BatterySOC} Analog Input

${deviceType_BatterySOC}

Read input level
MODBUSR(H, 588, UInt16) / 100
Battery - temperature Temperature Sensor

Battery - temperature

Read temperature
(MODBUSR(H, 586, UInt16) - 1000) / 10
Battery - voltage Variable
Service Attributes
Battery current
Battery power

Battery - voltage

Read
MODBUSR(H, 587, UInt16) / 100
Service Attributes
Battery current
TOSTRING(MODBUSR(H, 591, Int16) / 100, "F2") + " A"
Battery power
TOSTRING(MODBUSR(H, 590, Int16), "F0") + " W"
Battery - charge today Variable
Service Attributes
Battery discharge today

Battery - charge today

Read
MODBUSR(H, 514, UInt16) / 10
Service Attributes
Battery discharge today
TOSTRING(MODBUSR(H, 515, UInt16) / 10, "F1") + " kWh"
Grid - voltage L1 Variable
Service Attributes
Grid voltage L2
Grid voltage L3
Grid frequency

Grid - voltage L1

Read
MODBUSR(H, 598, UInt16) / 10
Service Attributes
Grid voltage L2
TOSTRING(MODBUSR(H, 599, UInt16) / 10, "F1") + " V"
Grid voltage L3
TOSTRING(MODBUSR(H, 600, UInt16) / 10, "F1") + " V"
Grid frequency
TOSTRING(MODBUSR(H, 609, UInt16) / 100, "F2") + " Hz"
Grid - power balance Electricity Meter
Service Attributes
Grid power L1
Grid power L2
Grid power L3
Grid energy bought today
Grid energy sold today

Grid - power balance

Read demand
MODBUSR(H, 625, Int16) / 1000
Service Attributes
Grid power L1
TOSTRING(MODBUSR(H, 622, Int16)) + " W"
Grid power L2
TOSTRING(MODBUSR(H, 623, Int16)) + " W"
Grid power L3
TOSTRING(MODBUSR(H, 624, Int16)) + " W"
Grid energy bought today
TOSTRING(MODBUSR(H, 520, UInt16) / 10, "F1") + " kWh"
Grid energy sold today
TOSTRING(MODBUSR(H, 521, UInt16) / 10, "F1") + " kWh"
PV1 - voltage Variable
Service Attributes
PV1 current
PV1 power

PV1 - voltage

Read
MODBUSR(H, 676, UInt16) / 10
Service Attributes
PV1 current
TOSTRING(MODBUSR(H, 677, UInt16) / 10, "F1") + " A"
PV1 power
TOSTRING(MODBUSR(H, 672, UInt16)) + " W"
PV2 - voltage Variable
Service Attributes
PV2 current
PV2 power

PV2 - voltage

Read
MODBUSR(H, 678, UInt16) / 10
Service Attributes
PV2 current
TOSTRING(MODBUSR(H, 679, UInt16) / 10, "F1") + " A"
PV2 power
TOSTRING(MODBUSR(H, 673, UInt16)) + " W"
PV - production today Variable

PV - production today

Read
MODBUSR(H, 529, UInt16) / 10
Load - consumption today Variable
Service Attributes
Load power L1
Load power L2
Load power L3

Load - consumption today

Read
MODBUSR(H, 526, UInt16) / 10
Service Attributes
Load power L1
TOSTRING(MODBUSR(H, 650, Int16)) + " W"
Load power L2
TOSTRING(MODBUSR(H, 651, Int16)) + " W"
Load power L3
TOSTRING(MODBUSR(H, 652, Int16)) + " W"
Inverter - output power total Variable
Service Attributes
Inverter output L1
Inverter output L2
Inverter output L3
Inverter voltage L1
Inverter voltage L2
Inverter voltage L3
Inverter frequency

Inverter - output power total

Read
MODBUSR(H, 636, Int16)
Service Attributes
Inverter output L1
TOSTRING(MODBUSR(H, 633, Int16)) + " W"
Inverter output L2
TOSTRING(MODBUSR(H, 634, Int16)) + " W"
Inverter output L3
TOSTRING(MODBUSR(H, 635, Int16)) + " W"
Inverter voltage L1
TOSTRING(MODBUSR(H, 627, UInt16) / 10, "F1") + " V"
Inverter voltage L2
TOSTRING(MODBUSR(H, 628, UInt16) / 10, "F1") + " V"
Inverter voltage L3
TOSTRING(MODBUSR(H, 629, UInt16) / 10, "F1") + " V"
Inverter frequency
TOSTRING(MODBUSR(H, 638, UInt16) / 100, "F2") + " Hz"
Backup - output power Variable

Backup - output power

Read
MODBUSR(H, 643, UInt16)
Generator port - power Variable

Generator port - power

Read
MODBUSR(H, 667, Int16)
DC transformer temperature Temperature Sensor

DC transformer temperature

Read temperature
(MODBUSR(H, 540, UInt16) - 1000) / 10
Heat sink temperature Temperature Sensor

Heat sink temperature

Read temperature
(MODBUSR(H, 541, UInt16) - 1000) / 10
Settings - energy management mode Multi-value Switch
Values / States: Selling first · Zero export to load · Zero export to CT

Settings - energy management mode

Read switch state
MODBUSR(H, 142, UInt16)
Write switch state
MODBUSWNE(H, 142, UInt16, Mu)
Settings - solar sell Switch
Values / States: ON · OFF

Settings - solar sell

Read switch state
MODBUSR(H, 145, UInt16)
Write switch state
MODBUSWNE(H, 145, UInt16, St)
Settings - max sell power Variable

Settings - max sell power

Read
MODBUSR(H, 143, UInt16)
Write
MODBUSWNE(H, 143, UInt16, Va)
Settings - max solar sell power Variable

Settings - max solar sell power

Read
MODBUSR(H, 340, UInt16)
Write
MODBUSWNE(H, 340, UInt16, Va)
Settings - grid charging Switch
Values / States: ON · OFF

Settings - grid charging

Read switch state
MODBUSR(H, 130, UInt16)
Write switch state
MODBUSWNE(H, 130, UInt16, St)
Settings - grid charge current Variable

Settings - grid charge current

Read
MODBUSR(H, 128, UInt16)
Write
MODBUSWNE(H, 128, UInt16, Va)
Settings - max battery charge current Variable

Settings - max battery charge current

Read
MODBUSR(H, 108, UInt16)
Write
MODBUSWNE(H, 108, UInt16, Va)
Settings - max battery discharge current Variable

Settings - max battery discharge current

Read
MODBUSR(H, 109, UInt16)
Write
MODBUSWNE(H, 109, UInt16, Va)
Settings - generator port use Multi-value Switch
Values / States: Generator input · Smart load output · Micro-inverter input

Settings - generator port use

Read switch state
MODBUSR(H, 133, UInt16)
Write switch state
MODBUSWNE(H, 133, UInt16, Mu)
TOU - enable Switch
Values / States: ON · OFF

TOU - enable

Read switch state
GETBIT(MODBUSR(H, 146, UInt16), 0)
Write switch state
VAR reg := MODBUSR(H, 146, UInt16);
reg := SETBIT(reg, 0, St);
MODBUSWNE(H, 146, UInt16, reg)
TOU W1 - start time Variable

TOU W1 - start time

Read
MODBUSR(H, 148, UInt16)
Write
MODBUSWNE(H, 148, UInt16, Va)
TOU W1 - target SoC Dimmer

TOU W1 - target SoC

Read level
LINEAR(MODBUSR(H, 166, UInt16), 0, 0, 100, 1)
Write level
MODBUSWNE(H, 166, UInt16, LINEAR(Le, 0, 0, 1, 100))
TOU W1 - grid charging Switch
Values / States: ON · OFF

TOU W1 - grid charging

Read switch state
GETBIT(MODBUSR(H, 172, UInt16), 0)
Write switch state
VAR reg := MODBUSR(H, 172, UInt16);
reg := SETBIT(reg, 0, St);
MODBUSWNE(H, 172, UInt16, reg)
TOU W2 - start time Variable

TOU W2 - start time

Read
MODBUSR(H, 149, UInt16)
Write
MODBUSWNE(H, 149, UInt16, Va)
TOU W2 - target SoC Dimmer

TOU W2 - target SoC

Read level
LINEAR(MODBUSR(H, 167, UInt16), 0, 0, 100, 1)
Write level
MODBUSWNE(H, 167, UInt16, LINEAR(Le, 0, 0, 1, 100))
TOU W2 - grid charging Switch
Values / States: ON · OFF

TOU W2 - grid charging

Read switch state
GETBIT(MODBUSR(H, 173, UInt16), 0)
Write switch state
VAR reg := MODBUSR(H, 173, UInt16);
reg := SETBIT(reg, 0, St);
MODBUSWNE(H, 173, UInt16, reg)
TOU W3 - start time Variable

TOU W3 - start time

Read
MODBUSR(H, 150, UInt16)
Write
MODBUSWNE(H, 150, UInt16, Va)
TOU W3 - target SoC Dimmer

TOU W3 - target SoC

Read level
LINEAR(MODBUSR(H, 168, UInt16), 0, 0, 100, 1)
Write level
MODBUSWNE(H, 168, UInt16, LINEAR(Le, 0, 0, 1, 100))
TOU W3 - grid charging Switch
Values / States: ON · OFF

TOU W3 - grid charging

Read switch state
GETBIT(MODBUSR(H, 174, UInt16), 0)
Write switch state
VAR reg := MODBUSR(H, 174, UInt16);
reg := SETBIT(reg, 0, St);
MODBUSWNE(H, 174, UInt16, reg)
TOU W4 - start time Variable

TOU W4 - start time

Read
MODBUSR(H, 151, UInt16)
Write
MODBUSWNE(H, 151, UInt16, Va)
TOU W4 - target SoC Dimmer

TOU W4 - target SoC

Read level
LINEAR(MODBUSR(H, 169, UInt16), 0, 0, 100, 1)
Write level
MODBUSWNE(H, 169, UInt16, LINEAR(Le, 0, 0, 1, 100))
TOU W4 - grid charging Switch
Values / States: ON · OFF

TOU W4 - grid charging

Read switch state
GETBIT(MODBUSR(H, 175, UInt16), 0)
Write switch state
VAR reg := MODBUSR(H, 175, UInt16);
reg := SETBIT(reg, 0, St);
MODBUSWNE(H, 175, UInt16, reg)
TOU W5 - start time Variable

TOU W5 - start time

Read
MODBUSR(H, 152, UInt16)
Write
MODBUSWNE(H, 152, UInt16, Va)
TOU W5 - target SoC Dimmer

TOU W5 - target SoC

Read level
LINEAR(MODBUSR(H, 170, UInt16), 0, 0, 100, 1)
Write level
MODBUSWNE(H, 170, UInt16, LINEAR(Le, 0, 0, 1, 100))
TOU W5 - grid charging Switch
Values / States: ON · OFF

TOU W5 - grid charging

Read switch state
GETBIT(MODBUSR(H, 176, UInt16), 0)
Write switch state
VAR reg := MODBUSR(H, 176, UInt16);
reg := SETBIT(reg, 0, St);
MODBUSWNE(H, 176, UInt16, reg)
TOU W6 - start time Variable

TOU W6 - start time

Read
MODBUSR(H, 153, UInt16)
Write
MODBUSWNE(H, 153, UInt16, Va)
TOU W6 - target SoC Dimmer

TOU W6 - target SoC

Read level
LINEAR(MODBUSR(H, 171, UInt16), 0, 0, 100, 1)
Write level
MODBUSWNE(H, 171, UInt16, LINEAR(Le, 0, 0, 1, 100))
TOU W6 - grid charging Switch
Values / States: ON · OFF

TOU W6 - grid charging

Read switch state
GETBIT(MODBUSR(H, 177, UInt16), 0)
Write switch state
VAR reg := MODBUSR(H, 177, UInt16);
reg := SETBIT(reg, 0, St);
MODBUSWNE(H, 177, UInt16, reg)
Connection: Modbus RTU • 9600 baud• 8N1 • Slave ID: $[SlaveId]

Import parameters

Enter these values when you import the XML.

Asked in the appDefault
Modbus Slave ID1

Found a problem with this device template?

Tell us what's wrong, what's missing, or how the template should behave. We rely on your feedback to keep the catalog accurate.

Template · TapHome portal Deye SUN-xK-SG04LP3-EU / SG05LP3-EU Open this template in the Customer Portal to apply it to one of your homes, or to draft a refinement and submit it back to the catalog. Modbus RTU View in TapHome portal