Hi, i’m trying to put the value from an input number in duration of a motion sensor delay to turn off the lights…
This is the code from automations.yaml:
trigger:
- platform: state
entity_id: binary_sensor.mo2
to: 'off'
for:
minutes: "{{states('input_number.luci_auto_off_min') | float}}"
and this from configuration.yaml
input_number:
luci_auto_off_min:
name: Minutes for Auto switch off lights
min: 1
max: 30
step: 1
unit_of_measurement: step
But i’m getting this error:
Invalid config for [automation]: expected float for dictionary value @ data[‘for’][‘minutes’]. Got None.
What am I missing?
Thank you!!