hello there!
i’ve set up template sensor for tracking which part of the day is - morning, day, evening, night.
all is perfect besides timeperiod 23.00-23.59 when sensor just don’t know what part to use. i’ve been trying to change timezone in HA - same result: between 23.00-23.59 sensor showing blank value. what might be problem here?
code:
{% if states.sensor.time.state > ‘08.01’ and states.sensor.time.state < ‘12.00’ %}
Hommik
{% elif states.sensor.time.state > ‘12.01’ and states.sensor.time.state < ‘19.00’ %}
Päev
{% elif states.sensor.time.state > ‘19.01’ and states.sensor.time.state < ‘23.59’ %}
Õhtu
{% elif states.sensor.time.state > ‘00.00’ and states.sensor.time.state < ‘02.00’ %}
Õhtu
{% elif states.sensor.time.state > ‘02.01’ and states.sensor.time.state < ‘08.00’ %}
Öö
{% endif %}