Peak and offpeak tariffs - need to setup multiple tariff changes per day

Hello there man,
so I was today trying to check the electricity measurement and here are the results:

1, The peak / off peak tariffs together with their relevant prices are switching fine and correctly.

2, I setup a completely new power plug with measurement and added this outlet power sum consumption to the energy dashboard and setup the price from the sensor we have made in the config.


3, Then I ran my electric heater in the peak tariff for 15 minutes (17:55 - 18:10).


4, The complete consumption for these 15 minutes was 0,42 kWh and it was calculated as 1.33 CZK.
That is a bit odd, because that means 1,33 / 0,42 = 3,1666 CZK and it should be 3.24802 CZK.
There I can see the only problem now.

5, For example the other entinty “kotel” which calculates price from the sensor and it is running ONLY in OFF PEAK is calculated correctly 73,16 / 27,67 = 2,644 CZK

So, as I said, only the point 4 shows me a bit different number that it should…

Any idea :-)?

Rounding and precision. “1.33” could be as low as 1.325; “0.42” could be as high as 0.4249…, and using those numbers gives about 3.12.

Well yes, that´s a good point. But I am really satisfied how it´s working now, it´s great :slight_smile:

Before I close this issue, the last thing - do you know, if it´s possible to have a Mushroom chip card on the dashboard showing either in green color text “Nízký tarif” (as for off peak) and to automatically switch to red color text “Vysoký tarif” (for peak)?

Now I have a simple chip which turns red when the peak is on, but it could look more nice as described above.
01

I´ve tried to make a sensor in the config code, but of course no success :smiley:

No idea if it works with Mushroom cards (which I’ve not used) but you could try this:

You might find examples on this forum somewhere, but it’s not something I’ve done.

Nice, will try and again thanks a lot for your help!