Have a dumb bloutooth light, on for 12 hours a day - want to add power / energy - only energy sensor created ? #2945
-
I have a few things setup for 24 hours / all day in the house and they are all working fine. I'm wondering what the time is actually for therefore - Is it just to calculate the daily energy used (power configured x 12 hours) In my use case, having an on and off time in here would mean I can track it properly - same as the schedule in the tuya app, and it can be added to my total monitored power. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
That's correct, when you only supply on_time no power sensor is created because it's not schedule based. For your use case I would suggest to create an input boolean helper (Using Toggle helper in HA helpers section). For example Now create a virtual power sensor (https://docs.powercalc.nl/sensor-types/virtual-power-manual/), select the input boolean as source entity, select Hope this helps. |
Beta Was this translation helpful? Give feedback.
-
I understand your answer now. It’s better as no config code needed. Plus it made me look at a few others things I did in config code that can be done better with the helper and automations. Thanks for that. |
Beta Was this translation helpful? Give feedback.
That's correct, when you only supply on_time no power sensor is created because it's not schedule based.
i.e. powercalc just adds correct amount for 12 hour on during the day to the energy sensor.
But it does not know "when" the energy is consumed, so it won't create a power meter.
For your use case I would suggest to create an input boolean helper (Using Toggle helper in HA helpers section). For example
input_boolean.staircase_light_on
.Create an automation which toggles this input boolean on 6PM and 6AM respectivily on and off.
Now create a virtual power sensor (https://docs.powercalc.nl/sensor-types/virtual-power-manual/), select the input boolean as source entity, select
fixed
strateg…