Starting a new thread as this was getting lost in the Hints, Tips & Troubleshooting thread.
Post details of your integration with Home Assistant etc.
I haven't got the pysolarmanv5 to work on my me3000, but it seems others have got the solarman intergration running.
The sofar registers are completely different (well on its rs485 connection)
Have a peek here
https://www.facebook.com/groups/2477195449252168/?ref=share
It's the Facebook group for the sofar automation.
Hi all,
I had solar installed at the start of August and have been spending the last number of weeks looking at the reports from the Solarman smart app. I have also been following along here to see what others are doing regarding automation etc. and have been convinced to spend some time at it. I started at the start of this thread and am trying initially to get the Home Assistant Solarman integration working. I have the integration showing on Home assistant but it is not giving any information. I've tried using pysolarmanv5 to query my inverter (I have a solarman data logging stick with a Sofar HYD 6000 EP inverter) but I am not getting any information back from any of the input registers (30000+) and getting a CRC error when trying to read the holding registers (40000+).
Sorry for the basic question but is there something I am doing wrong or does pysolarmanv5 not work with Sofar inverters? I don't think i'm using a newer logger as the serial number is 10 digits beginning in 235. From memory the firmware on the logger begins with LSW3 and not some of the firwares mentioned earlier in this thread. Has anyone managed to get this working on a Sofar inverter or knows if the mapping is the same/similar to that in the TCD pdf.
I would be grateful for any advice, hints or tips at this point.
I bumped the battery size in my calculation up to 6250 and it seems to be closer. My charge started at 2am and finished at 4.41am. I was aiming for 5am so at least it's under that time. I may drop it down slightly and see how that goes. Certainly the 5kWh PureDrive is more than 5kWh gross.
I also revised my automation to avoid errors. Now, if the target is lower than the current state of charge it will set the amps to 0 rather than calculate a negative value. Also I've set a lower level as I found it wouldn't accept below around 4A. So, the range it will work in 5-50A. It will calculate the appropriate charge amps based on the target % and time allowed. Both of these are set from a card. I may automate the target.
Nice spot, thanks for that, fixed. I'm sure that register has min-max values (you'd hope) and it wouldn't accept 1000A 🤣
Maybe that was in there in the original post and was fixed later? I don't think I messed around with anything other than the values at the top.
Its in the API, global radiation.
what data bank /forecast specifically are you all using for the sunlight forecast. I don’t see what might be relevant on met.ie?
You've got a bug in there @SD_DRACULA .
See this line:
{% elif current_needed_a > 1000 %}
It should be comparing to 100, not 1000, as that variable is Amps. You run the risk of setting up to 1000A (10000 deciAmps) in the subsequent else block the way it is there, which is in unknown territory for the Solis. That whole if-else block acts as a safety-clamp to keep within the register ranges, as well as converting from Amps to deciAmps.
See original post here with the correct value:
Other than that, glad to hear that its working well for you.
Could it be that usable is 5kWh and gross is 6.2kWh? I can't see net/gross specs anywhere on it - just 5kWh. With 10,000 cycles and 1C charging & discharging it must have a buffer of some sort surely?
This is essentially what I've been doing. I'm setting it to charge until it reaches my input target. The change now is that I'm also trying to get it to spread the charging over the cheap tariff hours (2-5am) rather than at the start.
The issue I'm seeing is that it's taking approx 1.25-1.3x the kWh to charge vs discharge, so it ran over and took until about 5.45am to charge.
Are these normal losses?
Here's my automation for anyone interested
alias: Solis - Timed Charge description: "" trigger: - platform: time at: "02:00:00" condition: - condition: state entity_id: input_boolean.solis_timed_charge state: "on" action: - service: script.inverter_write_holding_register data: register_addr: 43141 register_value: >- {{ ((((states('input_number.time_charge_soc') | int - states('sensor.solis_battery_soc') | int) /100 * 5000/100*states('sensor.solis_battery_soh') | int ) / states('sensor.solis_battery_voltage') | int) / states('input_number.solis_timed_charge_hours') | int) | round(0) *10 }} - delay: hours: 0 minutes: 0 seconds: 15 milliseconds: 0 - service: script.inverter_write_holding_register data: register_addr: 43110 register_value: 51 - wait_for_trigger: - platform: template value_template: >- {{ states('sensor.solis_battery_soc')|float > states('input_number.time_charge_soc')|float -1 }} - service: script.inverter_write_holding_register data: register_addr: 43141 register_value: 0 - delay: hours: 0 minutes: 0 seconds: 15 milliseconds: 0 - service: script.inverter_write_holding_register data: register_addr: 43110 register_value: 49 mode: single
That was my initial thought as well but with working out the charge Amps you get a lower and longer charge rate which is better for the batteries anyway and the added bonus is that this way the car can get charged during the night period without having to mess with pausing the battery as all is running from grid.
Can you use a different approach - charge and watch the SOC% constantly, and simply stop charging when the SOC% reaches your target level ?
I do this with Node-Red and my ME3000, telling it to charge overnight until SOC hits xx%.
I assume you drain that down to 10% which would mean 4500wh usable.
This is the script I use with Home Assistant and it is very accurate, maybe 1-2% higher charge than I set it to but but close enough that it doesn't bother me (cannot complain about more usable power)
set_night_charge: alias: "Set Night Charge" icon: mdi:flash variables: charge_voltage: 53 charge_hours: 9 night_usage_wh: 3500 battery_capacity_wh: 20480 lower_soc_limit: 15 now_soc: "{{ states('sensor.solar_battery_soc') }}" target_soc: "{{ states('input_number.grid_charge_to_soc') }}" soc_to_wh: "{{ (battery_capacity_wh / 100) | int }}" now_battery_usable_wh: "{{ ((now_soc - lower_soc_limit) * soc_to_wh) | int }}" target_battery_usable_wh: "{{ ((target_soc - lower_soc_limit) * soc_to_wh )| int }}" energy_storage_mode: >- {% if (now_battery_usable_wh - night_usage_wh) > target_battery_usable_wh and is_state('input_boolean.force_always_charge', 'off') %} 49 {% else %} 51 {% endif %} charge_needed_wh: "{{ target_battery_usable_wh - (now_battery_usable_wh) }}" current_needed_a: "{{ ((charge_needed_wh/charge_hours) / charge_voltage) }}" current_needed_deci_amps: >- {% if current_needed_a < 0.1 %} 0 {% elif current_needed_a > 1000 %} 1000 {% else %} {{ (current_needed_a * 10 ) | int }} {% endif %} sequence: - service: script.inverter_set_energy_storage_mode data: storage_mode: "{{ energy_storage_mode }}" - delay: seconds: 30 - service: script.inverter_set_charge_current data: current_da: "{{ current_needed_deci_amps }}"
You'd want to plug in your version of these values:
charge_voltage: 53 charge_hours: 9 night_usage_wh: 3500 battery_capacity_wh: 20480 lower_soc_limit: 15
No, using my own. Basically getting the difference between current SOC and my target then multiplying by battery size (5000) and dividing by voltage to get amps. Rounding off to zero decimal places and multiplying by 10 to convert to the deciamps that the Solis wants.
I can't find anything about usable capacity on the PureDrive DC batteries. If I look at the discharge kWh and % change in SOH, then it matches up with 5000Wh. The charging kWh and % change in SOH don't match.
Are you using @connesha code a few pages back?
The only thing I can think of is to check the values of the battery voltage, max Wh, min % SOC, total Wh, usable Wh, etc
I updated my timed charging automation last night so it calculates the charge rate in amps based on the battery state of charge and voltage. Intention is to fill the cheap rate time rather than charge to 100% in a short time.
However, it seems that the actual charge added was about a third extra than the calculation so it ran over the allotted time. It's a PureDrive II 5kWh DC battery that I have. I worked out the amount to charge based on difference between 100% and SOC and 5000 for the battery size.
Am I missing something? losses? battery bigger than 5kWh? bit of everything?
wow, that forecast is surprisingly accurate. That really is not what I would have expected. I am religious about checking the weather!
Mine has changed to. Up from 1.73kWh to 1.97kWh on 4.8kWp,
but not at the times I stated above. This update was around 10am, rather than the more normal 05:00/11:00/17:00/23:00 Summer time that I have seen before
My forecast for tomorrow has crept up from 1.3 to 1.8kWh 😅
It's improved marginally. I was computing under 2Kwhr for tomorrow, but I see it's jumped to a whopping 2.2kwhr now. Yaah, "Go solar!" - LOL
I might have asked this in the wrong post, has anyone built the sofar2mqtt with MAX3485?
Trying to figure out if I can use the Tx/Rx pre soldered pins or is there something else on the board I need to wire to.
That's good to know on the time for the updates to the forecast. Yeah, my forecast for tomorrow is rotten. It's showing 1.3kWh on my 4.5kWp~ SW system. I guess I'll be charging tonight.
I am also using @Jonathan met eireann script, but I have been running it every hour. This shows me that the forecasts are updated around 06:00/12:00/18:00/24:00 UTC (subtract 1 hour for summer time) if you are trying to get the "Latest" prediction.
Will have a look at your script as well. 👍️
As @bullit_dodger says on the daily PV production thread, tomorrow looks terrible in the West as well = 1.76kWh on 4.8kWp system.
Tesla thing; https://www.tsmart.co.uk/videos
basically a replacement element and thermostat, or you can just buy the thermostat and smart head piece. From there you can set desired temperature and or times remotely.
The Shelly might do the same thing or close enough if a fairly accurate temp can be retrieved by its externally probe.
Eddi is a difference beast, and 4x or 5x the price.
I've been playing around a bit with the met eireann forecast and finally got it roughly where I want. Will see how that goes now.
Each night after generation has stopped, the accuracy (estimate vs generation) is updated on a sensor. Then I have a statistics sensor getting the 7 day mean of that accuracy. Finally, that 7 day accuracy is now being brought back into the script.
Other changes include the time restrictions which are to avoid wiping out the today forecast when running the forecast for tomorrow. I usually call the forecast for today at 1am and then tomorrow at 8pm.
import datetime from weatherforecast import WeatherForecast @service def meteireann_solarforecast(): weather = WeatherForecast(53.54321, -6.12345) weather.load_weather_data() accuracy = float(state.get('sensor.solar_forecast_accuracy_7_day')) /100 arrayMultiplier = 0.187*23.104/1000 # panelEfficiency * panelArea(m2) / 1000 (to kWh) today = round(weather.get_radiation_for_date_total(datetime.date.today()) * arrayMultiplier * accuracy,1) tomorrow = round(weather.get_radiation_for_date_total(datetime.date.today() + datetime.timedelta(days=1)) * arrayMultiplier * accuracy,1) current_time = (datetime.datetime.now().strftime("%H:%M")) if "00:00" < current_time < "07:59": state.set("sensor.meteireann_solarforecast_today", today,{'friendly_name':'Met Éireann Solar Today','icon':'mdi:solar-power','unit_of_measurement':'kWh','device_class':'energy'}) state.set("sensor.meteireann_solarforecast_tomorrow", tomorrow,{'friendly_name':'Met Éireann Solar Tomorrow','icon':'mdi:solar-power','unit_of_measurement':'kWh','device_class':'energy'}) elif "08:00" < current_time < "23:59": state.set("sensor.meteireann_solarforecast_tomorrow", tomorrow,{'friendly_name':'Met Éireann Solar Tomorrow','icon':'mdi:solar-power','unit_of_measurement':'kWh','device_class':'energy'})
You could add a relay board to an Eddi, with PT1000 sensor to read temps.
But what does the Tesla thing do ??
I had not considered that as I was keen to be able to see the temperature in the tank, but I have now seen Shelly has a temp add on, which I guess could get a sufficiently accurate reading from outside the tank, (inside the outer insulation/covering).
This seems to be the shelly option Jonathan? https://shop.shelly.cloud/temperature-sensor-addon-for-shelly-1-1pm-wifi-smart-home-automation#313?
And a shelly one relay?
the current setup is one of the APT immersion timer, two 3kw immersions one near bottom one 1/3 down tank.
Rather than having to swap out the immersion, why don't you just swap out the immersion timer switch for something like a Shelly and a contactor?
I think an Eddi modulates power to the tank? Any excess PV goes to tank correct me if wrong?
This is just a smart timer which includes a thermostat and some smart functions- but your 3kw immersion will be on or off at 3kw?
and around 400 euro.
What's the difference between that and an Eddi ?
Has anyone fitted a tesla t-smart for the immersion, or a similar product? It looks like it would be a big advancement for my setup and management. Especially if one could trigger it to come on during high PV production.