Trouble Connecting To Sunspec Modbus Device


gillecaluimi

Recommended Posts

I'm trying to query a photovoltaic inverter (SolarEdge) to collect energy production data.  The inverter has several different operating modes, one mode being able to produce data stream using the SunSpec protocol, which I believe is a simple modbus rtu.  The manufacturer has a list of modbus registers to query but to date I have been unable to communicate with the device.

1.  If I set the device to be a modbus master and monitor the rs485 serial device, there's activity every 10 seconds received by the Comm Monitor...which I figure is the device looking for slave devices

 

Rx (10:18:46.723): \xBB\xD9\xAAC\xFF\x03\x06(\xBA\x00\x07g7\xE8\x80\x00\x00\x00\x7F}\x9D\xE3
Rx (10:19:12.437): \xBB\xD9\xAAC\xFF\x03\x06(\xBA;v\xBF\x03\x07\x06\x08\x10`\xEB\xD7\xBE\xFC
Rx (10:19:32.438): \xBB\xD9\xAAC\xFF\x03\x06(\xBA;v\xBF\x03\x07\x06\x10 \xC0\xEB\xD7\xBE\xFC
Rx (10:19:52.440): \xBB\xD9\xAAC\xFF\x03\x06(\xBA;v\xBF\x03\x07\x06\x08\x10`\xEB\xD7\xBE\xFC
Rx (10:20:12.441): ;\x97\xA7\x1B\xFF\xFF\x03\x06(\xBAt\xD8\xF67\xE8\x80\x00\x00\x00\x7F\xF5\xD7\xBE\xFC
Rx (10:20:32.443): \xBB\xD9\xAAC\xFF\x03\x06(\xBA;v\xBF\x03\x07\x06\x08\x10`\xEB\xD7\xBE\xFC
Rx (10:20:52.444): \xBB\xD9\xAAC\xFF\x03\x06(\xBA;v\xBF\x03\x07\x06\x08\x10`\xEB\xAF\xBE\xFC
Rx (10:21:12.446): \xBB\xD9\xAAC\xFF\x03\x06,\xBA;v\xBF\x03\x07\x06\x08\x10`\xEB\xD7\xBE\xFC
Rx (10:21:32.448): \xBB\xD9\xAAC\xFF\x03\x06(\xBA;v\xBF\x03\x07\x06\x08\x10`\xEB\xD7\xBE\xFC
Rx (10:21:52.449): \xBB\xD9\xAAC\xFF\x03\x06(\xBA;v\x7F\x03\x07\x06\x08\x10`\xEB\xD7|\xFC
Rx (10:22:12.451): \xBB\xD9\xAAC\xFF\x03\x06(\xBA;v\xBF\x03\x07\x06\x080`\xEB\xD7\xBE\xFC
Rx (10:22:32.453): \xBB\xD9\xAAC\xFF\x03\x06(\xBA;v\xBF\x03\x07\x06\x08\x10`\xEB\xD7\xBE\xFC
Rx (10:22:52.454): \xBB\xD9\xAAC\xFF\x03\x06(\xBA;v\xBF\x03\x07\x06\x08\x10`\xEB\xD7\xBE\xFC
Rx (10:23:12.456): \xBB\xD9\xAAC\xFF\x03\x06(\xBA;v\xBF\x03\x07\x06\x08\x10`\xEB\xD7\xBE\xFC
Rx (10:23:32.458): \xBB\xD9\xAAC\xFF\x03\x06(\xBA;v\xBF\x03\x07\x06\x08\x10`\xEB\xD7\xBE\xFC
Rx (10:23:52.459): \xBB\xD9\xAAC\xFF\x03\x06(\xBA;v\xBF\x03\x07\x06\x08\x10\xC0\xEB\xD7\xBE\xFC
Rx (10:24:12.461): \xBB\xD9\xAAC\xFF\x03\x06(\xBA;v\xBF\x03\x07\x06\x08\x10`\xEB\xD7\xBE\xFC
 
this activity disappears once I set the device to slave mode.
 
2.The manufacturers manual states states:
Tx: 01 03 9C 40 00 7A EB AD – Read 122 holding registers starting at address 40001.
but I get no response when entering 01 03 9C 40 00 7A EB AD in the CommMonitor window and pressing enter
 
Anyone have any experience using df with sunspec protocol devices?
 
Link to comment
Share on other sites

The queries the device was sending when in master mode were not Modbus queries.  xD9 is not a valid modbus function.  If it was Modbus, it'd look a lot more like what you tried when you made the device the slave.

 

As for when you made it the slave, if you want to enter hex values into the monitor you have to put a backslash and x in front, much like you saw in the Rx:

 

\x01\x03\x9C\x40\x00\x7a\xeb\xad

 

otherwise, DAQFactory thinks you are trying to send the letters 0, 1, space, 0, 3, etc. which is totally different.  Also, when dealing with binary protocols you'll want to check the box that says "Display all ascii chars as codes", and given your documentation, probably also the one that displays all codes in hex.

 

BTW: if you want DAQFactory to be the Modbus master, use the built in protocol and channels.  Typing the command into the monitor is an ok way to test, but don't try and parse it when DAQFactory can do it for you already.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.