CodeRabbitAI
This commit is contained in:
@@ -863,7 +863,7 @@ script:
|
|||||||
if (LIGHT_TRANSITION_TURN_ON > 0)
|
if (LIGHT_TRANSITION_TURN_ON > 0)
|
||||||
call.set_transition_length(LIGHT_TRANSITION_TURN_ON); // in ms
|
call.set_transition_length(LIGHT_TRANSITION_TURN_ON); // in ms
|
||||||
if (LIGHT_BRIGHTNESS_TURN_ON > 0 and LIGHT_BRIGHTNESS_TURN_ON <= 100)
|
if (LIGHT_BRIGHTNESS_TURN_ON > 0 and LIGHT_BRIGHTNESS_TURN_ON <= 100)
|
||||||
call.set_brightness(LIGHT_TRANSITION_TURN_ON / 100.0f);
|
call.set_brightness(LIGHT_BRIGHTNESS_TURN_ON / 100.0f);
|
||||||
call.perform();
|
call.perform();
|
||||||
} else if (!state and id(gb_lights_1)[light_index]->current_values.is_on()) {
|
} else if (!state and id(gb_lights_1)[light_index]->current_values.is_on()) {
|
||||||
ESP_LOGI("core_hw_leds", "Turn-off %s light for Relay %" PRIu8,
|
ESP_LOGI("core_hw_leds", "Turn-off %s light for Relay %" PRIu8,
|
||||||
@@ -887,7 +887,7 @@ script:
|
|||||||
if (LIGHT_TRANSITION_TURN_ON > 0)
|
if (LIGHT_TRANSITION_TURN_ON > 0)
|
||||||
call.set_transition_length(LIGHT_TRANSITION_TURN_ON); // in ms
|
call.set_transition_length(LIGHT_TRANSITION_TURN_ON); // in ms
|
||||||
if (LIGHT_BRIGHTNESS_TURN_ON > 0 and LIGHT_BRIGHTNESS_TURN_ON <= 100)
|
if (LIGHT_BRIGHTNESS_TURN_ON > 0 and LIGHT_BRIGHTNESS_TURN_ON <= 100)
|
||||||
call.set_brightness(LIGHT_TRANSITION_TURN_ON / 100.0f);
|
call.set_brightness(LIGHT_BRIGHTNESS_TURN_ON / 100.0f);
|
||||||
call.perform();
|
call.perform();
|
||||||
} else if (!state and id(gb_lights_2)[light_index]->current_values.is_on()) {
|
} else if (!state and id(gb_lights_2)[light_index]->current_values.is_on()) {
|
||||||
ESP_LOGI("core_hw_leds", "Turn-off %s light for Relay %" PRIu8,
|
ESP_LOGI("core_hw_leds", "Turn-off %s light for Relay %" PRIu8,
|
||||||
|
|||||||
@@ -12,7 +12,7 @@
|
|||||||
####################################################################################################
|
####################################################################################################
|
||||||
---
|
---
|
||||||
substitutions:
|
substitutions:
|
||||||
vibration_max_duration: 5s
|
vibration_max_duration: 2s
|
||||||
|
|
||||||
binary_sensor:
|
binary_sensor:
|
||||||
- id: bs_vibrating
|
- id: bs_vibrating
|
||||||
@@ -37,7 +37,6 @@ number:
|
|||||||
name: Vibrate duration
|
name: Vibrate duration
|
||||||
icon: mdi:vibrate
|
icon: mdi:vibrate
|
||||||
unit_of_measurement: ms
|
unit_of_measurement: ms
|
||||||
# mode: box
|
|
||||||
internal: false
|
internal: false
|
||||||
entity_category: config
|
entity_category: config
|
||||||
platform: template
|
platform: template
|
||||||
|
|||||||
Reference in New Issue
Block a user