I have an Emporia Vue that has been flashed with esphome and is monitoring my panel. I am trying to monitor energy consumption on one of my circuit breakers and alert me if that device has not been on during the entire day. I can use the daily energy metric for it, which adds up the usage during the day. I tested this automation with a high trigger value and it worked:
alias: Well Pump Status
description: ""
trigger:
- platform: time
at: "21:00:00"
condition:
- type: is_energy
condition: device
device_id: 8ed94e26dc545038d65f266e96bf3f5e
entity_id: sensor.well_pump_daily_energy
domain: sensor
below: 100
action:
- service: notify.me
data:
message: Well Pump not Running {{ states('sensor.well_pump_daily_energy') }}
title: Well Pump not Running
mode: single
My problem is that this fires at 9PM. Ideally, I’d like this to fire in the morning so that I can go outside and investigate the problem. From what I see, the daily energy metric resets to zero at midnight, and I don’t have a way to look at the previous day’s value.
What is the best approach available here?