-
Notifications
You must be signed in to change notification settings - Fork 5
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
Extra battery sensors to easily integrate with the Energy Dashboard #44
Comments
I'm not entirely sure about adding "fake" sensors here — it could make the codebase overly complex. I know the sensors' naming is not the best, but I've tried to keep it as close to the official application as possible. HomeAssistant already has a quite good integral sensor that can be easily set up via UI or YAML, I'd lean towards writing some sort of guide in the README file to instruct users on how the sensors work and how to create better kWh sensor than to add it directly in this integration. That said, I understand the frustration with the kWh sensors provided by the device, I had to create my own DC power meter and coulomb counter using esphome because the inverter ones are quite useless and have low resolution and precision. For reference, I've used these custom ones for some time: sensor:
- platform: integration
name: Battery Out
unique_id: 'battery_out_kwh'
source: sensor.battery_out
unit_prefix: k
unit_time: h
round: 2
method: left
- platform: integration
name: Battery In Solar
unique_id: 'battery_in_solar_kwh'
source: sensor.battery_in_solar
unit_prefix: k
unit_time: h
round: 2
method: left
- platform: integration
name: Solar Production
unique_id: 'solar_production_kwh'
source: sensor.pv1800_charger_power
unit_prefix: k
unit_time: h
round: 2
method: left Where:
|
I agree that more documentation would be a good step, I've stared at these sensors for hours trying to make sense of what they truly are. Thanks for your template sensors! That said users will want to use this integration to fill their energy dashboard, having an almost mandatory manual "post-install" that could very easily be included seems counter productive. I also couldn't help but notice that you have solar production as charger_power, on my unit I use accumulated power. Maybe because my unit is entirely offgrid, but half the sensors always measure 0. (yes, I reset it today, but it has charged/discharged the battery due to clouds) In any case, if there's more information on where these sensors are and what they are measuring I will make sure to read it. |
@p4block Most of mine measures 0 as well.
From my experience:
|
@mukaschultze those are the assumptions I had initially, I will write down my thoughts: charger power goes to both battery and load. Thankfully we have standalone battery and inverter sensors for that. I arranged the three together in my dashboard to more or less make sense of what's happening. In this picture taken just before sunset it's getting 10W from panels (lol) +65W from battery are feeding the inverter which is outputting 24W.
discharger power in theory should be the same as
But I recall having problems with it, I will compare in a few days. After the values repopulate. load power seems good but seemingly useless for the Energy Dashboard. It's also 0 for me, but it wasn't before I reset it. Weird. power is good and I am feeding it directly as solar input in the dashboard self use power is actually increasing since I reset it, unlike load_power. Maybe it has something to do with the offgrid status or some settings in the mppt. I have it set to SOL right now, but didn't in the past. Thanks a lot for your help 💯 |
Again, from my experience: The AC power sensor used in the inverter is super low precision for small loads, mine would sometimes report negative values when drawing less than 50W, above this threshold it correctly reported the same as a CT clamp. The solar power (charger power) and battery power were precise even for small loads. The battery voltage sensor is absolute trash, with a slope error of ±1V. The solar panels' voltage was correct with only ±0.1V offset. There are ways of "calibrating" the sensors, but I tried that and it doesn't make them any better. My measured efficiency from battery power to AC power was about ~80%. |
I am drawing <10W, my unit seems to not fuck up that hard it goes into negative. It's very consistent and all values check out. It's not exactly the same, but efficiencies below 50% are not unheard of in computer PSUs at <10% load and I'm here asking a 5kW inverter for 0.01kW The clamp is currently off as I had to unplug half to house to conserve power, when I get it back up I can provide more accurate information. I want to shutdown the inverter part and measure how much the device itself draws from the battery at night (using a laptop, bye house). From all indicators, it's far, far from 0. |
Checklist
Is your feature request related to a problem? Please describe.
The energy dashboard for HA requests various sensors, some of which (I think) are not directly provided by the Must inverter. Namely, the battery kwh in and kwh out sensors.
Describe the solution you'd like
The integration should do more things than read registers and present them to user, it should add these useful sensors that are not in the MPPT itself.
We have a sensor that has the instantaneous power in and out from the battery, with some magic it's possible to convert it to kwh in and out.
Describe alternatives you've considered
I made the sensors myself with chatpgt, but they are error prone. This is actually a thing that I encounter often and I always resort to some hacks, a well built solution coming from here would be best.
Additional context
In general, I found that the sensors provided by the inverter are not very good for human-readable consumption. Naming is very confusing and they hardly map to HA's (or my) needs.
The battery one for the energy dashboard is the most obvious one, but I'm sure that thinking this through reveals many more.
The text was updated successfully, but these errors were encountered: