MODBUS data from SMA Inverter

Mine is still working as of today, no known firmware updates this month.

I’d check that the IP address is still the same and try rebooting the inverter.

Thanks, @drmcinnes. Yeah, tried rebooting it a few times. Left it off for 20mins also. I’ve got a reserved IP for it on a fully open LAN segment, and confirmed the error changes to a timeout when the unit is turned off.

image

I tried ModbusView and the specific error there is EC4 Slave Device Failure. Googling doesn’t come up with any solution for error unfortunately. I can’t think of anything that might have changed…

image

The registers previously working are below.

image

Hi everyone
Totally new in home assistant and programming, dont even ask. I have SMA STP7000 inverter and Home manager 2 which I wanted to get connecetd to HA. Big thanks to Chris for his tutorials, managed to get the Node red done for Home manager and now trying to figure out how to get the solar production out. Will probably follow his another tutorial and see what happens :slight_smile: While I was searching how to get the Home manager and inverter connected to HA I found this: https://www.home-assistant.io/integrations/sma/
Is it working only for USA? I cant get anything out from this and I actually think that it shouldnt be the IP of inverter but home manager. Inverter would not have access to power supplied from grid no?

Edit: Big thx to MBolt for his script, didnt need all the sensors so I have trimmed it a bit and got working. :slight_smile:

1 Like

Anyone have advice on communication hardware to use, from Sunny Island SI6048US, which has rs485 port?

Sounds like most in this thread have a Sunny Webbox or Data Manager box between the inverters and your local network / internet. These feel pricey?

I have a little $2.50 RS485 - TTL board that I’ll try with an ESP32. Anyone do that? Thanks!

I’m getting the same error - I suspect a firmware update, which is a shame because the isolarcloud portal doesnt update as frequently as I would like

Mine died three days ago as well, probably a forced firmware update…

It looks like i’ll have to switch to reading the RS485 directly.

It’s my own fault for not blocking remote access.

Mine too, out of the blue. You think its a firmware? Did you manage to get around or understand what changed?

Pretty sure its firmware.

I’m currently trying direct connect

If you sniff from the S100 you only get the consumption data as below

[21/08/2020 14:08:21]	
Modbus Response (COM3)	
Address: 32	
Function: 3 (0x03) - Read Holding Registers	
    Byte Count: 4	
    Values: 00 00 1f b4 	
        Register0: 0	
        Register1: 8116	
Checksum: 50038(OK)	

now i’m trying to intercept the RS485 between the WIFI dongle and the inverter but i’ll have to build an adapter.

the RS485 A and B seems to be on pins 6 and 3 respectively but i’m still trying to identify power

I’ll head down a different path and scrape the isolar portal. Let me know if anyone is interested and I can share a git repo

yes please, always good to have a backup plan!

Turned out I didnt need to do much work. Someone had managed to map the isolar cloud. Take a look here. I was quite ease to exctract the api client from its repo.

https://developer.aliyun.com/mirror/npm/package/homebridge-platform-isolarcloud

I’ve also got a SH5K-20. Mine was running perfectly with a pymodbus script but stopped working in february. I’ve been in contact with sungrow but they deny that any firmware update has taken place to change the modbus interface on 502.

I’m current trying to get them to warranty replace my unit because of this, so either they will have to admit that they have modified my inverter remotely to cripple it or there is an actual “fault” with the system.

2 Likes

I didn’t have the same error message. Mine was something to do with the host being in Init mode. It happened after I restarted my router, although there was no IP, port or firewall change. After that my modbus comms was very unstable, but would occasionally work. I ended up running through the full shut down and restart procedure (off at the panels, off at the house, off at the inverter, disconnect batteries, then all on again. That got it all working back to normal again.

Maybe worth trying with yours if you haven’t tried?

Yep first thing I’ve tried, and subsequently tried again after you message just to be sure but still in the same problem. The modbus is responding to the request but it’s not readable.

no luck here either, it would have saved me a lot of work!

Looks like the guys on whirlpool have figured out whats going on

…well, i guess i can get rid of this monstrosity now!

Hi … this works for me with the example but as soon as I add another one to the list I no longer get any entities for sma ? Any idea ?

Exaample: (only when I leave only the first one it works ???)

  • platform: modbus
    scan_interval: 30
    registers:
    • name: Gesamtertrag
      hub: Sunnyboy
      unit_of_measurement: kWh # see register description in section 5.4.1 of the document
      slave: 3 # use the UnitID you found in Sunny Explorer
      register: 30531 # use a register from section 5.4.1 of the document
      register_type: input # all registers starting with 3 need to have the type input
      count: 2 # use the correct count for the register see section 5.4.1 of the document
    • name: SMApwrL1
      unit_of_measurement: kW
      slave: 3
      register: 30777
      count: 2
      data_type: uint
      scale: 0.001
      precision: 2

Thanks !

Hi Tony,

did you try to use the entries like I described them including register_type: input etc

regards
Chris

Hello, I have the same problem. Did you find the problem?