diff --git a/mlock-common.yaml b/mlock-common.yaml index 1179040..385266a 100644 --- a/mlock-common.yaml +++ b/mlock-common.yaml @@ -18,10 +18,16 @@ esphome: on_boot: - priority: 600 then: - - light.addressable_set: { id: status_led, red: 0%, green: 0%, blue: 50% } + - light.addressable_set: { id: status_led, red: 0%, green: 0%, blue: 100% } - priority: -100 then: - - light.addressable_set: { id: status_led, red: 0%, green: 0%, blue: 100% } + - if: + condition: + switch.is_on: mlock_${name_of_board}_switch + then: + - light.addressable_set: { id: status_led, red: 0%, green: 100%, blue: 0% } + else: + - light.addressable_set: { id: status_led, red: 100%, green: 0%, blue: 0% } # Enable logging logger: