Noob here. Any suggestions how I can get energy costs calculations for my Sonoff POW?
I live in Spain and the tariffs have just changed to three different rates at different times
I guess what I need to do is first is put the tariff prices in then write an automation to tell HA what tariff is currently active, ie PEAK, MID or OFFPEAK then create the calculations.
This is what I have found on the forums so far but not sure how to get this all working together:
I was expecting your next post to be about you not having energy sensors, and me having to explain the integral integration, but you searched and sorted it yourself. Well done.
One thing to be aware of is the method option in the Riemann integral.
My recommendation would be to make the utility rates per tarrif input number that you can control through the UI. This way if your rate changes you can just adjust it in the UI versus having to edit code.
Not that you have to do this. Just an option I take. I decided to not hard code any values into my automations, scripts, template sensors, … and do everything with input_number, input_select, and input_boolean and I have a dashboard in Home Assistant where I can maintain all of these values. I don’t make updates to the values often but it does help. Plus I have told my wife about this dashboard so she can adjust values herself. For example, she used to say “can we make the hallway lights less bright at night” and I would have to adjust the automation. Now she knows there is an input for this and she can just change it.
The comments you made helped to prompt me to look for the solution rather than ask stupid questions that are posted in the docs and other topics so thanks @tom_l
Going to now get myself a Shelly EM to monitor the whole house as the Sonoff POW was a test and only monitoring the new refrigerator
I like the Shelly EM. I use it myself and it has performed faultlessly for years - other than a wifi connection issue that was firmware fixed soon after. It gives me a good estimate of my quarterly bill (+/- 5%). Not sure where the inaccuracy is coming from. It should be better than that.
However just the other day I was alerted to this option you can use with ESPHome (if you are into DIY). It’s a great deal cheaper and seems to work well: