Open otello86 opened 1 year ago
Same problem. I still don't know how to fix
Hello there, same issues after trying to set this up today. In my case a Sofar ME 3000SP. No error messages either, it seems that it can't connect to the device for one or the other reason. Did a port scan and ports 80 and 8899 (ospf-lite) are open.
I can't connect over the IP:8899 either using a browser. This returns however an error --> Cancelled Load from http://IP:8899 because it is using http/0.9
Willing to do some testing but don't know where to start.
Hi, same here but i have Sofar 8.8 KTLX-G3. for now i see that different port gives "Connection refused" and 8899 stalls for 40 seconds.
I have the same issue. Afore inverter with Solarman logger. Able to log in on the IP adress, hacks reports connected but no values on the sensors in HA. Logger SN 17xxxxxx
IP:8899 not able to connect. Is there any port forwarding required or other ports that are in use for this.
Another ME3000SP here. Device serial 23xxxx Telnet connection can be made on port 8899 from the home assistant cli interface. 40 entities are created but I don't seem to be able to gather data. Willing to test if wanted / needed.
@mcasteels : there is a sofar_wfikit.yaml file included when you clone the repo
I removed the solarman integration completely and then redownloaded it again.
This time, before adding it to the interface, I copied the sofar_wifikit.yaml over the sofar_lsw3.yaml and then proceeded by adding the integration again.
It seems to read some data now from my inverter seeing this in the logbook:
Then I can click through and see the state of the battery charge during the full last day, meaning it connected and read historic data:
Right now, I added the counters to the battery dashboard but they don't seem to update yet anyway.
I am seeing this as good news, seems there is a possibility to read the data of the inverter while all other have failed for me.
@s0x00c ,
Thanks for that great info. I was using the HACS integration and that is different than the one on the site! I always assumed that these are the same. I had first some issues but ended up doing the following and that was a win. No shortcuts, tried it and ended up to be more work. So really step by step (again thanks to your info)
I can see the logbook entries and connection is made and noticed some updates (SN, software version, …). Verified entity by entity and I do see info. No more unknowns for the moment. Still need to verify the data versus the API. Looks promising.
Before I had several issues trying your solution. What changed it in the end … Delete all the Solarman integrations (HA and HACS! I also had a disabled one) and restarted after each change and not accumulate to only restart once.
@mcasteels Do you have a possibility to add to the energy dashboard? I see this link: https://github.com/StephanJoubert/home_assistant_solarman/blob/main/energy.md but that definition is not in the sofar_wifikit.yaml. Would it be possible just to copy those entries over and see if they pick up anything?
Well, I tried that, but copying in the definitions from another yaml config file doesn't work. We would need the exact modbus "addresses" to read the correct values.
@mcasteels Do you have a possibility to add to the energy dashboard? I see this link: https://github.com/StephanJoubert/home_assistant_solarman/blob/main/energy.md but that definition is not in the sofar_wifikit.yaml. Would it be possible just to copy those entries over and see if they pick up anything?
I was able to add entries to the Energy Dashboard, but really limited and I think that the ones I could add (daily solar panel) will not add anything useful. I can't add the battery system.
Well, I tried that, but copying in the definitions from another yaml config file doesn't work. We would need the exact modbus "addresses" to read the correct values.
that is what I tried before and nothing helped. the only way I could get it working now is thanks to your info. To be honest I even did not test the sofar_lsw3.yaml. I just used the sofar_wifikit.yaml but renamed it to the sofar_lsw3.yaml and point to that one when setting up the integration. Seems that these SOFAR's are not always defined in the same way. Mine is just used for the battery system and has sensors too look at my solar panel system (that was already installed +10 years ago). The battery was installed 2 months ago.
Well, I tried that, but copying in the definitions from another yaml config file doesn't work. We would need the exact modbus "addresses" to read the correct values.
that is what I tried before and nothing helped. the only way I could get it working now is thanks to your info. To be honest I even did not test the sofar_lsw3.yaml. I just used the sofar_wifikit.yaml but renamed it to the sofar_lsw3.yaml and point to that one when setting up the integration. Seems that these SOFAR's are not always defined in the same way. Mine is just used for the battery system and has sensors too look at my solar panel system (that was already installed +10 years ago). The battery was installed 2 months ago.
Same here, I would like to see the battery integrated in the 'energy dashboard'.
The funny thing is, I can actually see the battery charging / discharging graphic, but no way to add it to the energy dashboard in separate counters
Same thing here.
Well, I tried that, but copying in the definitions from another yaml config file doesn't work. We would need the exact modbus "addresses" to read the correct values.
Yes, I think this is also my issue. Currently I have no information on the adress list for my setup with AFORE inverter. Can't find this anywhere.
@mcasteels So, eventually I found the solution: We needed to split up the charge / discharge counter with a riemann calculation: (in the configuration.yaml file)
template:
- sensor:
- name: "Battery Charge Power"
state_class: "measurement"
device_class: "power"
unit_of_measurement: "kW"
icon: mdi:battery-plus
state: >-
{% set e = states('sensor.solarman_battery_charge_discharge_power') %}
{{ e|float(0)|abs if e|float(0) >= 0 else 0 }}
availability: >-
{{ states('sensor.solarman_battery_charge_discharge_power')|is_number }}
- name: "Battery Discharge Power"
state_class: "measurement"
device_class: "power"
unit_of_measurement: "kW"
icon: mdi:battery-minus
state: >-
{% set e = states('sensor.solarman_battery_charge_discharge_power') %}
{{ e|float(0)|abs if e|float(0) <= 0 else 0 }}
availability: >-
{{ states('sensor.solarman_battery_charge_discharge_power')|is_number }}
and get that data then in the energy dashboard with adding this to the configuration.yaml file
sensor:
- platform: integration
source: sensor.battery_charge_power
name: battery_charge_energy
round: 2
- platform: integration
source: sensor.battery_discharge_power
name: battery_discharge_energy
round: 2
This gives you everything you need to get the data in the energy dashboard
@s0x00c Will have to try it out. Can I just copy paste this in the configuration.yaml?
Yes, in reverse order than I posted it
@s0x00c I'm noob concerning programming! Just Copied the data as you mentioned. First the last part to define the sensor, then the template. They are both together in one section of the configuration.yaml. I do have other sensors created Currently no go. See below screenshot.
The sensor in the template that you use is exactly the same name as in my config.
Any idea what I'm doing wrong?
My config
This is what I have in configuration.yaml
I haven't changed anything else I think.
Same as you, I am NO programmer. I just copy paste and adjust where needed.
If you did these changes while the inverted was not sending power to the batteries, it's normal to get the (unknown) error.
Then, after 2 hours, when the batteries are charging, you should see data and the unknown error should go away on its own.
Maybe try the forum of tweakers.net to get more specific help if you can.
@s0x00c I don’t know why. Did not check it since I tried and it works 🫣.
Thanks again for the share of info. Only thing I still want to figure out is do isolate some values as W instead of KW. All other sensors of equipment are published in W. Looks weird when you put several together in one card. Also verified the results between the online API and the direct network connection.
Info have weird numbers so I’m wondering what you added as input
For Solarpanels I’m using
and the battery with your config
That is where my dashboards differs from yours. I get my solarpanels info from my SMA device, NOT from solarman, so I won't be able to help you on that front, I am sorry.
No problem, battery settings are similar to yours? Actualy solar looks look it's rather the battery in combination with the rest.
yes, my settings are the same for the battery as yours.
I have sunsynk hybrid inverter, followed every step in the READM but still entities are unavailable. In the logs I get a connection refused error. IP address of wifi datalogger is correct but am not sure about the port [8899] because it doesn't show as open.
Hi, same here but i have Sofar 8.8 KTLX-G3. for now i see that different port gives "Connection refused" and 8899 stalls for 40 seconds.
Hello. Have you please managed to solve the issue?
Hi, i try to use this integration with my Sofar HYD-5000ES with wifi logger (S/N: 23XXXXXX). I put on all the parameters and restart HA but all the sensor stay in status “unknown”. I try different .yaml configuration but the sensors still have unkown status I don’t have any error message in log and i don't know if the connection to the datalogger works or not I also try autodiscover mode but without success
The integration is in version 1.4.1 HA works HA OS in version 2022.10.2