Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Connection issues for SunGrow SH3.0RS #403

Open
MattiaPette opened this issue Nov 18, 2024 · 12 comments
Open

Connection issues for SunGrow SH3.0RS #403

MattiaPette opened this issue Nov 18, 2024 · 12 comments

Comments

@MattiaPette
Copy link

Hi, in my residential installation I've installed a Sungrow SH3.0RS which I do not know if it's officially supported with this project (the readme mentions SH3.RS, SH3.6RS and i guess mine is the first one ? ) product page link

I have a small problem connecting to the inverter with the ethernet. I've plugged in the free ethernet port you see in the below image and it seams that it gets an IP from my DHCP ip pool but when portscanned or pinged it doesn't do anything, which probably is the reason the integration does not work.
Is the port the correct one? Is the inverter supposed to not have any tcp port open or not be pinged? Is it because this particular model does not have support at all?

The black ethernet cable was installed by the technician and I've honestly no idea where it goes (maybe to the small device they added to my electrical box?)
This is the only free ethernet port other than the one with the WLAN cloud dongle they added (which honeslty I would like to remove if it safe to do so, i do not need yet another device remotely connected to somewhere)
PXL_20241116_160646233 RAW-01 COVER
PXL_20241116_160820874 RAW-01 COVER

@Gnarfoz
Copy link
Contributor

Gnarfoz commented Nov 18, 2024

Check page 42 of your inverter's manual. It describes the COM2 port in detail.
In short: there is no secondary Ethernet port on this model.
You can still connect to the WiNet-S via Modbus, though, preferably via its Ethernet port. If that is only connected via Wi-Fi, unscrew the cap and connect a cable, if you like. You can then disable Wi-Fi on the WiNet-S.
It doesn't just connect "somewhere", btw, but to Sungrow's iSolarCloud, the "normal" way to monitor and manage Sungrow solar systems. Sungrow's inverters can mostly be operated without it, if you spend the necessary time to learn the ins and outs of alternatives like this project.

Another alternative would be to connect a RS485 to Ethernet converter to COM2 ports A1 and B1, bypassing the WiNet-S altogether.

@MattiaPette
Copy link
Author

Ok, so if I understand It correctly, that free ethernet port Is for DRM which Is something I do not have to worry about because it's only needed in some countries. The second eth Port which Is already plugged in Is for modbus TCP, and somehow it's already in use by my installator (maybe for remote assistance?)

I do not understand the WiNet-S thing as my installator wont let me use the phone application as "It voids my warranty" if I manage It by myself, i have not seen the app and I do not know what's all about It.

It leaves me the last thing to try and wireup a cable for the COM2 port and try that.

My goal with this Is not to manage my inverter from homeassistant but to receive metrics for my kiosk tablets and automations in HA and Better handle the energy stored in the batteries.

@Gnarfoz
Copy link
Contributor

Gnarfoz commented Nov 19, 2024

I'm not sure what your IP scan showed, but neither of those RJ45 connectors is an Ethernet port. Refer to page 42 of the manual. The DRM port is indeed for connecting a device controlling the inverter according to the requirements set by the power company. The other port is for connecting a battery, which you seem to have, so that's why it's in use.

The WiNet-S dongle does two things: it feeds data to Sungrow's iSolarCloud so it has something to show you, and it offers Modbus TCP access for local use. Depending on your inverter model, the data available via Modbus might vary. Refer to the most recent Modbus register specification as of October 2024 for details.

Regarding the app: your installer is lying to you.
The iSolarCloud app and website are for use by owners of Sungrow solar installations. It shows things like energy production, consumption, power, earnings, etc. Things any solar power operator should have access to. How else would you know anything about your installation's performance?
iSolarCloud offers customer and installer privilege levels and nothing the customer role can do should jeopardize your warranty (which is offered by Sungrow, not your installer, keep that in mind).
Your installer can (and probably should) retain installer-level access to your installation. Only they can adjust important / dangerous parameters.
It's possible that your installer is (wrongly) operating your installation as if it was his own installation, or they have multiple customer installations in the same account, so giving you access would also give you access to other customer's installations.
Whatever the reason may be: this is your device and you are owed access to it.
Make them set it up for you, you paid for it. Make them set up an "owner" type account in iSolarCloud for you / with you (or create the account yourself), and have them set this account as the owner of your installation. They'll use their installer code to add themselves to the installation with installer-level access. You can always kick them out later, if that becomes necessary. You can even make an installer account for yourself and share your installation from your owner account to your installer account, granting you full access. Not recommended unless You Know What You Are Doing™️, though.
Further reading:
https://en.sungrowpower.com/productDetail/987/cloud-platform-isolarcloud
https://www.isolarcloud.eu/
https://play.google.com/store/apps/details?id=com.isolarcloud.manager

The COM2 port encompasses the two RJ45 connectors (DRM & battery) as well as the two pin blocks. Check page 42 (PDF page 52) of the manual to learn more.
Just wiring up a cable to pins A1 + B1 would not be enough. You would need a RS485 to Ethernet converter like for example this one (or similar): https://www.waveshare.com/RS232-485-TO-ETH-for-EU.htm

@MattiaPette
Copy link
Author

Hi, thank you so much for taking the time to write this.
I am indeed settling things with my installer and as for the account usage I will probably set them up as installer access account and me as owner as it the right thing to do (i paid for it I might as well use it). I'm going to just ignore the fact that I will have limited warranty as it's not true at all.

Correct me if I'm wrong, for this project I can't just use the modbus tcp rj45 connector at the bottom of the WiNet-S dongle and I need to buy that adapter (I think I have one laying around from an old work project, I might give it a shot), connect the two pins A1 + B1 and ground to feed into the adapter, use a standard ethernet cable to connect to the device to my network and use the IP address in the integration configuration.

@Gnarfoz
Copy link
Contributor

Gnarfoz commented Nov 19, 2024

Correct me if I'm wrong, for this project I can't just use the modbus tcp rj45 connector at the bottom of the WiNet-S dongle [...]

Despite what the big warning on the README of this project says, I would at least give this a try. Recent firmware versions of the WiNet-S dongle have improved its Modbus behavior at least a bit. It's possible that not all registers are available. Depending on if/which registers are missing, that might be irrelevant (stuff like serial numbers), annoying (things like energy counters, you could implement those yourself in Home Assistant by deriving the data from the power values), or deal-breaking (basic things like inverter running state that are required to know what the device is doing).
Modbus TCP should be available on the WiNet-S's IP address on port 502, regardless of if the WiNet-S connects to your network via Wi-Fi or Ethernet. It think it's actually able to connect via Wi-Fi and Ethernet at the same time, but don't quote me on that. ;-)

Using an adapter and tapping directly into the inverter of course bypasses any issues or limitations the WiNet-S might have, at the cost of a bit of time spent tinkering.
One note when dealing with Sungrow connectors / plugs: use appropriate wire ferrules to terminate the wires that you plug into the connector. Just like on your initial photo for ports A2/B2.

@NigelPearson
Copy link

This morning, to test this HA stuff, I connected my SG3.0RS like this:
IMG_0806
Just have to remove the waterproof connector from the end:
IMG_0805

Then a scan of my network showed a second device from vendor 'Espressif Inc.', which was the new direct wired IP address. It seems both the WiNet and the Ethernet can work at the same time, because I could ping both of the IP addresses?

@Gnarfoz
Copy link
Contributor

Gnarfoz commented Dec 27, 2024

That's the WiNet-S in both cases then. Once via Wi-Fi and once via Ethernet. It can probably do both at the same time, but Sungrow recommends against that in the manual (page 52) and I don't think you'd gain anything from doing that. The inverter itself does not have a dedicated Ethernet port (see page 35 of the manual).

You can fit the waterproof gland and the cable at the same time (that's what it's for, after all). Just feed the cable through it before inserting it into the Ethernet socket.
See page 53 of the manual.

@NigelPearson
Copy link

NigelPearson commented Dec 28, 2024

Christian, I would fit the gland if I wasn't using a patch cable (i.e. it already has RJ45s at both ends :-)

Initial modbus queries don't look good. It responds to register addresses 4949 thru 5018, but most of them are FFFF:
% ./mbtget.pl 192.168.0.16 -u 1 -a 4949 -n 10
values:
1 (ad 04949): 65535
2 (ad 04950): 65535
3 (ad 04951): 65535
4 (ad 04952): 65535
5 (ad 04953): 65535
6 (ad 04954): 65535
7 (ad 04955): 65535
8 (ad 04956): 65535
9 (ad 04957): 65535
10 (ad 04958): 65535
% ./mbtget.pl 192.168.0.16 -u 1 -a 4999 -n 10
values:
1 (ad 04999): 2024
2 (ad 05000): 12
3 (ad 05001): 28
4 (ad 05002): 20
5 (ad 05003): 4
6 (ad 05004): 2
7 (ad 05005): 207
8 (ad 05006): 170
9 (ad 05007): 1000
10 (ad 05008): 65535

% ./mbtget.pl 192.168.0.16 -u 1 -a 5009 -n 10
values:
1 (ad 05009): 65535
2 (ad 05010): 65535
3 (ad 05011): 65535
4 (ad 05012): 65535
5 (ad 05013): 65535
6 (ad 05014): 65535
7 (ad 05015): 65535
8 (ad 05016): 65535
9 (ad 05017): 65535
10 (ad 05018): 65535`

@Gnarfoz
Copy link
Contributor

Gnarfoz commented Dec 29, 2024

I missed it, since you're posting in an issue about the SH3.0RS, but you're using a SG3.0RS. That's a totally different device that does not use the same set of Modbus registers. That's also the reason why it's not on the list of inverters this project currently supports.
You can try adjusting the relevant sensors yourself using the SGxRS register spec: https://github.com/Gnarfoz/Sungrow-Inverter/blob/main/Modbus%20Information/TI_20230117_Communication.Protocol.of.Residential.and.Commerical.PV.Grid-connected.Inverter_V1.1.53_EN.pdf

Regarding the WiNet-S Ethernet port: the rubber gasket has a cut in so you can clip it around pre-fabricated cables:
image
https://info-support.sungrowpower.com/application/pdf/2024/08/08/SG2.0-6.0RS-UEN-Ver22-202408.pdf (page 54, step 4)

@NigelPearson
Copy link

NigelPearson commented Dec 30, 2024

Oops, yes, I missed the SH vs SG detail.

  1. Is it possible that my SG series has encrypted modbus communications:
    https://github.com/rpvelloso/Sungrow-Modbus
    https://brettbeeson.com.au/hacking-the-sungrow-5-inverter

I have not verified this yet. If it does, I will try the RS485 interface.

  1. Despite the beautiful diagram in the manual, no slit in the rubber grommet:
    f8sahAwwS+O4zaud6+91mA_thumb_5e5a

Easy enough to make a cut myself, though!

@Gnarfoz
Copy link
Contributor

Gnarfoz commented Dec 30, 2024

True, easy enough. 👍🏻
Is this ridge not a factory-made cut, though? It was on my WiNet-S... Or is this a WiNet-S2?
Screenshot_20241230_134901_Chrome

@NigelPearson
Copy link

Good eyes, Christian. I twisted, then pushed an engineer's ruler in there, and it did separate!
(it is like the rubber re-sealed under heat and clamping pressure)

I think it is WiNet-S.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants