Jump to content

SunSynk - Inverter Monitoring


Bloubul7
 Share

Recommended Posts

I can't believe it's taken me this long to find this forum/thread, I've been doing it by myself on a set of 3 Deye Inverters (I think they're Sunsynk rebrands or vice versa?). 

I am looking to optimise my battery storage/grid export implementation from an efficiency standpoint. Having 3 inverters sitting active the whole time is wasteful when a single inverter being active covers 99.9% of my house's normal power consumption needs. (I have the 3 inverters because I'm on Octopus Agile in the UK so I need to pull as much from the grid I can in as short (cheap) period of time).

I can use the node-red interface to modify essentially every useful Modbus register with the exception of ID 417 which controls the inverter Parallel settings. I want to edit this register so I can disable (turn off) inverters (I have relays hooked up to the power buttons on the undersides), enable/disable parallel, then switch on only the inverter(s) I want running (essentially the minimum for the load/grid charge power I want at any given time). According to the tech at Deye (who replies once in a blue moon) this is possible (he's shown me vague and blurry modbus messages confirming this), but I can't get it to work, or at least I don't know what state(s) the inverters need to be in for it to work.

Can anyone who has more than one inverter running in parallel see if they can write register 417 (clearly with the inverters switched off/disabled to prevent damage) and have the changes reflected in a subsequent read? (For this I'm trying to read/write 1026 (dec) 0402 (hex) to this register for parallel off, and 1027/0403 for parallel on, which matches the Deye tech's values).

Well up for a conversation with anyone about this, it's good to find some like minded people! :D


 

Link to comment
Share on other sites

Welcome tjs000 ,

I would suspect that it may have something to do with the format in which you are trying to write the settings. Maybe if you try the process the other way around, you may be able to get an answer from DEYE on how to set it up manually and then just write those settings back to the inverter. 

Firstly I would have a look at Bloubul7's Node Red flows and see if it currently reads the 417 registery settings (I would guess that it doesn't) and then rewrite the flows to just read the 417 registry. Store the setting so you can write them back when necessary.

I would then try and set up the inverter manually to switch off the unused inverters, if you can get that to work then read the 417 registry again to see how the settings are changed with the unused inverters switched off and then save those settings.

The 417 registry is marked as R/W so you then should be able to just switch between the settings by writing the settings that you have stored.

Good luck. 

Link to comment
Share on other sites

Hi Sc00bs, 

Thanks for the reply. I'm pretty sure the format is correct. I have requests/registry reads in my flow(s) already, and the values I'm trying to write are the ones that changing settings on the touch-screen results in on the inverter.

Switching the inverters on/off using the button at the bottom doesn't change any of the parallel settings, the only way I've found to do this is using the Parallel Settings screen in the advanced settings menu. With Parallel off (on the master), value is 1026, and on is 1027. On inverter 2 (slave) it's 2048 and 2049, and on inverter 3 it's 3072 and 3073.
image.png.4933a81bdea3112e919e1107516d0189.png


I can observe/read register 417 changing when I change the settings on the touch screen, but writing the registry with these values changes nothing. I read/write values using the same methods on every other registry I've tried, but 417 does/will not change. 
 

image.thumb.png.5aeb4a8d94c73237b9df95d5b1756b5f.png

The flow is a bit of a mess, but until I can turn Parallel on/off, I get all the info I need from other sources (other power monitors, BMS interfaces, spoofing Battery SoC, the on/off button relays etc), so this is purely for testing..

Link to comment
Share on other sites

  • 2 weeks later...

I have just installed a Sunsynk 5kw 1P and came across this thread started by @Bloubul7 and the other one started by @Sc00bs and looks to be exactly what I'm after as I'm already running Home Assistant with some smart switches and lights around the house.
Thank you to all who have been involved in this.

I would like to get clarity on something please. Am I correct that I can plug-in the RS-485 to USB adapter into my HA box and do all this from the same device?
I gather I would still run the MQTT output from the flows and then get HA to read the MQTT from itself so I use various values from the inverter to trigger things in HA?

My HA is running on an Intel NUC, Celeron with 4Gb RAM, do you think it will cope with this extra load?
I have a 20m USB cable, with signal booster in the middle, running from where my inverter is to the cabinet where the NUC is. I had that USB cable from my old Infinisolar inverter to a PC running Solarpower for a while with no issues so hoping it will work for the RS-485 so I don't have to try run a new LAN cable.
I do have a Pi I could use closer to the inverter but am trying to avoid that if possible if I can just run it from the NUC...

Link to comment
Share on other sites

1 hour ago, RhysMcW said:

I have just installed a Sunsynk 5kw 1P and came across this thread started by @Bloubul7 and the other one started by @Sc00bs and looks to be exactly what I'm after as I'm already running Home Assistant with some smart switches and lights around the house.
Thank you to all who have been involved in this.

I would like to get clarity on something please. Am I correct that I can plug-in the RS-485 to USB adapter into my HA box and do all this from the same device?
I gather I would still run the MQTT output from the flows and then get HA to read the MQTT from itself so I use various values from the inverter to trigger things in HA?

My HA is running on an Intel NUC, Celeron with 4Gb RAM, do you think it will cope with this extra load?
I have a 20m USB cable, with signal booster in the middle, running from where my inverter is to the cabinet where the NUC is. I had that USB cable from my old Infinisolar inverter to a PC running Solarpower for a while with no issues so hoping it will work for the RS-485 so I don't have to try run a new LAN cable.
I do have a Pi I could use closer to the inverter but am trying to avoid that if possible if I can just run it from the NUC...

I can't see any reason why it wouldn't be able to work. As long as the RS485 converter doesn't mind the long USB cable. Which rs485 USB do you have? Had problems with the one mentioned in the previous posts, and ended up with a Pi Zero and a 485 hat. Cpu load on the nuc is of no concern. 

Link to comment
Share on other sites

14 minutes ago, jacauc said:

I can't see any reason why it wouldn't be able to work. As long as the RS485 converter doesn't mind the long USB cable. Which rs485 USB do you have? Had problems with the one mentioned in the previous posts, and ended up with a Pi Zero and a 485 hat. Cpu load on the nuc is of no concern. 

Great, thanks @jacauc will continue with the setup.
Yeah, I got the same RS485 that was mentioned to have issues, before I found the mentions of the issues, going to give it a try anyway but will get another one if it is a problem, will short connect it to a Pi if needed for testing to confirm if it works or just my long USB cable as a problem.

Link to comment
Share on other sites

4 minutes ago, RhysMcW said:

Great, thanks @jacauc will continue with the setup.
Yeah, I got the same RS485 that was mentioned to have issues, before I found the mentions of the issues, going to give it a try anyway but will get another one if it is a problem, will short connect it to a Pi if needed for testing to confirm if it works or just my long USB cable as a problem.

I mean it works, just not perfectly. 

Link to comment
Share on other sites

2 hours ago, RhysMcW said:

I have just installed a Sunsynk 5kw 1P and came across this thread started by @Bloubul7 and the other one started by @Sc00bs and looks to be exactly what I'm after as I'm already running Home Assistant with some smart switches and lights around the house.
Thank you to all who have been involved in this.

I would like to get clarity on something please. Am I correct that I can plug-in the RS-485 to USB adapter into my HA box and do all this from the same device?
I gather I would still run the MQTT output from the flows and then get HA to read the MQTT from itself so I use various values from the inverter to trigger things in HA?

My HA is running on an Intel NUC, Celeron with 4Gb RAM, do you think it will cope with this extra load?
I have a 20m USB cable, with signal booster in the middle, running from where my inverter is to the cabinet where the NUC is. I had that USB cable from my old Infinisolar inverter to a PC running Solarpower for a while with no issues so hoping it will work for the RS-485 so I don't have to try run a new LAN cable.
I do have a Pi I could use closer to the inverter but am trying to avoid that if possible if I can just run it from the NUC...

Hi Rhys

It will all run on an Intel Nuc Box running HASS with the suplimentary apps installed. Home Assistant brings everything together and provides connections to most IOT devices, MQTT for direct current values in HA, Node Red for the Automations & linking to the Modbus connection on the inverter, Influx DB for storing all the time based data that it gathered by Node Red and Grafana for being able to format the data in a graphical way that is easy to understand and customise.

The flows that Bloubul7 wrote have been updated and are being maintained by Jacauc on his Guthub page  https://github.com/jacauc/SunSynk-NodeRed to include the feed from NR into the MQTT running on HA.

 It took a little time for an "average joe" like me, to wrap my head around, and a LOT of youtube videos on Node Red and Home Assistant, but in the end it is reasonably easy to understand the basics once you understand how everything links together. 

If you get stuck just give us a shout 🙂  

 

 

Link to comment
Share on other sites

I have been thinking of trying out a Waveshare RS485-Ethernet converter for my connection to the Inverter as it would allow me to move my NUC from out of my garage next to my inverter. 

Has anyone else tried one of these out? 

https://www.waveshare.com/rs485-to-eth.htm 

I have one lying around so will give it a bash in any case and see if it works better than the USB - RS485 adapter

Link to comment
Share on other sites

On 2021/06/10 at 10:54 AM, tjs000 said:

Hi Sc00bs, 

Thanks for the reply. I'm pretty sure the format is correct. I have requests/registry reads in my flow(s) already, and the values I'm trying to write are the ones that changing settings on the touch-screen results in on the inverter.

Switching the inverters on/off using the button at the bottom doesn't change any of the parallel settings, the only way I've found to do this is using the Parallel Settings screen in the advanced settings menu. With Parallel off (on the master), value is 1026, and on is 1027. On inverter 2 (slave) it's 2048 and 2049, and on inverter 3 it's 3072 and 3073.
image.png.4933a81bdea3112e919e1107516d0189.png


I can observe/read register 417 changing when I change the settings on the touch screen, but writing the registry with these values changes nothing. I read/write values using the same methods on every other registry I've tried, but 417 does/will not change. 
 

image.thumb.png.5aeb4a8d94c73237b9df95d5b1756b5f.png

The flow is a bit of a mess, but until I can turn Parallel on/off, I get all the info I need from other sources (other power monitors, BMS interfaces, spoofing Battery SoC, the on/off button relays etc), so this is purely for testing..

Hi TJ 

On the Modbus document that I have, it has the 417 Register marked as R/W so strange that it cannot be written to. 

Maybe someone else who has more experience with Modbus can comment, can only guess that there may be some other setting/value that needs to be changed to allow that value to be written. 

Good luck, keep us posted please. 

 

 

sunsynk_modbus - no chinese.docx

Link to comment
Share on other sites

22 minutes ago, Sc00bs said:

Hi Rhys

It will all run on an Intel Nuc Box running HASS with the suplimentary apps installed. Home Assistant brings everything together and provides connections to most IOT devices, MQTT for direct current values in HA, Node Red for the Automations & linking to the Modbus connection on the inverter, Influx DB for storing all the time based data that it gathered by Node Red and Grafana for being able to format the data in a graphical way that is easy to understand and customise.

The flows that Bloubul7 wrote have been updated and are being maintained by Jacauc on his Guthub page  https://github.com/jacauc/SunSynk-NodeRed to include the feed from NR into the MQTT running on HA.

 It took a little time for an "average joe" like me, to wrap my head around, and a LOT of youtube videos on Node Red and Home Assistant, but in the end it is reasonably easy to understand the basics once you understand how everything links together. 

If you get stuck just give us a shout 🙂  

 

 

Thanks @Sc00bs, yeah I've been running HA for a while now, previously on a Pi 4 but changed to the NUC about a month back, with NodeRed. I use NodeRed for the logic and HA for the pretty UI with buttons etc to trigger NR flows.
It also took me a while to get into HA and NR but really like it now so looking forward to having some decent inverter data do do more. My previous Infinisolar and ICC was very flaky and the MQTT from the ICC was down more than up so couldn't do much with the data.
I did read through the thread you started and saw the mention of the Github by @jacauc which I have downloaded, thank you @jacauc for putting that together.

Link to comment
Share on other sites

Happy to help. Unfortunately NR flows are not very good on a platform like github because of all the coordinate values, but it does the job I guess. 

Been looking at getting a NUC. Where did you buy it from and are you happy with the performance? 

Want to run all of the above on it, and maybe plex media server also. 

Link to comment
Share on other sites

2 minutes ago, jacauc said:

Been looking at getting a NUC. Where did you buy it from and are you happy with the performance?

I found it on Facebook but actually got screwed a little. The post stated it was one of the i5 models but when I got it home and powered it on I discovered it was actually the Celeron version, so if you do look at one second hand make sure you get the model number off it's base sticker and Google that model to confirm its spec.
Even though it's only the Celeron CPU (with 4Gb RAM) it is significantly better performing than the Pi 4 (with 4Gb RAM) so still very happy with it, I may just upgrade the RAM to 8Gb though as I see HA likes using RAM so want to give it some more. It's not super heavy on RAM but if you drop into the shell in the OS and run "top" you can see it uses what it gets, which is not a bad thing (Linux based OS's handle memory great compared to crappy Windows) but I'm sure it would benefit from some more.

Link to comment
Share on other sites

44 minutes ago, jacauc said:

Happy to help. Unfortunately NR flows are not very good on a platform like github because of all the coordinate values, but it does the job I guess. 

Been looking at getting a NUC. Where did you buy it from and are you happy with the performance? 

Want to run all of the above on it, and maybe plex media server also. 

I got am I5 slightly older version for R1500 on Facebook, is way faster than a Pi3 and loads more space, 16gb ram and a 256gbSSD

Link to comment
Share on other sites

4 hours ago, Sc00bs said:

I have been thinking of trying out a Waveshare RS485-Ethernet converter for my connection to the Inverter as it would allow me to move my NUC from out of my garage next to my inverter. 

Has anyone else tried one of these out? 

https://www.waveshare.com/rs485-to-eth.htm 

I have one lying around so will give it a bash in any case and see if it works better than the USB - RS485 adapter

Yes, I have used the waveshare wifi unit as my first attempt and didn't have any issues. The polling rate was slightly slower than the Raspberry Pi though.  But we are talking miliseconds

Edited by Bloubul7
Link to comment
Share on other sites

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...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...