-
-
Notifications
You must be signed in to change notification settings - Fork 30.5k
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
Goodwe integration not working with LAN module #114173
Comments
Hey there @mletenay, @starkillerOG, mind taking a look at this issue as it has been labeled with an integration ( Code owner commandsCode owners of
(message by CodeOwnersMention) goodwe documentation |
I had the LAN module in my GW15K-ET and in general it works. The problem is the change of IP address. I preferred to use the already discovered instance in order to keep the data. Just go into the directory where your configuration.yaml lives, cd into to .storage and edit core.config_entries where you search for your old WiFi address of the Goodwe and change it to the LAN IP address. Restart HA and your inverter is back in business. |
I will try it out, not sure if there was a IP change problem, this happened when I setup a new integration using the IP I got from the LAN module. But I will try your solution later today and update the ticket if it works. |
I just tried it out and it did not work. As soon as the LAN module is connected (updated IP in HA as you wrote and restarted HA) it cannot send anything to HA, nothing is recived. Even trying to reload the device in HA did not help or adding a new one using the LAN IP. Instead SEMS Portal start working again which stops working when using the WIFI module (does not matter to me). Not sure which LAN module you have, I have the new one, version 2 which is a LAN/Wifi module. But when using the module which only has Wifi then its works again with HA. From what I understand this integration uses UDP modbus but the new LAN/Wifi module (version 2) seems to be using TCP modbus. But I could be wrong or perhaps that doesn't even matter? |
How did you configure the LAN/WiFi module? |
What do you mean with configure? I just insert LAN cable in to the module and use the LAN IP in HA. The SolarGo app had some settings for Wifi or LAN. I'm sure I have tried to shutdown wifi and only have settings for LAN but it did not help. |
You need to select LAN as the "Internet access port" within SEMS Portal WiFi-configuration (I know, "WIFI-configuration" is a bit misleading...). You may want to watch the Goodwe Configuration video of the Wii-Fi+LAN-kit on youtube |
I am having what seems to be the exact same issue with my inverter - GW5000-DNS-30. Worked fine with the wifi module while I waited for the LAN/Wifi module to arrive. |
Looking into this further the only open port that I can find is TCP 502 with nmap. I no longer have the wifi only module to compare this to but I suspect @ivik has hit the nail on the head that its not using UDP anymore, just TCP |
Apologies, I have found port 48899 open |
48899 is the "discovery" port of the module itself. It should not be a rocket science to add TCP support, but since I don't have such interface at hand, it might be a bit difficult to implement it in blind or over some mock ... |
What is exactly the LAN/WIFI module type/version ? |
I finally found some doc regarding the 2.0 version of the WIFI/LAN module - https://www.memodo.cz/media/pdf/a4/e4/21/sa-e-20230921-001statement_of_wifilan_kit-20_2b87cc807f18fb171fecf24308f64207.pdf Can you confirm it is the 2.0 version you have ? |
Hello @mletenay , what me concerns I received the old version. |
I just got my WIFI/LAN module today, I set it up as LAN, and gave it a static IP, and got it connected now with the GoodWe HA integration. I don't think it's the latest version though, I got the module from the company that placed my inverter, so i didn't ordered it myself. I added some pictures below, i'll let y'all know if it stays stable. If i can answer any questions, let me know. |
Yes I have version 2, please check above pictures. |
So to summarize it:
|
I think the summarization is correct. The v2 seems to be working with TCP/modbus instead of TCP. If it helps, I can connect the new v2 again and give you raw data on output but you need to help me a bit and tell me what I need and what I should do. I have not worked with modbus before but if you can dumb it down a bit perhaps I could help extract data? I tried downloading a windows app to check the modbus connection but the app was a freeware and in half Chinese and half bad english so I could not understand what I needed to do in order to get any meaningful data out of it. I also tried to do what Ralf suggested but that does not work since the v2 only handle configuration using bluetooth and not wifi. For now I'm using the Wifi only kit which works fine, no SEMS portal access anymore (don't care, SEMS sucks anyway) but it would be nice to get of Wifi and use LAN instead... |
@ivik I have started coding the TCP support, but it make take couple of days/week until I have something usable. |
Sure thing, just let me know when you have anything ready for test. |
@ivik So, I implemented the Modbus/TCP protocol and tested it as much as I could on simple mocks. |
Not much is happening, it prints couple rows and nothing else happens. I have waited 5 min before I killed the script: 2024-04-24 17:04:11,179 init(54) - DEBUG: Using selector: SelectSelector But this is done using the Goodwe python from PIP. (goodwe_test) PS C:\Users\Erfan\anaconda3\envs\goodwe_test\goodwe-master> python.exe .\tests\inverter_check.py The line above the import error tells the path to the Goodwe module (non PIP version) but it says:
Should I not be:
I tried that as well but still same error.... |
@ivik The ../../ stuff assumes you are running it from test directory as python inverter_check.py, if you run it from parent, then yes you have to adjust it. |
I tried again, after couple of attampts it started to try DT family inverter and I killed the script. 2024-05-02 20:42:30,327 init(54) - DEBUG: Using selector: SelectSelector |
Thanks for the feedback, I'm going to analyze it. Anyway, this github ticket is fine place to collect feedback and discussion, but sometime it might be more efficient to talk directly. |
@xrsprint @ivik Something quite odd is happening there. |
I have not seen output like the one @xrsprint have displayed. Not sure if we have the same issue or we are talking about 2 different issues. We have different inverters so there could be different issues/bugs we are talking about. But let me know when you have new code and I will try it out. If possible, create a script that does sensor reads each 10s or whatever and I will have it go for couple of minutes and see what happens. Perhaps you could put the update time in a variable which I could play around with if needed. |
and if anyone wants me to run any scrips, more than happy to, might need a couple of pointers on how to run it 📦 |
@xrsprint @ivik I have made some adjustments to the code.
If you checkout the latest sources from the https://github.com/marcelblijleven/goodwe, you can find new python script stability_check.py in the tests folder. It should connect to the TCP server and send request every 5 seconds in a loop. |
Thanks for that @mletenay i will give this a go this afternoon and report back. Im still not sure how to run scripts but will update the source and let you know Thanks again for the great work and will revert back ! |
@mletenay I downloaded the new code. I ran it and it worked but had strange output: C:\python\goodwe\tests> python.exe .\stability_check.py But then I changed your script a bit and added output for actual sensor values, I made this change: `
` That made it more interesting, it was able to do the output of all sensors for 7 runs but it then crasched: 2024-05-14 23:22:18,699 get_runtime_data(38) - INFO: ################################ I also tried to change the sleep time to 10s and tried again, it had the same crash as above after run number 6. 2024-05-14 23:32:40,963 get_runtime_data(38) - INFO: ################################ |
Hi Everyone i tried and tired, but still couldnt figure out how to run the scripts, but i uninstalled and re-installed the app to the new Lan module and was getting the same thing only thing I also noticed is in the integration logbook, every five seconds the timestamp is updated, an on each fouth update is when we loose the entities, then on the next update they come back hope this helps in some way :) |
@ivik The output confirms previous observation - there is more and more garbage at the end of response until it crashes. Use this invite link - https://discord.gg/TaXyWXT |
@ivik I have added standard pymodbus library version to stability_check.py to find out whether my code is wrong or not. |
Just FYI - I've collected data both via my code and standard pymodbus. |
Just FYI - see the announcement on discord - the v0.9.9.20 is out there and should be production ready with the "keep alive" flag turned off. |
Hi, sorry for late reply, been busy lately. I have 5s polling and it has been working great the last 5min. |
If you only configure the LAN part then your Goodwe will continue to broadcast the internal WIFI ssid, and worse, it starts to function as an access point. Connecting to the internal WIFI will get you access to the wired LAN segment and even the internet. |
@ivik Do not close it yet, the code is still in HACS only and has to mature a bit to port it to core HA. |
Just wanted to report in, it still works great! |
Great! Thanks. |
Still going strong, no issues at all! Close this ticket whenever you feel it's time to close it but for me it all works great! |
I will create a new ticket directly under the goodwe integration page but something has happened the last couple of 3-4 days. It looses connection couple of times each minute. I have also tried using different version of the goodwe code, still same issue, all the way back to 0.9.9.25. I will add more info under a new created ticket: mletenay/home-assistant-goodwe-inverter#292 |
I received the version 2.0 of the Wifi/LAN Kit, installed it Tuesday and works perfect with the modbus setting. The only thing I recognized: regardless of polling interval below 20 seconds: it will not poll shorter than 20 seconds, bug or feature? @ivik : did you check for changes in your environment? New firmware versions? |
For me it works with 5s interval. I changed to 10s to see if it behaves better after the issue, did not make a difference. Not sure about new firmware updates. I received a new Goodwe unit (same model as before) and updated it to the newest version of everything. Could have been some new firmware that was updated but pretty sure it was the same as old the old unit (arm v8). |
How do i get the coms module updated, when i use the solargo app no new updates are displayed. |
I received my updates due to an open ticket (my ET 15 pushed >100 watts into grid when on battery). You could register there and open a ticket to get the latest updates pushed: |
Goodwe updated firmware, ARM and Communication module, I did not get new DSP firmware and the communication module is not v 2.0.1 but it is newer then the one I had before. So far it looks and works good. I will continue talks with Goodwe and see if I can get a new DSP firmware and newer Communication module firmware. Communication module firmware, I had: v1.2.32 but now I got: v1.3.53 |
Is there any solution to the issue using the v2 WIFI/LAN Module? I'm using a GW20K-ET inverter with the v2 WIFI/LAN Module (WLA0000-01-00P) and have the same issue. |
Not sure what problem you are referring to, but the V2 is supported in the experimental HACS version of the integration - https://github.com/mletenay/home-assistant-goodwe-inverter. |
The problem
I have a GW15K-ET which works fine with HA GoodWe integration when using the Wifi module.
But as soon as I change to the LAN/WIFI module then HA is not able to find it anymore.
I remove everything and start new integration, I give it the LAN IP and it says "Unknown error occurred"
Same if I give it Wifi IP from the LAN/Wifi module.
But If I remove everything again, change to only Wifi module and give it the IP then it works great.
LAN/Wifi module works as I can see data in SEMS portal.
I found some info in the logs, please see below
What version of Home Assistant Core has the issue?
core-2024.3.3
What was the last working version of Home Assistant Core?
No response
What type of installation are you running?
Home Assistant OS
Integration causing the issue
GoodWe inverter
Link to integration documentation on our website
https://www.home-assistant.io/integrations/goodwe
Diagnostics information
No response
Example YAML snippet
No response
Anything in the logs that might be useful for us?
Additional information
No response
The text was updated successfully, but these errors were encountered: