Hey everyone,
Hoping I can get some advise with an automation I would like to setup, I have a input_boolean I’m using to track my working hours. E.g when I walk into my office building an automation turns an at work input_boolean to ‘on’ that I use to track the hours.
I’ve been used history_stats with the input_boolean for my work day hours and work week. I also use it for when I’m working from home by just turning ‘on’ the input_boolean when my day starts and turning it off when I’m done / taking lunch.
I would really like to setup an automation to add a calendar event to a google calendar when the input_boolean goes from ‘on’ to ‘off’ state with an event with a start time of when the input_boolean went to on and an end time of the off event.
So I can use it to help record work hours over the long term.
adding a calendar event doesn’t seem to be too hard but I do far haven’t been able to find a way to get the last time the input_boolean was ‘on’
if anyone happens to know a way to get the last on time on an input_boolean that would really help me out.
thanks
Danny