SunSpec SunSpec Model 502 — Solar Module Modbus TCP template

SunSpec Model 502 — Solar Module

SunSpec Model 502 is a standardized Modbus TCP information model for solar module monitoring, defined by the SunSpec Alliance for use across compliant PV devices regardless of manufacturer. This template reads per-module output and input electrical data: current, voltage, instantaneous power, and cumulative energy on both the input (inw, ina, inv, inwh) and output (outpw, outa, outv, outwh) sides, plus module temperature and operating timestamp. Status, standard event flags, and vendor event flags expose fault and alarm states. Three read-write control registers (ctl, ctlvend, ctlval) allow module-level commands. Importing this template into your ModbusCloud portal gives you structured, manufacturer-independent panel telemetry in one click.

Protocol
Modbus TCP
Connection
Ethernet, Modbus TCP
Registers
23, read and write
Brand
SunSpec
Last updated

Registers (23)

23 read, 3 write

NameUnitAccessAddress (Hidden until you enter your email)Function (hidden)Type (hidden)
idRead
lRead
a_sfRead
v_sfRead
w_sfRead
wh_sfRead
statRead
statvendRead
evtRead
evtvendRead
ctlRead and write
ctlvendRead and write
ctlvalRead and write
tmsSecsRead
outaARead
outvVRead
outwhWhRead
outpwWRead
tmp°CRead
inaARead
invVRead
inwhWhRead
inwWRead

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.

Use cases

  • Monitor per-module output power and input power to detect underperforming panels across a PV array.
  • Track cumulative input and output energy (inwh, outwh) to verify energy conversion efficiency over time.
  • Alert on non-zero event flags (evt) to identify module faults or alarms before they escalate.
  • Compare module temperature (tmp) against output power to correlate thermal derating with reduced yield.
  • Verify operating status (stat) after grid events to confirm all modules have returned to normal operation.

Installation

  1. Confirm that the target device implements SunSpec Model 502 and has Modbus TCP enabled, typically under the communication or Modbus section of its web interface or configuration tool.

  2. Connect the device to the same LAN as the ModbusCloud Gateway, ensuring TCP port 502 is reachable from the Gateway's network segment and no firewall blocks it.

  3. In the ModbusCloud portal, add a new device using the ModbusCloud Gateway, import the SunSpec Model 502 Solar Module template, and set the correct unit ID matching your device's Modbus slave address.

  4. Spot-check connectivity by reading register offset 0 (id): a returned value of 502 confirms the correct model block is addressed and data is flowing.

Things to watch for

Register id returns a value other than 502. Why?

The model block base address may be wrong. SunSpec devices place models at dynamic offsets discovered by walking the device map from the SunSpec start address. Confirm the base address of Model 502 by scanning from the SunSpec identifier register rather than assuming a fixed offset.

Current and power readings look wrong by a factor of 10 or 100. What is the cause?

SunSpec uses signed integer scale factors. The raw outa, outpw, ina, and inw values must be multiplied by 10 raised to the power of a_sf or w_sf respectively. If your integration ignores these scale factor registers, all derived readings will be off by a power of ten.

The gateway connects but outwh and inwh show zero or no change. What should I check?

Energy accumulator registers (outwh, inwh) are uint32 and increment only while the module is producing power. Verify the module's stat register is in an active operating state and that the module is not in a fault condition indicated by the evt bitfield.

Is it safe to write to the ctl, ctlvend, and ctlval registers in normal monitoring?

No. These are read-write control registers that send commands to the module. Writing incorrect values to ctl or ctlval can alter module operating mode, interrupt production, or trigger protective shutdowns. Only write to these registers if you have verified the command sequence in the device's documentation and understand the consequences.

Want to see how it works?

Electrician working in an open distribution board