Skip to main content

Growatt SPH (hybrid storage)

Status: Vendor Confirmed · Register points: 396 · Transports: Modbus RTU, Modbus TCP

A curated ModDef profile for the Growatt SPH (hybrid storage). Import it as growatt.sph or load the .moddef.yaml directly.

Connect to one over Web Serial and watch its values live in the device dashboard.

Usage

Load the profile, bind a transport, and read a point by name. The runtime applies the offset, scaling, byte order, and sentinels from the definition.

doc, _ := moddef.Load("growatt-sph.moddef.yaml")
dev, _ := client.New(doc, "growatt-sph", transport) // your modbus.Transport
v, _ := dev.ReadPoint(ctx, "rated_pv_voltage")
fmt.Println(v)

Commands

Multi-step register procedures (spec §11.7) this profile defines — write params, arm a trigger, poll for completion, then read the result. Run one with your language's command executor (RunCommand, runCommand, run_command, or md_cmd_begin/md_cmd_tick in C/C++).

set_active_power_rate — Set Active Power Rate (Persistent)

Set the inverter's maximum active output power as a percentage, then make it survive a power cycle. 255 means no limit. The setpoint registers 3, 4, 5 and 99 are volatile until holding register 2 is set to 1, so this writes the value and then latches it (document register 02: "these settings will be acting or not when next power on"). Register 2 is a single flag covering all four setpoints, so latching one latches whatever the others currently hold. Leave at least 850 ms between the two writes (document section 5.3.1).

Params

FieldTypeRequired
rateDECIMALyes

Results

FieldType
appliedDECIMAL
persisted

set_reactive_power_rate — Set Reactive Power Rate (Persistent)

Set the inverter's maximum reactive output power as a percentage from -100 to 100, then make it survive a power cycle. 255 means no limit. The setpoint registers 3, 4, 5 and 99 are volatile until holding register 2 is set to 1, so this writes the value and then latches it (document register 02: "these settings will be acting or not when next power on"). Register 2 is a single flag covering all four setpoints, so latching one latches whatever the others currently hold. Leave at least 850 ms between the two writes (document section 5.3.1).

Params

FieldTypeRequired
rateDECIMALyes

Results

FieldType
appliedDECIMAL
persisted

set_power_factor — Set Power Factor (Persistent)

Set the inverter's output power factor, then make it survive a power cycle. The parameter is the raw register value, i.e. the power factor times 10000: 0 to 10000 is underexcited and 10001 to 20000 overexcited. Command params carry no transform, so unlike the power_factor_set point this value is not scaled for you. The setpoint registers 3, 4, 5 and 99 are volatile until holding register 2 is set to 1, so this writes the value and then latches it (document register 02: "these settings will be acting or not when next power on"). Register 2 is a single flag covering all four setpoints, so latching one latches whatever the others currently hold. Leave at least 850 ms between the two writes (document section 5.3.1).

Params

FieldTypeRequired
power_factor_rawUINT32yes

Results

FieldType
appliedUINT32
persisted

set_pf_lock_in_voltage — Set CEI 0-21 PF Lock-In Voltage (Persistent)

Set the CEI 0-21 power-factor curve lock-in grid voltage, then make it survive a power cycle. The parameter is the raw register value in units of 0.1 V, since command params carry no transform. The setpoint registers 3, 4, 5 and 99 are volatile until holding register 2 is set to 1, so this writes the value and then latches it (document register 02: "these settings will be acting or not when next power on"). Register 2 is a single flag covering all four setpoints, so latching one latches whatever the others currently hold. Leave at least 850 ms between the two writes (document section 5.3.1).

Params

FieldTypeRequired
voltage_rawUINT32yes

Results

FieldType
appliedUINT32
persisted

set_grid_first_slot1 — Program Grid First Time Slot 1

Write the start time, stop time and enable flag of grid first time slot 1 (discharging the battery to the load and grid) as one action. Start and stop times pack the hour in the high byte and the minute in the low byte. The enable flag is written last so a half-written window is never live; the protocol document does not mandate an order, that is this profile's choice. Leave at least 850 ms between the three writes (document section 5.3.1).

Params

FieldTypeRequired
start_timeUINT32yes
stop_timeUINT32yes
enableenum enable_stateyes

Results

FieldType
start_timeUINT32
stop_timeUINT32
enabled

set_grid_first_slot2 — Program Grid First Time Slot 2

Write the start time, stop time and enable flag of grid first time slot 2 (discharging the battery to the load and grid) as one action. Start and stop times pack the hour in the high byte and the minute in the low byte. The enable flag is written last so a half-written window is never live; the protocol document does not mandate an order, that is this profile's choice. Leave at least 850 ms between the three writes (document section 5.3.1).

Params

FieldTypeRequired
start_timeUINT32yes
stop_timeUINT32yes
enableenum enable_stateyes

Results

FieldType
start_timeUINT32
stop_timeUINT32
enabled

set_grid_first_slot3 — Program Grid First Time Slot 3

Write the start time, stop time and enable flag of grid first time slot 3 (discharging the battery to the load and grid) as one action. Start and stop times pack the hour in the high byte and the minute in the low byte. The enable flag is written last so a half-written window is never live; the protocol document does not mandate an order, that is this profile's choice. Leave at least 850 ms between the three writes (document section 5.3.1).

Params

FieldTypeRequired
start_timeUINT32yes
stop_timeUINT32yes
enableenum enable_stateyes

Results

FieldType
start_timeUINT32
stop_timeUINT32
enabled

set_bat_first_slot1 — Program Battery First Time Slot 1

Write the start time, stop time and enable flag of battery first time slot 1 (charging the battery) as one action. Start and stop times pack the hour in the high byte and the minute in the low byte. The enable flag is written last so a half-written window is never live; the protocol document does not mandate an order, that is this profile's choice. Leave at least 850 ms between the three writes (document section 5.3.1).

Params

FieldTypeRequired
start_timeUINT32yes
stop_timeUINT32yes
enableenum enable_stateyes

Results

FieldType
start_timeUINT32
stop_timeUINT32
enabled

set_bat_first_slot2 — Program Battery First Time Slot 2

Write the start time, stop time and enable flag of battery first time slot 2 (charging the battery) as one action. Start and stop times pack the hour in the high byte and the minute in the low byte. The enable flag is written last so a half-written window is never live; the protocol document does not mandate an order, that is this profile's choice. Leave at least 850 ms between the three writes (document section 5.3.1).

Params

FieldTypeRequired
start_timeUINT32yes
stop_timeUINT32yes
enableenum enable_stateyes

Results

FieldType
start_timeUINT32
stop_timeUINT32
enabled

set_bat_first_slot3 — Program Battery First Time Slot 3

Write the start time, stop time and enable flag of battery first time slot 3 (charging the battery) as one action. Start and stop times pack the hour in the high byte and the minute in the low byte. The enable flag is written last so a half-written window is never live; the protocol document does not mandate an order, that is this profile's choice. Leave at least 850 ms between the three writes (document section 5.3.1).

Params

FieldTypeRequired
start_timeUINT32yes
stop_timeUINT32yes
enableenum enable_stateyes

Results

FieldType
start_timeUINT32
stop_timeUINT32
enabled

Measurands

The 22 semantic quantities this device reports, each linked to the measurand catalog. Query a device by measurand instead of a raw point when you want portable code.

Base quantityNameUnitDescription
inverter_statusInverter StatusundefinedInverter operating state (enum)
pv_powerPV PowerWPV array / string power
pv_voltagePV VoltageVPV array / string voltage
pv_currentPV CurrentAPV array / string current
active_powerActive PowerWInstantaneous real power
apparent_powerApparent PowerVAInstantaneous apparent power
reactive_powerReactive PowervarInstantaneous reactive power
power_factorPower Factor1 (ratio)Ratio of real to apparent power (dimensionless)
frequencyFrequencyHzGrid frequency
voltageVoltageVRMS voltage; qualify with phase_ref (L1_N, L1_L2, ...)
currentCurrentARMS current; qualify with phase_ref / direction
dc_bus_voltageDC Bus VoltageVInternal DC bus voltage
energy_activeActive EnergyWhCumulative active energy register
inverter_temperatureInverter TemperaturedegCInverter internal temperature
device_statusDevice StatusundefinedOverall device operating status (enum)
battery_powerBattery PowerWBattery power (sign per direction)
battery_voltageBattery VoltageVBattery terminal voltage
state_of_chargeState of Charge%Battery charge level
state_of_healthState of Health%Battery health
temperatureTemperaturedegCTemperature; qualify with location (INTERNAL, EXTERNAL, ...)
fault_codeFault CodeundefinedVendor fault code (enum or integer)
warning_codeWarning CodeundefinedVendor warning code (enum or integer)

Source