Quantcast
Channel: Configuration - Home Assistant Community
Viewing all articles
Browse latest Browse all 95459

Sensor.elevation in automations

$
0
0

@maurizio53 wrote:

In my automations i am using this template to turn on lights when the sun elevation is at a certain degree:

value_template: '{{ state_attr("sun.sun", "elevation") < -6 }}'

Actually i am using the attributes of the sun device, but now i’d like to use the sun2 custom component which creates a sensor called sensor.elevation.

How to change that value template to use the state of this sensor ?
Thanks in advance… always learning with templates and always having headaches… :joy: :pray:

Posts: 3

Participants: 2

Read full topic


Viewing all articles
Browse latest Browse all 95459

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>