I have some esphomatized power plugs around and added them. Works
Would it be also possible to calculate the exact costs in Grafana? What I want to do is to make an alert when my costs are over my monthley payments. For example, I pay 140 euro each month to my energy supplier. After 25 days in the current month I Used eneregy for 141 euro, then I want an alert, So I need ot be carefull, If I won;t pay more.
EDIT: I think I created the cost stats in grafana with the following query:
SELECT (last(âvalueâ) - first(âvalueâ)) * 0.76963 + 0.67639 FROM âm3â WHERE (âentity_idâ = âgas_consumptionâ) AND $timeFilter GROUP BY time(1d)
0.76963 = the cost per m3 gas
0.67639 = the cost I pay every day to the supplier for gas
For electricity:
SELECT (last(âvalueâ) - first(âvalueâ)) * 0.22376 + 0.82292 FROM âkWhâ WHERE (âentity_idâ = âpower_consumption_lowâ) AND $timeFilter GROUP BY time(1d)
SELECT (last(âvalueâ) - first(âvalueâ)) * 0.23899 FROM âkWhâ WHERE (âentity_idâ = âpower_consumption_normalâ) AND $timeFilter GROUP BY time(1d)
Apologies for resurrecting this old thread. I had a close look at the DSMR section of the utility meter component. You directly feed the watts sensor into the utility meter sensor. Is that correct? I was under the assumption that I should feed the watts sensor -> integral sensor -> utility meter (but that is producing some very strange values sometimesâŚ)
Can you indicate the right approach?
How do you have the integral sensor set up? If you donât have that set up properly, youâll get bad results.
EDIT: In case you respond and I donât see it.
If you are always consuming power (above 0) and it has rolling consumption like a sine wave use the default value (method: trapezoidal).
If your power drops to zero for extremely long periods of time and spike very high (like a square wave), use method: left.
Iâve never found a good use case for method: right.
Thatâs pretty cool! I was using something similar but stopped the conversion to cost, because costs change over time. I.e. this year electricity is more expensive compared to last year (in Holland), so I figured the most âpureâ measurement I want to look at is the amount of energy I use and see if this can help make us more aware of that and find ways to reduce it.
Hi Frank, not sure I completely understand your question, but what I do to get daily power consumption is:
I use packages (for now) to setup the parts of my config, so I have setup the utility meter like this:
utility_meter: !include_dir_merge_named ../utility_meters
and then in the ../utility_meters
directory I have created files for the various instances I want to keep track of, for example:
daily_power_used_offpeak:
source: sensor.power_consumption_low
cycle: daily
And this works nicely (I think ), although I have been away from home assistant for a while, just getting back into it again now.
Hope this helps!
For me this doesnât look like you are using packages, more like âjustâ splitting your configuration. Or is this part in the âpackages:â section of your configuration.yaml?
yeah it is but I did not paste all of it here
packages: !include_dir_named components/packages
And then in that directory is the file utility_meter.yaml
mentioned in the previous post. That then includes the components/utility_meters folder where all the sensors are defined in separate files.
I saw something similar in someone elseâs config and it was a lot better then the mess my config was in at the time, so I started moving. I believe it was based on @frenck 's setup he had at some point, but I am not sure entirely.
I see, didnât even know you can do includes inside packages (includeception ). Good to know for the future, until now Iâm comfortable with my packages.
Yeah, I am continuously trying to find ways to structure it so that it keeps making sense to me. But, HA has come a long way with managing setups. I love how new esphome nodes just show up as newly discovered integrations. Awesome!
That must be it! I am having especially problems with my electrical boiler which has got some spikey power consumption (see screenshot) and its power consumption is quite overrated. Will try your suggestion.
You definitely want to use left with that graph. Youâll get the correct results instead of results that are wildly off
Hi @aetjansen,
Great video, thank you!
I am collecting power consumption from the blink led of my power meter. Therefor, what I get is Wh and not W. How to use your dashboard and goes from Wh to W?
Thanks!
Thanks @mgim,
You could edit the graph panels in the dashboard to select the different measurement for your situation, but be aware that W and Wh are two different things.
Watt is an indication of power where Wh (Watt hour) is an indication of energy.
Power is measured in Watt and tells the rate at which energy is used. For example, a 10W led light, uses 10 Joule/second. Wh is a measure of energy consumption, so using the same 10W led light as an example: if you leave that on for an hour, it uses 10Wh of energy.
Think of it this way:
Watt tells you how much energy is consumed (or produced) at any given moment in time.
Watthour tells you how much energy is consumed (or produced) over a period of time (1 hour in this case)
Hope that helpsâŚ
Thank you so much @aetjansen
Indeed, it was quite useful to analyse Watts for instant device consumption.
Is there a way to go from W to Wh in grafana? Maybe derivative or something?
Hi. I discovered just now your nice work on grafana about Energy dashboard. Iâm trying to realize something similar. Could I kindly ask you to share an exported version of the dashboard (json format) in order to see better how you design the graphs? Iâll appreciate if you can do it but no problem if you prefer not. Thank in advance.
Did you ever get a response?
Hi aetjansen. I need to thank you for your answer. But Iâm interesting to the only electricity dashboard as @orange-assistant realized. If you have material like that it will be appreciated. Thank you again. Bye