Skip to content
View in the app

A better way to browse. Learn more.

Power Forum - Renewable Energy Discussion

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

SunSynk - Inverter Monitoring

Featured Replies

@JuanH @Bloubul7 and anyone else that has the RS485 HAT for the Pi - what is the serial port connection?

 

Obviously from downloading the flows from GitHub, it had USB, but when I search I only find a /dev/ttyAMA0.

I deployed my NodeRed with that and now the pi seems like it reboots all the time 🤦🏼‍♂️

 

  • Replies 734
  • Views 204.6k
  • Created
  • Last Reply

Top Posters In This Topic

Most Popular Posts

  • Thanks to @Bloubul7and all the other contributors. This is my HA dashboard. It has all I need to view at a glance. (PS: really impressed with the Sunsynk)  

  • Thanks for sharing. Did not know about the horseshoe or plotly cards. Added to Dashboard  

  • Think I figured it out. Copied the Raw Config file. EDIT: Open the file at the bottom with notepad or Text Editor. Copy and paste in Dashboard "Raw configuration editor" You need to install

Posted Images

On 2021/12/03 at 4:49 PM, cyber7 said:

How did you configure this screen to come up?

1) Make sure your Home-Assistant version is up to date.
2) Get the Solar-Assistant BETA
3) Configured Solar-Assistant MQTT and MQTT DISCOVERY
4) Configure Home-Assistant to get the Solar-Assistant MQTT messages
See https://solar-assistant.io/help/integration/home-assistant
5) Configure "Energy" in Home-Assistant
See https://www.home-assistant.io/blog/2021/08/04/home-energy-management/
Configure -> Energy and follow the wizard
image.thumb.png.a12620ae76cfa790c8aefac229fe5142.png

It just works after that - the refresh is quite slow - I need to see what to configure in Home-Assistant to make it more "live" - the energy kWh data is being fed every minute, and the power kW every second - I'm trying to find a way to make the Home Assistant Energy Screen more real time.

Edited by system32

It is very nice, and thank you for assisting to set this up, but the updates are very  slow...  It seems to be behind by at least 30 minutes...

16 minutes ago, cyber7 said:

It is very nice, and thank you for assisting to set this up, but the updates are very  slow...  It seems to be behind by at least 30 minutes...

Yes, a bit sad it's not real-time.
Solar-Assistant is providing energy (kWh) every minute and power (W), Volts (V), etc are near real time - every second.
I think the slow update is a problem with Home-Assistant.
There's probably a setting in Home Assistant to make it more real time.

I tend to use Grafana mostly to display my data.

11 hours ago, system32 said:

I think the slow update is a problem with Home-Assistant.
There's probably a setting in Home Assistant to make it more real time.

The Energy management dashboard of Home Assistant is about longer term statistics, long term stats are updated once an hour. It an overview of your usage from different sources during different periods of the day/over weeks/months/year. Real time updates will have little value here.

The actual energy value (kWh) is still available and you can display it in the UI if you wish (If you have a use case I'd be very interested!)

Power (kW) is not part of the Energy dashboard and this is updated every second (or when it changes) and has more interesting use cases in automation. You can also show this on the normal HA dashboard to get a real time view of your usage, as in the attached image

 

 

 

 

image.png

On 2021/04/16 at 9:21 AM, Bloubul7 said:

Hi,

Yes, reading the settings will retrieve the current settings from the inverter and populate the dashboard.  You can then make changes if you like and press write settings to push back the changes to the inverter.

Some explanation on the different dashboards:

  • System Settings - Provides you with the ability to read and write the live settings from the inverter
  • Default Settings - This stores a set of default settings to the file system on Pi.  This was utilized to store my non-loadshedding settings.  These settings are automatically pushed to the inverter based on the loadshedding status
  • Loadshedding Settings - This stores a set of loadshedding settings to the file system on Pi.  This was utilized to store my loadshedding settings.  These settings are automatically pushed to the inverter based on the loadshedding status
  • Time Mode - I use the Time Mode to trigger feeding back into my non-essential loads on certain days of the week.  Due to my solar setup currently being undersized to power the entire house on days when my domestic worker (higher loads due to washing, tumble dryer, ironing etc) is here, this allows me to save some additional power on the alternate days by feeding back into the non-essentials.

A note for everybody else, if you want to access the dashboards then go to the following address http://[your pi's IP]:1880/ui

Hey @Bloubul7

Hope you're well. Thanks for all the work here (and @Sc00bs).

I'm trying to get your UI all working but seem to be struggling, can you help me out please? #willsendbeer

Here are a few things:

1. System Settings - I can't get the System Settings to "READ" when I click the button
2. Default Settings - This seems to work, I can READ \ SAVE (not sure where it's actually saving)
3. Load Shedding Settings - This seems to work, I can READ \ SAVE (not sure where it's actually saving)
4. Time Mode - This UI works, haven't used it

So here are a few questions that I have:

1. In the "Solar - Time Zones" section, the Time_Zone 1-6, how does this translate to the actual time?
2. System Settings - I can't seem to read my existing values, any idea how to debug this?

Might be a ton of questions after this :D

TIA

Crash

2 hours ago, Sc00bs said:

@crashThere are some Node Red settings that need to be changed to allow you to save variables in the flows, not sure how to do it exactly

Thanks. I think I've got it sorted (so far!) for the Reading part. I can now read my current settings onto the dashboard, save my default and load shedding settings on the dashboard. I've also got the load shedding check sorted so it polls the site to check the load shedding status.

Next task to tackle is enabling the write flows and write back to the Inverter *gulp*

On 2021/09/23 at 8:18 AM, kellerza said:

This runs on Hassio/HassOS and needs the RS485 connected locally to USB. But MQTT does not have to be local…
 

In my setup I have 2xraspberries. Both run HassOS and the HassOS with the RS485 uses this addon to send to my main HomeAssistant’s MQTT server

(it should also be possible to run a usb to tcp modbus gateway on “that other” raspberry and run this addon remotely)

Hi all :)

 

@kellerza I am looking at possibly using your addon. My inverter is far away from my NAS which has Home assistant running in a Docker container. So if I were to emulate your setup then I'd purchase a Raspberry PI, install HassOS on it, hook it up to the inverter and let it push events via WiFi to a remote MQTT server (which also happens to run on my NAS)? Is HassOS not too "heavy" for essentially a bridge from the inverter to the MQTT server?

I'm also considering doing what @Bloubul7 and @JuanH did with the RS485 HAT.

I'm just wondering which option is better, without having procured the PI yet:

  1. Get a PI Zero W, install HassOS and use USB to RS485 (RJ45) cable from Solar Assistant Shop to speak to the inverter, Home Assistant from HassOS running on the PI publishes to a remote MQTT server on the NAS via WiFi which the Home Assistant on the NAS can pick up, or
  2. Get a PI Zero WH, add a RS485 HAT, one end of a Cat5e cable connects to the HAT, the other end is crimped with RJ45 to speak to the inverter, install Raspberry PI OS with NodeRed (is this combo correct?) and let NodeRed publish to the MQTT server on the NAS via WiFi.

Did I get the above options right? Which option do you think is the better one?

  • Author
19 minutes ago, SolarConvert said:

Hi all :)

 

@kellerza I am looking at possibly using your addon. My inverter is far away from my NAS which has Home assistant running in a Docker container. So if I were to emulate your setup then I'd purchase a Raspberry PI, install HassOS on it, hook it up to the inverter and let it push events via WiFi to a remote MQTT server (which also happens to run on my NAS)? Is HassOS not too "heavy" for essentially a bridge from the inverter to the MQTT server?

I'm also considering doing what @Bloubul7 and @JuanH did with the RS485 HAT.

I'm just wondering which option is better, without having procured the PI yet:

  1. Get a PI Zero W, install HassOS and use USB to RS485 (RJ45) cable from Solar Assistant Shop to speak to the inverter, Home Assistant from HassOS running on the PI publishes to a remote MQTT server on the NAS via WiFi which the Home Assistant on the NAS can pick up, or
  2. Get a PI Zero WH, add a RS485 HAT, one end of a Cat5e cable connects to the HAT, the other end is crimped with RJ45 to speak to the inverter, install Raspberry PI OS with NodeRed (is this combo correct?) and let NodeRed publish to the MQTT server on the NAS via WiFi.

Did I get the above options right? Which option do you think is the better one?

I would recommend option 2 with Raspberry PI OS lite.

As a 3rd option you can also look at using USR-W630 Modbus RTU at the inverter side.  Home Assistant has the modbus protocol built in and you can poll the modbus addresses directly from HA.  USR-W630 Industrial Serial to WiFi and Ethernet Converter Supports 2 E – Reliable Store

 

Great 3rd option, thanks @Bloubul7!

I have no idea how much data is transferred when monitoring inverter stats, but presumably with option 2 the Modbus polling is local and you can filter the data at source (by the inverter) with NodeRed therefore transferring less data over wifi, whereas with option 3 all the raw data transfer and polling would happen over WiFi? Or is that not a concern at all? I literally have no idea whether this makes a difference or not :)

I see @kellerza does have an addon for option 3 here and with me struggling to find stock of the Pi Zero WH this is looking like a good option.

10 minutes ago, SolarConvert said:

Great 3rd option, thanks @Bloubul7!

I have no idea how much data is transferred when monitoring inverter stats, but presumably with option 2 the Modbus polling is local and you can filter the data at source (by the inverter) with NodeRed therefore transferring less data over wifi, whereas with option 3 all the raw data transfer and polling would happen over WiFi? Or is that not a concern at all? I literally have no idea whether this makes a difference or not :)

I see @kellerza does have an addon for option 3 here and with me struggling to find stock of the Pi Zero WH this is looking like a good option.

I'm currently using this option, but logging the data with node-red and Modbus module.

Basically using Bloubul7's node-red config, but the USR-W610. 😀
 

Edited by KempM

3 minutes ago, KempM said:

I'm currently using this option, but logging the data with node-red and Modbus module.

Basically using Bloubul7's node-red config, but the USR-W610. 😀
 

Thanks @KempM, so to understand, node-red is polling the USR-W610 over WiFi? And you have no latency or bandwidth issues, all monitoring is real-time? If so I'm adding the USR-W610 to my shopping cart now :)

Correct.

No issues.

You can use the W630 also. It has 2 ethernet ports compared to the W610 with one ethernet port. Basically the same device. 

On 2021/12/03 at 6:11 AM, system32 said:

Thanks,
Subscribed to the beta program and got the Home-Assistance Energy integration working well:
image.png.fe8b27def5d7fd3622e780327c4f4fed.png

 

The battery charge/discharge % per hour on Solar-Assistant is a nice touch:image.thumb.png.4719d40a9e1504bbfec80058f6e2d824.png

The additional details [Battery in/out, Grid in/out] on the Totals tab is useful data:
image.png.b7b70cc885ab43b119e634f21b6e2510.png

 

Also making use of the additional MQTT kWh topics instead of calculating them myself from elapsed * kw.

solar_assistant/inverter_1/ac_output_voltage/state
solar_assistant/inverter_1/battery_current/state
solar_assistant/inverter_1/battery_voltage/state
solar_assistant/inverter_1/grid_frequency/state
solar_assistant/inverter_1/grid_power/state
solar_assistant/inverter_1/grid_voltage/state
solar_assistant/inverter_1/load_power/state
solar_assistant/inverter_1/load_power_auxiliary/state
solar_assistant/inverter_1/load_power_essential/state
solar_assistant/inverter_1/load_power_non-essential/state
solar_assistant/inverter_1/pv_current_1/state
solar_assistant/inverter_1/pv_current_2/state
solar_assistant/inverter_1/pv_current_3/state
solar_assistant/inverter_1/pv_power/state
solar_assistant/inverter_1/pv_power_1/state
solar_assistant/inverter_1/pv_power_2/state
solar_assistant/inverter_1/pv_power_3/state
solar_assistant/inverter_1/pv_voltage_1/state
solar_assistant/inverter_1/pv_voltage_2/state
solar_assistant/inverter_1/pv_voltage_3/state
solar_assistant/inverter_1/temperature/state
solar_assistant/total/battery_power/state
solar_assistant/total/battery_state_of_charge/state
solar_assistant/total/battery_temperature/state
solar_assistant/total/battery_energy_in/state
solar_assistant/total/battery_energy_out/state

solar_assistant/total/grid_energy_in/state
solar_assistant/total/grid_energy_out/state
solar_assistant/total/load_energy/state
solar_assistant/total/pv_energy/state

Thanks, keep up the good work.

Hey dear, what kind of RS485 pinaout are u using.
Im from Brazil and bought Solar Assistant, but im getting CRC failure with my RS485 adaptor.

10 minutes ago, mauriciosti said:

Hey dear, what kind of RS485 pinaout are u using.
Im from Brazil and bought Solar Assistant, but im getting CRC failure with my RS485 adaptor.

I bought the  USB/RS485 cable from Solar-Assistant.io

Should be easy enough to make one.

9 minutes ago, system32 said:

I bought the  USB/RS485 cable from Solar-Assistant.io

Should be easy enough to make one.

The cable has a different pinout? Is not a standard RS485??

Good evening 

Need some help debugging my setup please. 

My piZero worked for months and writing to my MQTT server. Had to disconnect the setup to take my battery in. Since reconnecting it, it is no longer working. 

Did my USB-TO-RS485 get damaged or did the Sunsynk firmware update cause something to break?

Debug only shows:

Client not Ready To Read At State reconnecting 

ModBus failure on state sending..... 

 

Thanks

16 hours ago, swazz99jhb said:

Good evening 

Need some help debugging my setup please. 

My piZero worked for months and writing to my MQTT server. Had to disconnect the setup to take my battery in. Since reconnecting it, it is no longer working. 

Did my USB-TO-RS485 get damaged or did the Sunsynk firmware update cause something to break?

Debug only shows:

Client not Ready To Read At State reconnecting 

ModBus failure on state sending..... 

 

Thanks

Looks like my unit id on the Sunsynk was changed from 1 to 0 with the firmware updated. Changed under Advance on Sunsynk. Working again. 

  • 1 month later...
25 minutes ago, system32 said:

@kellerzaIs there a python library to read the Hubble AM-2 BMS (either via RS232 or RS458)
Solar-Assistant is able to read and present some of the BMS values.

@system32 I have not seen any python library for the BMS, but have not really searched that much. I do have an AM-2, but I don't have an RS-232 cable. If you have documentation with the registers it will take a couple of hours to implement.

Solar Assistant is a good product and I really liked it when I evaluated it. I'm glad they finally publish the kWh data to MQTT. When I tried a demo this was limited to power data, so I spent a couple of evenings and built the Sunsynk Addon. The result is you now have an open-source solution to push data to Home Assistant, but my intention is not to compete with Solar Assistant's display or detailed data retention (I did trigger a detailed feature request to Pierre, so like to think we're all better off 😉)

It helped that Sunsynk had the modbus registers nicely documented and there were already some Node-Red examples floating around on the forums!

@Bloubul7
Thank You, this is awesome work, I followed your guide to get direct data from my Sunsynk and I must say, IT FREAKING WORKS GREAT !!!
Next I will try your settings integration and then automate the heck out of my system.
I cannot believe all these years I did not use nodered, that is an awesome bit of kit.

No more need for crappy dongle data and guessing what the hell is actually going on inside :)

Edited by WannabeSolarSparky

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.