Deye Deye SUN-SG04LP3 Modbus RTU template

Deye SUN-SG04LP3

Three-phase hybrid inverter for 48 V batteries with PV, battery, grid and load values and time-of-use control.

The Deye SUN-SG04LP3 is a three-phase hybrid inverter from 5 to 12 kW that combines two PV inputs, a 48 V battery and the grid for homes and small businesses. This Modbus RTU template reads PV, battery, grid and load values, energy counters and faults, and lets you set the work mode, time-of-use programs and battery limits from ModbusCloud.

Protocol
Modbus RTU
Connection
RS485, 9600 baud
Registers
244, read and write
Brand
Deye
Key readings
PV power · Battery SOC · Battery power · Grid power · Load power · Daily production · Imported and exported energy · Device state
Available commands
Work mode · Time-of-use programs · Battery charge current · Grid export limit
Compatible models
SUN-5K-SG04LP3-EU · SUN-6K-SG04LP3-EU · SUN-8K-SG04LP3-EU · SUN-10K-SG04LP3-EU · SUN-12K-SG04LP3-EU · Deye SUN-5K-SG04LP3-EU · Deye SUN-6K-SG04LP3-EU · Deye SUN-8K-SG04LP3-EU · Deye SUN-10K-SG04LP3-EU · Deye SUN-12K-SG04LP3-EU
Last updated

Registers (244)

244 read, 98 write

NameUnitAccessAddress (Hidden until you enter your email)Function (hidden)Type (hidden)
DeviceRead
Device Modbus AddressRead
Device Protocol VersionRead
Device Serial NumberRead
Device MCU Board VersionRead
Device AFCI VersionRead
Device MCU VersionRead
Device Control Board Firmware Version Part 1Read
Device Control Board Firmware Version Part 2Read
Device Control Board Firmware Version Part 3Read
Device Communication Board Firmware Version Part 1Read
Device Communication Board Firmware Version Part 2Read
Device Communication Board Firmware Version Part 3Read
Device Rated PowerWRead
Device MPPTsRead
Device Self-checkRead
Self-check timesRead and write
Date & Time Word 1Read and write
Date & Time Word 2Read and write
Date & Time Word 3Read and write
On/Off SwitchRead and write
Battery Control ModeRead and write
Battery EqualizationVRead and write
Battery AbsorptionVRead and write
Battery FloatVRead and write
Battery CapacityRead and write
Battery EmptyVRead and write
Zero Export powerWRead and write
Battery Equalization CycleRead and write
Battery Equalization TimehRead and write
Battery Temperature CompensationRead and write
Battery Max Charging CurrentARead and write
Battery Max Discharging CurrentARead and write
Battery Operation ModeRead and write
Battery Wake UpRead and write
Battery ResistanceRead and write
Battery Charging efficiency%Read and write
Battery Shutdown SOC%Read and write
Battery Restart SOC%Read and write
Battery Low SOC%Read and write
Battery Shutdown VoltageVRead and write
Battery Restart VoltageVRead and write
Battery Low VoltageVRead and write
Generator Operating TimehRead and write
Generator Cooling TimehRead and write
Battery Generator Charging Start VoltageVRead and write
Battery Generator Charging Start%Read and write
Battery Generator Charging CurrentARead and write
Battery Grid Charging Start VoltageVRead and write
Battery Grid Charging Start%Read and write
Battery Grid Charging CurrentARead and write
Battery Grid ChargingRead and write
GeneratorRead and write
IO ModeRead and write
SmartLoad Off VoltageVRead and write
SmartLoad Off%Read and write
SmartLoad On VoltageVRead and write
SmartLoad On%Read and write
Grid VoltageRead and write
Generator Min PV PowerWRead and write
Charging SignalRead and write
Energy PatternRead and write
Work ModeRead and write
Export Surplus PowerWRead and write
Export SurplusRead and write
Export AsymmetryRead and write
PV PowerWRead and write
MPPT multi-point scanningRead and write
Time of UseRead and write
Program 1 TimeRead and write
Program 2 TimeRead and write
Program 3 TimeRead and write
Program 4 TimeRead and write
Program 5 TimeRead and write
Program 6 TimeRead and write
Program 1 PowerWRead and write
Program 2 PowerWRead and write
Program 3 PowerWRead and write
Program 4 PowerWRead and write
Program 5 PowerWRead and write
Program 6 PowerWRead and write
Program 1 VoltageVRead and write
Program 2 VoltageVRead and write
Program 3 VoltageVRead and write
Program 4 VoltageVRead and write
Program 5 VoltageVRead and write
Program 6 VoltageVRead and write
Program 1 SOC%Read and write
Program 2 SOC%Read and write
Program 3 SOC%Read and write
Program 4 SOC%Read and write
Program 5 SOC%Read and write
Program 6 SOC%Read and write
Program 1 ChargingRead and write
Program 2 ChargingRead and write
Program 3 ChargingRead and write
Program 4 ChargingRead and write
Program 5 ChargingRead and write
Program 6 ChargingRead and write
Microinverter Export cut-offRead and write
Off GridRead and write
Grid reconnection timesRead and write
Grid Frequency SettingRead and write
Grid voltage protection - highVRead and write
Grid voltage protection - lowVRead and write
Grid frequency protection - highHzRead and write
Grid frequency protection - lowHzRead and write
Generator Grid sideRead and write
Generator Peak shavingWRead and write
Grid Peak shavingWRead and write
Grid Max Export powerWRead and write
Grid Max Import powerWRead and write
AC CouplingRead and write
Battery BMS Charging VoltageVRead
Battery BMS Discharging VoltageVRead
Battery BMS Charging CurrentARead
Battery BMS Discharging CurrentARead
Battery BMS SOC%Read
Battery BMS VoltageVRead
Battery BMS CurrentARead
Battery BMS Max Charging CurrentARead
Battery BMS Max Discharging CurrentARead
Battery AlarmRead
Battery FaultRead
Battery BMS Other SymbolRead
Battery BMS TypeRead and write
Today Battery ChargekWhRead
Today Battery DischargekWhRead
Total Battery ChargekWhRead
Total Battery DischargekWhRead
Today Energy ImportkWhRead
Today Energy ExportkWhRead
Total Energy ImportkWhRead
Total Energy ExportkWhRead
Today Load ConsumptionkWhRead
Total Load ConsumptionkWhRead
Generator Energy - todaykWhRead
Generator EnergykWhRead
Today ProductionkWhRead
Total ProductionkWhRead
DC Temperature°CRead
Temperature°CRead
Device StateRead
Power On/Off StateRead
Device RelayRead
Device AlarmRead
Device Fault Word 1Read
Device Fault Word 2Read
Device Fault Word 3Read
Device Fault Word 4Read
Battery Temperature°CRead
Battery VoltageVRead
Battery SOC%Read
Battery PowerWRead
Battery Corrected CapacityRead
Grid L1 VoltageVRead
Grid L2 VoltageVRead
Grid L3 VoltageVRead
Internal CT1 PowerWRead
Internal CT1 Power High WordRead
Internal CT2 PowerWRead
Internal CT2 Power High WordRead
Internal CT3 PowerWRead
Internal CT3 Power High WordRead
Internal PowerWRead
Internal Power High WordRead
Grid FrequencyHzRead
Internal CT1 CurrentARead
Internal CT2 CurrentARead
Internal CT3 CurrentARead
External CT1 CurrentARead
External CT2 CurrentARead
External CT3 CurrentARead
External CT1 PowerWRead
External CT1 Power High WordRead
External CT2 PowerWRead
External CT2 Power High WordRead
External CT3 PowerWRead
External CT3 Power High WordRead
External PowerWRead
External Power High WordRead
Grid Power Factor%Read
Grid L1 PowerWRead
Grid L1 Power High WordRead
Grid L2 PowerWRead
Grid L2 Power High WordRead
Grid L3 PowerWRead
Grid L3 Power High WordRead
Grid PowerWRead
Grid Power High WordRead
Output L1 VoltageVRead
Output L2 VoltageVRead
Output L3 VoltageVRead
Output L1 CurrentARead
Output L2 CurrentARead
Output L3 CurrentARead
Output L1 PowerWRead
Output L1 Power High WordRead
Output L2 PowerWRead
Output L2 Power High WordRead
Output L3 PowerWRead
Output L3 Power High WordRead
Output PowerWRead
Output Power High WordRead
Output FrequencyHzRead
Load UPS L1 PowerWRead
Load UPS L1 Power High WordRead
Load UPS L2 PowerWRead
Load UPS L2 Power High WordRead
Load UPS L3 PowerWRead
Load UPS L3 Power High WordRead
Load UPS PowerWRead
Load UPS Power High WordRead
Load L1 VoltageVRead
Load L2 VoltageVRead
Load L3 VoltageVRead
Load Consumption L1 PowerWRead
Load Consumption L1 Power High WordRead
Load Consumption L2 PowerWRead
Load Consumption L2 Power High WordRead
Load Consumption L3 PowerWRead
Load Consumption L3 Power High WordRead
Load Consumption PowerWRead
Load Consumption Power High WordRead
Load FrequencyHzRead
Generator L1 VoltageVRead
Generator L2 VoltageVRead
Generator L3 VoltageVRead
Generator L1 PowerWRead
Generator L1 Power High WordRead
Generator L2 PowerWRead
Generator L2 Power High WordRead
Generator L3 PowerWRead
Generator L3 Power High WordRead
Generator PowerWRead
Generator Power High WordRead
PV1 PowerWRead
PV2 PowerWRead
PV1 VoltageVRead
PV1 CurrentARead
PV2 VoltageVRead
PV2 CurrentARead
Battery CurrentARead
Battery Current 2ARead

Loading registers…

Send your device list

If a device is not in the library yet, we build the template for free as soon as we have the register data.

Number of installations (optional)

Use cases

  • Show PV power, battery SOC, grid power and load per phase of a Deye installation on one dashboard.
  • Get an alert when the device state changes to alarm or fault, or when battery SOC drops below a threshold.
  • Compare daily production, import, export and battery cycles in the history.
  • Change the time-of-use programs remotely, for example to charge the battery from the grid at night.
  • Set the grid export limit or zero export power when the grid operator or a contract asks for it.

Installation

  1. Connect the RS485 pair from the Modbus port of the inverter to the RS485 port of the ModbusCloud Gateway, A to A and B to B, with 120 ohm at the end of the bus.

  2. Check the Modbus address of the inverter in its settings; leave it at 1 or give each inverter on the bus its own address.

  3. In ModbusCloud, add a Modbus device with protocol RTU, the inverter address, 9600 baud and 8N1, and import this template.

  4. Check that Device shows LV 3-Phase Hybrid Inverter and that Battery SOC matches the display.

Things to watch for

The inverter does not answer. What should I check?

Make sure the cable is on the Modbus port and not on the BMS port, check address 1 and 9600 baud, and swap A and B if nothing comes back. A Wi-Fi logger that also polls the RS485 port can cause collisions.

Why do grid and load power jump to large negative values above about 32 kW?

These powers are 16-bit values with a separate high word register. Below 32767 W the low register alone is correct; for larger systems combine it with the matching High Word register.

The temperatures show about 100 degrees too much. Why?

The inverter reports DC, AC and battery temperature with an offset of 100 degrees. Subtract 100 from the value to get the real temperature.

Can I change the work mode and time-of-use programs from ModbusCloud?

Yes, the settings, time-of-use programs and battery limits are writable. Writing is off per gateway by default; request it for the gateway in the portal. Read a setting first and change one value at a time, because the inverter applies it immediately.

Want to see how it works?

Electrician working in an open distribution board