[ { "id": "system_set_radio_volume", "automation": "- alias: system_set_radio_volume\n id: system_set_radio_volume\n initial_state: true\n triggers:\n - trigger: state\n entity_id: input_number.volume_radio\n to: null\n actions:\n - action: media_player.volume_set\n data:\n entity_id: '{% if is_state(\"input_select.chromecast_radio\", \"Kitchen\") %} media_player.yandex_k\n {% elif is_state(\"input_select.chromecast_radio\", \"Vova room\") %} media_player.yandex_v\n {% elif is_state(\"input_select.chromecast_radio\", \"Sasha room\") %} media_player.yandex_s\n {% elif is_state(\"input_select.chromecast_radio\", \"Master Bedroom\") %} media_player.yandex_mb\n {% elif is_state(\"input_select.chromecast_radio\", \"Hall big\") %} media_player.yandex_hb\n {% endif %}\n\n '\n volume_level: '{{ states(''input_number.volume_radio'') }}'", "config": [ { "name": "radio volume", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.volume_radio", "device_id": null } }, { "name": "chromecast radio", "room": "system", "type": "input_select", "id": { "entity_id": "input_select.chromecast_radio", "device_id": null } }, { "name": "yandex kitchen", "room": "kitchen", "type": "media_player", "id": { "entity_id": "media_player.yandex_k", "device_id": null } }, { "name": "yandex vova room", "room": "vova_room", "type": "media_player", "id": { "entity_id": "media_player.yandex_v", "device_id": null } }, { "name": "yandex sasha room", "room": "sasha_room", "type": "media_player", "id": { "entity_id": "media_player.yandex_s", "device_id": null } }, { "name": "yandex master bedroom", "room": "master_bedroom", "type": "media_player", "id": { "entity_id": "media_player.yandex_mb", "device_id": null } }, { "name": "yandex hall big", "room": "hall_big", "type": "media_player", "id": { "entity_id": "media_player.yandex_hb", "device_id": null } } ] }, { "id": "master_bedroom_breather_auto_co2", "automation": "- alias: master_bedroom_breather_auto_co2\n id: master_bedroom_breather_auto_co2\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /3\n conditions:\n - condition: state\n entity_id: switch.system_breather_auto_mb\n state: 'on'\n - condition: not\n conditions:\n - condition: state\n entity_id: switch.system_breather_manual_mb\n state: 'on'\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: binary_sensor.0x00158d000200ad58_contact\n state: 'off'\n - condition: numeric_state\n entity_id: sensor.esp32_node_mb_co2\n above: input_number.co2_high_limit\n - condition: state\n entity_id: binary_sensor.breather_mb\n state: 'off'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: numeric_state\n entity_id: sensor.0x00158d000222c746_temperature\n above: 20\n sequence:\n - action: fan.turn_on\n entity_id: fan.breather_mb\n - condition: numeric_state\n entity_id: sensor.esp32_node_mb_co2\n above: input_number.co2_high_limit\n - condition: state\n entity_id: switch.system_breather_auto_speed_mb\n state: 'on'\n - action: fan.set_percentage\n entity_id: fan.breather_mb\n data:\n percentage: '{{states(''sensor.breather_set_speed_mb'')|int(0) }}'\n - conditions:\n - condition: state\n entity_id: binary_sensor.0x00158d000200ad58_contact\n state: 'off'\n - condition: numeric_state\n entity_id: sensor.esp32_node_mb_co2\n above: input_number.co2_high_limit\n - condition: state\n entity_id: binary_sensor.breather_mb\n state: 'on'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: state\n entity_id: switch.system_breather_auto_speed_mb\n state: 'on'\n - condition: numeric_state\n entity_id: sensor.breather_set_speed_mb\n above: 0\n sequence:\n - action: fan.set_percentage\n entity_id: fan.breather_mb\n data:\n percentage: '{{states(''sensor.breather_set_speed_mb'')|int(0) }}'\n - conditions:\n - or:\n - and:\n - condition: state\n entity_id: binary_sensor.0x00158d000200ad58_contact\n state: 'off'\n - condition: numeric_state\n entity_id: sensor.esp32_node_mb_co2\n below: input_number.co2_low_limit\n - condition: state\n entity_id: binary_sensor.breather_mb\n state: 'on'\n - and:\n - or:\n - condition: numeric_state\n entity_id: sensor.0x00158d000222c746_temperature\n below: 20\n - condition: state\n entity_id: binary_sensor.0x00158d000200ad58_contact\n state: 'on'\n - condition: state\n entity_id: binary_sensor.breather_mb\n state: 'on'\n sequence:\n - action: fan.turn_off\n entity_id: fan.breather_mb", "config": [ { "name": "system breather auto mb", "room": "master_bedroom", "type": "switch", "id": { "entity_id": "switch.system_breather_auto_mb", "device_id": null } }, { "name": "system breather manual mb", "room": "master_bedroom", "type": "switch", "id": { "entity_id": "switch.system_breather_manual_mb", "device_id": null } }, { "name": "contact sensor 1", "room": "master_bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d000200ad58_contact", "device_id": null } }, { "name": "co2 sensor mb", "room": "master_bedroom", "type": "sensor", "id": { "entity_id": "sensor.esp32_node_mb_co2", "device_id": null } }, { "name": "breather mb binary", "room": "master_bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.breather_mb", "device_id": null } }, { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "temperature sensor 1", "room": "master_bedroom", "type": "sensor", "id": { "entity_id": "sensor.0x00158d000222c746_temperature", "device_id": null } }, { "name": "breather mb fan", "room": "master_bedroom", "type": "fan", "id": { "entity_id": "fan.breather_mb", "device_id": null } }, { "name": "co2 high limit", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.co2_high_limit", "device_id": null } }, { "name": "breather set speed mb", "room": "master_bedroom", "type": "sensor", "id": { "entity_id": "sensor.breather_set_speed_mb", "device_id": null } }, { "name": "co2 low limit", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.co2_low_limit", "device_id": null } }, { "name": "system breather auto speed mb", "room": "master_bedroom", "type": "switch", "id": { "entity_id": "switch.system_breather_auto_speed_mb", "device_id": null } }, { "name": "system breather auto s", "room": "sasha_room", "type": "switch", "id": { "entity_id": "switch.system_breather_auto_s", "device_id": null } } ] }, { "id": "master_bedroom_breather_auto_timer", "automation": "- alias: master_bedroom_breather_auto_timer\n id: master_bedroom_breather_auto_timer\n initial_state: true\n triggers:\n - trigger: event\n event_type: yandex_intent\n event_data:\n text: Выключи вентиляцию\n id: to_off_alice\n - trigger: event\n event_type: yandex_intent\n event_data:\n text: Включи вентиляцию\n id: to_on_alice\n - trigger: time\n at: 09:00:00\n id: time_trigger_day\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: to_off_alice\n sequence:\n - condition: template\n value_template: '{{ trigger.event.data.entity_id == ''media_player.yandex_mb''\n }}'\n - if:\n - condition: state\n entity_id: binary_sensor.breather_mb\n state: 'on'\n then:\n - action: fan.turn_off\n entity_id: fan.breather_mb\n - action: switch.turn_on\n entity_id: switch.system_breather_auto_mb\n - conditions:\n - condition: trigger\n id: to_on_alice\n sequence:\n - condition: template\n value_template: '{{ trigger.event.data.entity_id == ''media_player.yandex_mb''\n }}'\n - if:\n - condition: state\n entity_id: binary_sensor.breather_mb\n state: 'off'\n then:\n - action: fan.turn_on\n entity_id: fan.breather_mb\n - action: switch.turn_on\n entity_id: switch.system_breather_manual_mb\n - conditions:\n - condition: trigger\n id: time_trigger_night\n sequence:\n - action: switch.turn_on\n entity_id: switch.system_breather_manual_mb\n - action: fan.set_percentage\n entity_id: fan.breather_mb\n data:\n percentage: 50\n - conditions:\n - condition: trigger\n id: time_trigger_day\n sequence:\n - action: fan.turn_off\n entity_id: fan.breather_mb", "config": [ { "name": "yandex master bedroom", "room": "master_bedroom", "type": "media_player", "id": { "entity_id": "media_player.yandex_mb", "device_id": null } }, { "name": "system breather auto mb", "room": "master_bedroom", "type": "switch", "id": { "entity_id": "switch.system_breather_auto_mb", "device_id": null } }, { "name": "system breather manual mb", "room": "master_bedroom", "type": "switch", "id": { "entity_id": "switch.system_breather_manual_mb", "device_id": null } }, { "name": "breather mb binary", "room": "master_bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.breather_mb", "device_id": null } }, { "name": "breather mb fan", "room": "master_bedroom", "type": "fan", "id": { "entity_id": "fan.breather_mb", "device_id": null } } ] }, { "id": "master_bedroom_breather_switches_interlock", "automation": "- alias: master_bedroom_breather_switches_interlock\n id: master_bedroom_breather_switches_interlock\n triggers:\n - trigger: state\n entity_id:\n - switch.system_breather_auto_mb\n - switch.system_breather_manual_mb\n conditions:\n - condition: template\n value_template: '{{ trigger.to_state.state == ''on'' }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: homeassistant.turn_off\n target:\n entity_id: '{% if trigger.from_state.entity_id == ''switch.system_breather_auto_mb''\n %} {{ ''switch.system_breather_manual_mb'' }} {% else %} {{ ''switch.system_breather_auto_mb''\n }} {% endif %}'", "config": [ { "name": "system breather auto mb", "room": "master_bedroom", "type": "switch", "id": { "entity_id": "switch.system_breather_auto_mb", "device_id": null } }, { "name": "system breather manual mb", "room": "master_bedroom", "type": "switch", "id": { "entity_id": "switch.system_breather_manual_mb", "device_id": null } } ] }, { "id": "master_bedroom_breather_switches_default", "automation": "- alias: master_bedroom_breather_switches_default\n id: master_bedroom_breather_switches_default\n triggers:\n - trigger: template\n value_template: '{{ is_state(''switch.system_breather_auto_mb'',''off'') and is_state(''switch.system_breather_manual_mb'',''off'')\n }}'\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: switch.turn_on\n entity_id: switch.system_breather_auto_mb", "config": [ { "name": "system breather auto mb", "room": "master_bedroom", "type": "switch", "id": { "entity_id": "switch.system_breather_auto_mb", "device_id": null } }, { "name": "system breather manual mb", "room": "master_bedroom", "type": "switch", "id": { "entity_id": "switch.system_breather_manual_mb", "device_id": null } } ] }, { "id": "system_calendar_events_to_list", "automation": "- alias: system_calendar_events_to_list\n id: system_calendar_events_to_list\n triggers:\n - event: start\n platform: homeassistant\n - trigger: time\n at: 00:00:00\n actions:\n - action: input_select.set_options\n target:\n entity_id: input_select.calendar_events_list\n data:\n options: Нет событий\n - event: calendar_event_list_updated\n - action: script.calendar_events\n data:\n calendar: calendar.dima_tsymbal_gmail_com\n make_choice: true\n choice_word: день рождения\n response_variable: events\n - if:\n - condition: template\n value_template: '{{ events | length > 0 }}'\n then:\n - action: input_select.set_options\n target:\n entity_id: input_select.calendar_events_list\n data:\n options: '{{ (state_attr(''input_select.calendar_events_list'', ''options'')\n | join(''|'') + ''|'' + events.values() | list | join(''|'')).split(''|'')\n | select(''ne'', '''') | unique | list }}'\n - event: calendar_event_list_updated\n - action: script.calendar_events\n data:\n calendar: calendar.prazdniki_rossii_polnyi\n response_variable: events\n - if:\n - condition: template\n value_template: '{{ events | length > 0 }}'\n then:\n - action: input_select.set_options\n target:\n entity_id: input_select.calendar_events_list\n data:\n options: '{{ (state_attr(''input_select.calendar_events_list'', ''options'')\n | join(''|'') + ''|'' + events.values() | list | join(''|'')).split(''|'')\n | select(''ne'', '''') | unique | list }}'\n - event: calendar_event_list_updated", "config": [ { "name": "calendar events list", "room": "system", "type": "input_select", "id": { "entity_id": "input_select.calendar_events_list", "device_id": null } }, { "name": "calendar dima", "room": "system", "type": "calendar", "id": { "entity_id": "calendar.dima_tsymbal_gmail_com", "device_id": null } }, { "name": "calendar prazdniki rossii", "room": "system", "type": "calendar", "id": { "entity_id": "calendar.prazdniki_rossii_polnyi", "device_id": null } } ] }, { "id": "system_snapshot_window", "automation": "- alias: system_snapshot_window\n id: system_snapshot_window\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.g5_bullet_window_motion\n from: 'off'\n to: 'on'\n conditions:\n - condition: template\n value_template: '{{(as_timestamp(now())-as_timestamp(state_attr(''automation.system_snapshot_window'',\n ''last_triggered''),0)|int(0)) > 10 }}'\n actions:\n - action: notify.telegram_cam\n data:\n message: Window\n data:\n photo:\n - url: http://localhost:1984/api/frame.jpeg?src=g5_window\n caption: 📷 Window {{states('sensor.time')}} {{states('sensor.date')}}", "config": [ { "name": "window motion", "room": "outside", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.g5_bullet_window_motion", "device_id": null } }, { "name": "time", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.time", "device_id": null } }, { "name": "date", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.date", "device_id": null } } ] }, { "id": "system_snapshot_yard", "automation": "- alias: system_snapshot_yard\n id: system_snapshot_yard\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.g5_bullet_yard_motion\n from: 'off'\n to: 'on'\n conditions:\n - condition: template\n value_template: '{{(as_timestamp(now())-as_timestamp(state_attr(''automation.system_snapshot_yard'',\n ''last_triggered''),0)|int(0)) > 10 }}'\n actions:\n - action: notify.telegram_cam\n data:\n message: Yard\n data:\n photo:\n - url: http://localhost:1984/api/frame.jpeg?src=g5_yard\n caption: 📷 Yard {{states('sensor.time')}} {{states('sensor.date')}}", "config": [ { "name": "yard motion", "room": "outside", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.g5_bullet_yard_motion", "device_id": null } }, { "name": "time", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.time", "device_id": null } }, { "name": "date", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.date", "device_id": null } } ] }, { "id": "system_snapshot_dixy", "automation": "- alias: system_snapshot_dixy\n id: system_snapshot_dixy\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.g5_turret_dixy_motion\n from: 'off'\n to: 'on'\n conditions:\n - condition: template\n value_template: '{{(as_timestamp(now())-as_timestamp(state_attr(''automation.system_snapshot_dixy'',\n ''last_triggered''),0)|int(0)) > 10 }}'\n actions:\n - action: notify.telegram_cam\n data:\n message: Dixy\n data:\n photo:\n - url: http://localhost:1984/api/frame.jpeg?src=g5_dixy\n caption: 📷 Dixy {{states('sensor.time')}} {{states('sensor.date')}}", "config": [ { "name": "dixy motion", "room": "outside", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.g5_turret_dixy_motion", "device_id": null } }, { "name": "time", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.time", "device_id": null } }, { "name": "date", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.date", "device_id": null } } ] }, { "id": "system_snapshot_street", "automation": "- alias: system_snapshot_street\n id: system_snapshot_street\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.g5_turret_street_motion\n from: 'off'\n to: 'on'\n conditions:\n - condition: template\n value_template: '{{(as_timestamp(now())-as_timestamp(state_attr(''automation.system_snapshot_street'',\n ''last_triggered''),0)|int(0)) > 10 }}'\n actions:\n - action: notify.telegram_cam\n data:\n message: Street\n data:\n photo:\n - url: http://localhost:1984/api/frame.jpeg?src=g5_street\n caption: 📷 Street {{states('sensor.time')}} {{states('sensor.date')}}", "config": [ { "name": "street motion", "room": "outside", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.g5_turret_street_motion", "device_id": null } }, { "name": "time", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.time", "device_id": null } }, { "name": "date", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.date", "device_id": null } } ] }, { "id": "system_snaphot_outside", "automation": "- alias: system_snaphot_outside\n id: system_snaphot_outside\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.g4_doorbell_motion\n from: 'off'\n to: 'on'\n conditions:\n - condition: template\n value_template: '{{(as_timestamp(now())-as_timestamp(state_attr(''automation.system_snaphot_outside'',\n ''last_triggered''),0)|int(0)) > 15 }}'\n actions:\n - action: notify.telegram_cam\n data:\n message: Doorbell\n data:\n photo:\n - url: http://localhost:1984/api/frame.jpeg?src=g4_doorbell\n caption: 📷 Doorbell {{states('sensor.time')}} {{states('sensor.date')}}", "config": [ { "name": "doorbell motion", "room": "outside", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.g4_doorbell_motion", "device_id": null } }, { "name": "time", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.time", "device_id": null } }, { "name": "date", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.date", "device_id": null } } ] }, { "id": "hall_big_domofon_incoming_call", "automation": "- alias: hall_big_domofon_incoming_call\n id: hall_big_domofon_incoming_call\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.esp32_domofon_incomingcall\n to: 'on'\n from: 'off'\n actions:\n - parallel:\n - action: switch.turn_on\n entity_id: switch.kiosk_screen\n - parallel:\n - action: notify.telegram\n data:\n title: '{{states(''sensor.time'')}} {{states(''sensor.date'')}}'\n message: '{{states(''sensor.time'')}} {{states(''sensor.date'')}}'\n data:\n photo:\n - url: http://localhost:1984/api/frame.jpeg?src=g5_window\n caption: 📣 Звонок в домофон {{states('sensor.time')}} {{states('sensor.date')}}\n - action: notify.telegram_cam\n data:\n title: '{{states(''sensor.time'')}} {{states(''sensor.date'')}}'\n message: '{{states(''sensor.time'')}} {{states(''sensor.date'')}}'\n data:\n photo:\n - url: http://localhost:1984/api/frame.jpeg?src=g5_window\n caption: 📣 Звонок в домофон {{states('sensor.time')}} {{states('sensor.date')}}\n - if:\n - condition: state\n entity_id: person.sasha\n state: home\n then:\n - action: notify.hass_synochat\n data:\n message: Внимание Зконок в домофон\n data:\n file_url: http://localhost:1984/api/frame.jpeg?src=g5_window\n - or:\n - condition: state\n entity_id: switch.system_silent_mode\n state: 'on'\n - condition: state\n entity_id: switch.esp32_domofon_mute\n state: 'on'\n - action: light.turn_on\n data:\n entity_id: light.esp32_node_k_led\n effect: Green_Alarm\n brightness: 255\n - delay: 00:00:20\n - action: light.turn_off\n entity_id: light.esp32_node_k_led", "config": [ { "name": "person sasha", "room": "system", "type": "person", "id": { "entity_id": "person.sasha", "device_id": null } }, { "name": "system silent mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_silent_mode", "device_id": null } }, { "name": "kiosk screen", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.kiosk_screen", "device_id": null } }, { "name": "time", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.time", "device_id": null } }, { "name": "date", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.date", "device_id": null } }, { "name": "domofon incoming call", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_domofon_incomingcall", "device_id": null } }, { "name": "esp32 node k led", "room": "kitchen", "type": "light", "id": { "entity_id": "light.esp32_node_k_led", "device_id": null } }, { "name": "esp32 domofon mute", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.esp32_domofon_mute", "device_id": null } } ] }, { "id": "hall_big_domofon_open_from_iphone", "automation": "- alias: hall_big_domofon_open_from_iphone\n id: hall_big_domofon_open_from_iphone\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: mobile_app_notification_action\n event_data:\n service: Domofon_Open\n actions:\n - action: switch.turn_on\n entity_id: switch.esp32_domofon_open\n - action: notify.telegram\n data:\n message: 🔘 Домофон открыт с телефона", "config": [ { "name": "esp32 domofon open", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.esp32_domofon_open", "device_id": null } } ] }, { "id": "hall_big_domofon_auto_message", "automation": "- alias: hall_big_domofon_auto_message\n id: hall_big_domofon_auto_message\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.esp32_domofon_auto_opening\n from: 'off'\n to: 'on'\n actions:\n - action: notify.telegram\n data:\n message: 📞 Домофон открыт автоматически", "config": [ { "name": "esp32 domofon auto opening", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_domofon_auto_opening", "device_id": null } } ] }, { "id": "hall_big_domofon_auto_opening", "automation": "- alias: hall_big_domofon_auto_opening\n id: hall_big_domofon_auto_opening\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: switch.esp32_domofon_auto_open, switch.esp32_domofon_auto_open_once\n to: null\n conditions:\n - condition: template\n value_template: \"{% set ignore = ['unknown', 'unavailable', 'none'] %} {{ trigger.from_state.state\\\n \\ not in ignore and\\n trigger.to_state.state not in ignore and\\n trigger.to_state.state\\\n \\ = trigger.from_state.state\\n}}\"\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: notify.telegram\n data:\n message: '{% if is_state(''switch.esp32_domofon_auto_open'',''on'') and ''once''\n not in trigger.to_state.entity_id %}{{''\\U0001f513''}} Домофон: Автооткрытие\n включено {% elif is_state(''switch.esp32_domofon_auto_open_once'',''on'')\n and ''once'' in trigger.to_state.entity_id %}{{''\\U0001f513''}} Домофон: Разовое\n автооткрытие включено {% else %}{{''\\U0001f512''}} Домофон: Автооткрытие выключено{%\n endif %}\n\n '", "config": [ { "name": "esp32 domofon auto open", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.esp32_domofon_auto_open", "device_id": null } }, { "name": "esp32 domofon auto open once", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.esp32_domofon_auto_open_once", "device_id": null } } ] }, { "id": "hall_big_domofon_timer_on", "automation": "- alias: hall_big_domofon_timer_on\n id: hall_big_domofon_timer_on\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: template\n value_template: '{{is_state(''switch.esp32_domofon_auto_open'',''on'') or is_state(''switch.esp32_domofon_auto_open_once'',''on'')\n }}'\n actions:\n - action: timer.cancel\n entity_id: timer.domofon\n - action: timer.start\n entity_id: timer.domofon", "config": [ { "name": "esp32 domofon auto open", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.esp32_domofon_auto_open", "device_id": null } }, { "name": "esp32 domofon auto open once", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.esp32_domofon_auto_open_once", "device_id": null } }, { "name": "timer domofon", "room": "hall_big", "type": "timer", "id": { "entity_id": "timer.domofon", "device_id": null } } ] }, { "id": "hall_big_domofon_auto_open_turn_off", "automation": "- alias: hall_big_domofon_auto_open_turn_off\n id: hall_big_domofon_auto_open_turn_off\n initial_state: true\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.domofon\n actions:\n - action: switch.turn_off\n entity_id: switch.esp32_domofon_auto_open, switch.esp32_domofon_auto_open_once,\n switch.esp32_domofon_mute", "config": [ { "name": "esp32 domofon mute", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.esp32_domofon_mute", "device_id": null } }, { "name": "esp32 domofon auto open", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.esp32_domofon_auto_open", "device_id": null } }, { "name": "esp32 domofon auto open once", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.esp32_domofon_auto_open_once", "device_id": null } }, { "name": "timer domofon", "room": "hall_big", "type": "timer", "id": { "entity_id": "timer.domofon", "device_id": null } } ] }, { "id": "hall_big_domofon_timer_off", "automation": "- alias: hall_big_domofon_timer_off\n id: hall_big_domofon_timer_off\n initial_state: true\n triggers:\n - trigger: template\n value_template: '{{not is_state(''switch.esp32_domofon_auto_open'',''on'') and\n not is_state(''switch.esp32_domofon_auto_open_once'',''on'') }}'\n actions:\n - action: timer.cancel\n entity_id: timer.domofon", "config": [ { "name": "esp32 domofon auto open", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.esp32_domofon_auto_open", "device_id": null } }, { "name": "esp32 domofon auto open once", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.esp32_domofon_auto_open_once", "device_id": null } }, { "name": "timer domofon", "room": "hall_big", "type": "timer", "id": { "entity_id": "timer.domofon", "device_id": null } } ] }, { "id": "hall_big_domofon_button", "automation": "- alias: hall_big_domofon_button\n id: hall_big_domofon_button\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.esp32_domofon_button\n from: 'off'\n to: 'on'\n actions:\n - action: switch.turn_on\n entity_id: switch.kiosk_screen\n - action: telegram_bot.send_photo\n data:\n url: http://localhost:1984/api/frame.jpeg?src=g5_entrance\n caption: 🔘 Домофон открыт вручную\n target: secret tel_chat_id\n timeout: 180", "config": [ { "name": "kiosk screen", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.kiosk_screen", "device_id": null } }, { "name": "esp32 domofon button", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_domofon_button", "device_id": null } }, { "name": "Tel Chat ID Secret", "room": null, "type": "secret", "id": { "entity_id": "secret tel_chat_id", "device_id": null } } ] }, { "id": "hall_big_doorbell", "automation": "- alias: hall_big_doorbell\n id: hall_big_doorbell\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id:\n - binary_sensor.g4_doorbell_doorbell\n from: 'off'\n to: 'on'\n conditions:\n - condition: template\n value_template: '{{(as_timestamp(now())-as_timestamp(state_attr(''automation.hall_big_doorbell'',\n ''last_triggered''),0)|int(0)) > 10 }}'\n actions:\n - action: switch.turn_on\n entity_id: switch.kiosk_screen\n - parallel:\n - action: notify.telegram\n data:\n title: Doorbell photo\n message: 🔔 Внимание! Кто-то звонит в дверь!\n data:\n photo:\n - url: http://localhost:1984/api/frame.jpeg?src=g4_doorbell\n caption: 🔔 Внимание! Кто-то звонит в дверь! {{states('sensor.time')}}\n {{states('sensor.date')}}\n - if:\n - condition: state\n entity_id: person.sasha\n state: home\n then:\n - action: notify.hass_synochat\n data:\n message: Внимание! Кто-то звонит в дверь!\n data:\n file_url: http://localhost:1984/api/frame.jpeg?src=g4_doorbell\n - parallel:\n - action: light.turn_on\n data:\n entity_id: light.light_bar_s_ambilight\n effect: Police\n brightness: 255\n - action: light.turn_on\n data:\n entity_id: light.esp32_node_k_led\n effect: Green_Alarm\n brightness: 255\n - delay: 00:00:25\n - wait_for_trigger:\n - trigger: state\n entity_id:\n - binary_sensor.582d344031f7_contact\n - binary_sensor.0x00158d0001e5d6be_contact\n from: 'on'\n to: 'off'\n timeout:\n seconds: 30\n continue_on_timeout: true\n - action: light.turn_off\n entity_id: light.esp32_node_k_led, light.light_bar_s_ambilight", "config": [ { "name": "person sasha", "room": "system", "type": "person", "id": { "entity_id": "person.sasha", "device_id": null } }, { "name": "kiosk screen", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.kiosk_screen", "device_id": null } }, { "name": "time", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.time", "device_id": null } }, { "name": "date", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.date", "device_id": null } }, { "name": "esp32 node k led", "room": "kitchen", "type": "light", "id": { "entity_id": "light.esp32_node_k_led", "device_id": null } }, { "name": "g4 doorbell doorbell", "room": "outside", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.g4_doorbell_doorbell", "device_id": null } }, { "name": "light bar s ambilight", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.light_bar_s_ambilight", "device_id": null } }, { "name": "main door contact", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001e5d6be_contact", "device_id": null } }, { "name": "Contact Sensor 582d344031f7", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.582d344031f7_contact", "device_id": null } }, { "name": "Light Bar S", "room": "Sasha Room", "type": "light", "id": { "entity_id": "light.light_bar_s", "device_id": null } } ] }, { "id": "emergency_backup", "automation": "- alias: emergency_backup\n id: emergency_backup\n initial_state: true\n mode: queued\n max: 10\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.hass_backup_ping\n to: null\n - trigger: state\n entity_id: binary_sensor.hass_backup_state\n to: null\n actions:\n - action: notify.telegram\n data:\n message: '{% if is_state(''binary_sensor.hass_backup_ping'',''on'') and is_state(''binary_sensor.hass_backup_state'',''on'')\n %}{{''\\U00002705''}} {% elif is_state(''binary_sensor.hass_backup_ping'',''on'')\n or is_state(''binary_sensor.hass_backup_state'',''on'') %}{{''\\U000026a0''}}\n {% else %}{{''\\U0000274C''}} {% endif %} Backup: HA - {{states(''binary_sensor.hass_backup_state'')|upper}},\n host - {{states(''binary_sensor.hass_backup_ping'')|upper}}!'", "config": [ { "name": "hass backup ping", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.hass_backup_ping", "device_id": null } }, { "name": "hass backup state", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.hass_backup_state", "device_id": null } } ] }, { "id": "hall_big_fridge_not_closed_5m", "automation": "- alias: hall_big_fridge_not_closed_5m\n id: hall_big_fridge_not_closed_5m\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x00158d000253722b_contact\n from: 'off'\n to: 'on'\n for:\n minutes: 5\n actions:\n - action: notify.telegram\n data:\n message: 👁 Внимание! Холодильник не закрыт!", "config": [ { "name": "fridge contact", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d000253722b_contact", "device_id": null } } ] }, { "id": "hall_big_freezer_not_closed_5m", "automation": "- alias: hall_big_freezer_not_closed_5m\n id: hall_big_freezer_not_closed_5m\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x00158d000252acba_contact\n from: 'off'\n to: 'on'\n for:\n minutes: 5\n actions:\n - action: notify.telegram\n data:\n message: 👁 Внимание! Морозильник не закрыт!", "config": [ { "name": "freezer contact", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d000252acba_contact", "device_id": null } } ] }, { "id": "hall_big_fridge_temp_alarm", "automation": "- alias: hall_big_fridge_temp_alarm\n id: hall_big_fridge_temp_alarm\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /15\n conditions:\n - condition: numeric_state\n entity_id: sensor.ble_temperature_ble_fridge\n above: 15\n actions:\n - action: notify.telegram\n data:\n message: 🌡 Внимание! Температура в холодильнике {{states('sensor.ble_temperature_ble_fridge')|int(0)}}°C!", "config": [ { "name": "ble fridge temperature", "room": "hall_big", "type": "sensor", "id": { "entity_id": "sensor.ble_temperature_ble_fridge", "device_id": null } } ] }, { "id": "hall_big_freezer_temp_alarm", "automation": "- alias: hall_big_freezer_temp_alarm\n id: hall_big_freezer_temp_alarm\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /15\n conditions:\n - condition: numeric_state\n entity_id: sensor.ble_temperature_ble_freezer\n above: 0\n actions:\n - action: notify.telegram\n data:\n message: 🌡 Внимание! Температура в морозилке {{states('sensor.ble_temperature_ble_freezer')|int(0)}}°C!", "config": [ { "name": "ble freezer temperature", "room": "hall_big", "type": "sensor", "id": { "entity_id": "sensor.ble_temperature_ble_freezer", "device_id": null } } ] }, { "id": "hall_big_fridge_sensors_outage", "automation": "- alias: hall_big_fridge_sensors_outage\n id: hall_big_fridge_sensors_outage\n mode: single\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /30\n conditions:\n - condition: template\n value_template: '{{ as_timestamp(now())- as_timestamp(states.sensor.ble_temperature_ble_fridge.last_updated)\n > 2*60*60 or as_timestamp(now())- as_timestamp(states.sensor.ble_temperature_ble_freezer.last_updated)\n > 2*60*60 or as_timestamp(now())- as_timestamp(states.sensor[''0x00158d000253722b_zigbee''].last_updated)\n > 2*60*60 or as_timestamp(now())- as_timestamp(states.sensor[''0x00158d000252acba_zigbee''].last_updated)\n > 2*60*60 }}\n\n '\n actions:\n - action: notify.telegram\n data:\n message: '{{''\\U0000274c''}} Внимание! Нет данных от датчика {%- if as_timestamp(now())-\n as_timestamp(states.sensor.ble_temperature_ble_fridge.last_updated) > 2*60*60\n %} температуры холодильника {%- elif as_timestamp(now())- as_timestamp(states.sensor.ble_temperature_ble_freezer.last_updated)\n > 2*60*60 %} температуры морозилки {%- elif as_timestamp(now())- as_timestamp(states.sensor[''0x00158d000253722b_zigbee''].last_updated)\n > 2*60*60 %} двери холодильника {%- elif as_timestamp(now())- as_timestamp(states.sensor[''0x00158d000252acba_zigbee''].last_updated)\n > 2*60*60 %} двери морозилки {%-else%} ххх {%endif%}!'", "config": [ { "name": "ble fridge temperature", "room": "hall_big", "type": "sensor", "id": { "entity_id": "sensor.ble_temperature_ble_fridge", "device_id": null } }, { "name": "ble freezer temperature", "room": "hall_big", "type": "sensor", "id": { "entity_id": "sensor.ble_temperature_ble_freezer", "device_id": null } } ] }, { "id": "kitchen_briefing", "automation": "- alias: kitchen_briefing\n id: kitchen_briefing\n initial_state: true\n triggers:\n - trigger: time\n at: 07:05:00\n - trigger: homeassistant\n event: start\n conditions:\n - condition: time\n after: 07:00:00\n before: 07:15:00\n - condition: template\n value_template: '{{(as_timestamp(now())|int(0) - as_timestamp(state_attr(''automation.kitchen_briefing'',\n ''last_triggered''),0)|int(0)) > 15*60 }}'\n - condition: state\n entity_id: binary_sensor.workday_sensor\n state: 'on'\n actions:\n - action: input_number.set_value\n data:\n entity_id: input_number.main_volume\n value: '0.4'\n - wait_for_trigger:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0002b4729d_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0002b48381_motion\n timeout:\n minutes: 15\n continue_on_timeout: false\n - action: script.briefing_tts\n data:\n entity_id: media_player.yandex_k\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'", "config": [ { "name": "yandex kitchen", "room": "kitchen", "type": "media_player", "id": { "entity_id": "media_player.yandex_k", "device_id": null } }, { "name": "workday sensor", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.workday_sensor", "device_id": null } }, { "name": "main volume", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.main_volume", "device_id": null } }, { "name": "motion sensor kitchen 1", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b4729d_motion", "device_id": null } }, { "name": "motion sensor kitchen 2", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b48381_motion", "device_id": null } } ] }, { "id": "kitchen_smoke_detected", "automation": "- alias: kitchen_smoke_detected\n id: kitchen_smoke_detected\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x00158d0002c92f31_smoke\n to: 'on'\n actions:\n - action: notify.telegram\n data:\n message: ⛔ Внимание! Сработал датчик дыма!", "config": [ { "name": "smoke sensor", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002c92f31_smoke", "device_id": null } } ] }, { "id": "kitchen_gas_detected", "automation": "- alias: kitchen_gas_detected\n id: kitchen_gas_detected\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x00158d00024bcf85_gas\n to: 'on'\n actions:\n - action: notify.telegram\n data:\n message: ⛔ Внимание! Сработал датчик газа!", "config": [ { "name": "gas sensor", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d00024bcf85_gas", "device_id": null } } ] }, { "id": "kitchen_kettle_count", "automation": "- alias: kitchen_kettle_count\n id: kitchen_kettle_count\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.kettle_boil_k\n from: 'off'\n to: 'on'\n actions:\n - action: counter.increment\n entity_id: counter.kettle_k", "config": [ { "name": "kettle boil", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.kettle_boil_k", "device_id": null } }, { "name": "kettle counter", "room": "kitchen", "type": "counter", "id": { "entity_id": "counter.kettle_k", "device_id": null } } ] }, { "id": "kitchen_oven_notify", "automation": "- alias: kitchen_oven_notify\n id: kitchen_oven_notify\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /30\n conditions:\n - condition: numeric_state\n entity_id: sensor.esp8266_oven_temp_k_temperature\n above: 100\n - condition: state\n entity_id: binary_sensor.motion_k\n state: 'off'\n for: 00:30:00\n actions:\n - action: notify.telegram\n data:\n message: 🌡 Внимание! Духовка включена ({{states('sensor.esp8266_oven_temp_k_temperature')|int(0)}}°C)!", "config": [ { "name": "oven temperature", "room": "kitchen", "type": "sensor", "id": { "entity_id": "sensor.esp8266_oven_temp_k_temperature", "device_id": null } }, { "name": "motion kitchen", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.motion_k", "device_id": null } } ] }, { "id": "kitchen_tv_plug_off", "automation": "- alias: kitchen_tv_plug_off\n id: kitchen_tv_plug_off\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.presence_k\n to: 'off'\n for:\n minutes: 30\n conditions:\n - condition: time\n after: 00:00:00\n before: 06:00:00\n - condition: state\n entity_id: switch.0x00158d0001e85086_plug\n state: 'on'\n actions:\n - action: switch.turn_off\n entity_id: switch.0x00158d0001e85086_plug", "config": [ { "name": "presence kitchen", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.presence_k", "device_id": null } }, { "name": "tv plug", "room": "kitchen", "type": "switch", "id": { "entity_id": "switch.0x00158d0001e85086_plug", "device_id": null } } ] }, { "id": "kitchen_tv_plug_on", "automation": "- alias: kitchen_tv_plug_on\n id: kitchen_tv_plug_on\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.presence_k\n to: 'on'\n from: 'off'\n conditions:\n - condition: time\n after: 06:00:00\n - condition: time\n before: 08:00:00\n - condition: state\n entity_id: switch.0x00158d0001e85086_plug\n state: 'off'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n actions:\n - action: switch.turn_on\n entity_id: switch.0x00158d0001e85086_plug", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "presence kitchen", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.presence_k", "device_id": null } }, { "name": "tv plug", "room": "kitchen", "type": "switch", "id": { "entity_id": "switch.0x00158d0001e85086_plug", "device_id": null } } ] }, { "id": "kitchen_oven_notify_target_temp", "automation": "- alias: kitchen_oven_notify_target_temp\n id: kitchen_oven_notify_target_temp\n initial_state: true\n triggers:\n - trigger: event\n event_type: automation_reloaded\n - trigger: state\n entity_id: binary_sensor.esp8266_oven_temp_k_oven_state\n to: 'on'\n conditions:\n - condition: template\n value_template: '{{ states(''sensor.oven_target_temperature'')|int(0) > 100 }}'\n - condition: template\n value_template: '{{as_timestamp(now()) - as_timestamp(state_attr(''automation.kitchen_oven_notify_target_temp'',\n ''last_triggered''),0) > 60*60 }}'\n - condition: state\n entity_id: binary_sensor.esp8266_oven_temp_k_oven_state\n state: 'on'\n actions:\n - wait_for_trigger:\n - trigger: template\n value_template: '{{ states(''sensor.esp8266_oven_temp_k_temperature'')|int(0)\n >= states(''sensor.oven_target_temperature'')|int(0) }}'\n timeout:\n minutes: 60\n continue_on_timeout: false\n - action: notify.telegram\n data:\n message: 🌡 Духовка нагрелась до {{states('sensor.esp8266_oven_temp_k_temperature')|int(0)}}°C!\n - if:\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'on'\n - condition: state\n entity_id: switch.system_dark_mode\n state: 'off'\n then:\n - action: media_player.volume_set\n data:\n entity_id: media_player.yandex_k\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id: media_player.yandex_k\n media_content_id: Температура в духовке ({{states('sensor.esp8266_oven_temp_k_temperature')|int(0)}}°C", "config": [ { "name": "yandex kitchen", "room": "kitchen", "type": "media_player", "id": { "entity_id": "media_player.yandex_k", "device_id": null } }, { "name": "system dark mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_dark_mode", "device_id": null } }, { "name": "main volume", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.main_volume", "device_id": null } }, { "name": "oven temperature", "room": "kitchen", "type": "sensor", "id": { "entity_id": "sensor.esp8266_oven_temp_k_temperature", "device_id": null } }, { "name": "oven state", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp8266_oven_temp_k_oven_state", "device_id": null } }, { "name": "oven target temperature", "room": "kitchen", "type": "sensor", "id": { "entity_id": "sensor.oven_target_temperature", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "alice mode", "room": "system", "type": "input_select", "id": { "entity_id": "input_select.alice_mode", "device_id": null } } ] }, { "id": "kitchen_oven_notify_to_alice", "automation": "- alias: kitchen_oven_notify_to_alice\n id: kitchen_oven_notify_to_alice\n initial_state: true\n triggers:\n - trigger: event\n event_type: yandex_intent\n event_data:\n text: Какая температура в духовке\n actions:\n - action: media_player.volume_set\n data:\n entity_id: media_player.yandex_k\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id: media_player.yandex_k\n media_content_id: Температура в духовке ({{states('sensor.esp8266_oven_temp_k_temperature')|int(0)}}°C", "config": [ { "name": "yandex kitchen", "room": "kitchen", "type": "media_player", "id": { "entity_id": "media_player.yandex_k", "device_id": null } }, { "name": "main volume", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.main_volume", "device_id": null } }, { "name": "oven temperature", "room": "kitchen", "type": "sensor", "id": { "entity_id": "sensor.esp8266_oven_temp_k_temperature", "device_id": null } }, { "name": "alice mode", "room": "system", "type": "input_select", "id": { "entity_id": "input_select.alice_mode", "device_id": null } } ] }, { "id": "kitchen_today_dishwasher", "automation": "- alias: kitchen_today_dishwasher\n id: kitchen_today_dishwasher\n initial_state: true\n triggers:\n - trigger: event\n event_type: yandex_intent\n event_data:\n text: Кто моет посуду\n actions:\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id: '{{ trigger.event.data.entity_id }}'\n media_content_id: Сегодня посуду моет {% if is_state('input_select.dishwasher','Vova')\n %}{{['Вова','Володя','Владимир','Вовчик','Вовка']|random}}{%else%}{{['Саша','Санёк','Александр','Сашка']|random}}{%endif%}\n extra:\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'", "config": [ { "name": "main volume", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.main_volume", "device_id": null } }, { "name": "alice mode", "room": "system", "type": "input_select", "id": { "entity_id": "input_select.alice_mode", "device_id": null } }, { "name": "dishwasher", "room": "kitchen", "type": "input_select", "id": { "entity_id": "input_select.dishwasher", "device_id": null } } ] }, { "id": "kitchen_tv_plug_toggle_button", "automation": "- alias: kitchen_tv_plug_toggle_button\n id: kitchen_tv_plug_toggle_button\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0001ef61be_action\n click_type: single\n actions:\n - action: switch.toggle\n entity_id: switch.0x00158d0001e85086_plug", "config": [ { "name": "tv plug", "room": "kitchen", "type": "switch", "id": { "entity_id": "switch.0x00158d0001e85086_plug", "device_id": null } }, { "name": "action sensor kitchen", "room": "kitchen", "type": "sensor", "id": { "entity_id": "sensor.0x00158d0001ef61be_action", "device_id": null } } ] }, { "id": "system_fan_control_alice", "automation": "- alias: system_fan_control_alice\n id: system_fan_control_alice\n initial_state: true\n mode: parallel\n triggers:\n - trigger: event\n event_type: yandex_intent\n event_data:\n text: Выключи вентиляцию\n id: 'off'\n - trigger: event\n event_type: yandex_intent\n event_data:\n text: Включи вентиляцию\n id: 'on'\n conditions:\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: template\n value_template: '{{ trigger.event.data.entity_id == ''media_player.yandex_k''\n }}'\n actions:\n - action: fan.turn_{{ trigger.id }}\n entity_id: fan.esp8266_hood_k_fan", "config": [ { "name": "yandex kitchen", "room": "kitchen", "type": "media_player", "id": { "entity_id": "media_player.yandex_k", "device_id": null } }, { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "esp8266 hood fan", "room": "kitchen", "type": "fan", "id": { "entity_id": "fan.esp8266_hood_k_fan", "device_id": null } } ] }, { "id": "system_location_notify", "automation": "- alias: system_location_notify\n id: system_location_notify\n initial_state: true\n mode: queued\n max: 10\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: person.sandra, person.vova, person.sasha\n to: null\n conditions:\n - condition: template\n value_template: '{{ trigger.from_state.state != trigger.to_state.state }}'\n actions:\n - action: notify.telegram\n data:\n message: \"{%- set from = trigger.from_state.state |replace('_',' ') | title\\\n \\ %} {%- set to = trigger.to_state.state |replace('_',' ') | title %} {%-\\\n \\ set person = trigger.to_state.attributes.friendly_name %} {%- if from ==\\\n \\ 'Not Home' %}\\n {%- set event = 'прибыл' %}\\n{%- elif to == 'Not Home'\\\n \\ %}\\n {%- set event = 'покинул' %}\\n{%- else %}\\n {%- set event = 'переместился'\\\n \\ %}\\n{%- endif %} {%- if from == \\\"Not Home\\\" %} {{'\\\\U0001f30d'}} {{ person\\\n \\ + ' ' + event + ' в ' + to }} {%- elif to == \\\"Not Home\\\" %} {{'\\\\U0001f30d'}}\\\n \\ {{ person + ' ' + event + ' ' + from }} {%- else %} {{'\\\\U0001f30d'}} {{\\\n \\ person + ' ' + event + ' из ' + from + ' в ' + to }} {%- endif %}\"", "config": [ { "name": "person sasha", "room": "system", "type": "person", "id": { "entity_id": "person.sasha", "device_id": null } }, { "name": "person sandra", "room": "system", "type": "person", "id": { "entity_id": "person.sandra", "device_id": null } }, { "name": "person vova", "room": "system", "type": "person", "id": { "entity_id": "person.vova", "device_id": null } } ] }, { "id": "system_person_came_left_home", "automation": "- alias: system_person_came_left_home\n id: system_person_came_left_home\n mode: parallel\n max: 10\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id:\n - person.dima\n - person.sandra\n - person.sasha\n - person.vova\n to: null\n conditions:\n - condition: state\n entity_id: input_boolean.ha_shutdown\n state: 'off'\n for:\n seconds: 15\n - condition: template\n value_template: \"{% set ignore = ['unknown', 'unavailable', 'none'] %} {{ trigger.from_state.state\\\n \\ not in ignore and\\n trigger.to_state.state not in ignore and\\n trigger.to_state.state\\\n \\ != trigger.from_state.state }} \\n\"\n actions:\n - choose:\n - conditions:\n - condition: template\n value_template: '{{ trigger.to_state.state == ''home'' and trigger.from_state.state\n != ''home'' }}'\n sequence:\n - event: person_came_home\n - action: logbook.log\n data:\n name: Person Came Home\n message: ' - {{ trigger.entity_id }}'\n entity_id: '{{ trigger.entity_id }}'\n - conditions:\n - condition: template\n value_template: '{{ trigger.to_state.state != ''home'' and trigger.from_state.state\n == ''home'' }}'\n sequence:\n - event: person_left_home\n - action: logbook.log\n data:\n name: Person Left Home\n message: ' - {{ trigger.entity_id }}'\n entity_id: '{{ trigger.entity_id }}'", "config": [ { "name": "person sasha", "room": "system", "type": "person", "id": { "entity_id": "person.sasha", "device_id": null } }, { "name": "person sandra", "room": "system", "type": "person", "id": { "entity_id": "person.sandra", "device_id": null } }, { "name": "person vova", "room": "system", "type": "person", "id": { "entity_id": "person.vova", "device_id": null } }, { "name": "input boolean ha shutdown", "room": "system", "type": "input_boolean", "id": { "entity_id": "input_boolean.ha_shutdown", "device_id": null } }, { "name": "person dima", "room": "system", "type": "person", "id": { "entity_id": "person.dima", "device_id": null } } ] }, { "id": "system_location_home_mode", "automation": "- alias: system_location_home_mode\n id: system_location_home_mode\n triggers:\n - trigger: state\n entity_id: sensor.people_home\n to: '1'\n id: non_vac\n - trigger: state\n entity_id: sensor.people_home\n to: '0'\n for:\n hours: 24\n id: vac\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: non_vac\n sequence:\n - variables:\n txt: '{% if states(''sensor.people_home'')|int(0) > 0 %} Home {% elif states(''sensor.people_home'')|int(0)\n == 0 %} Away {% endif %}'\n - action: input_select.select_option\n entity_id: input_select.home_mode\n data:\n option: '{{ txt }}'\n - conditions:\n - condition: trigger\n id: vac\n sequence:\n - action: input_select.select_option\n entity_id: input_select.home_mode\n data:\n option: Vacation", "config": [ { "name": "people home", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.people_home", "device_id": null } }, { "name": "home mode", "room": "system", "type": "input_select", "id": { "entity_id": "input_select.home_mode", "device_id": null } } ] }, { "id": "hall_big_main_door_locks", "automation": "- alias: hall_big_main_door_locks\n id: hall_big_main_door_locks\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.top_lock\n to: null\n id: lock_top\n - trigger: state\n entity_id: binary_sensor.bottom_lock\n to: null\n id: lock_bottom\n conditions:\n - condition: numeric_state\n entity_id: sensor.ha_uptime\n above: 2\n - condition: state\n entity_id: input_boolean.ha_shutdown\n state: 'off'\n - condition: template\n value_template: '{{ states(''binary_sensor.top_lock'') in [''on'',''off''] and\n states(''binary_sensor.top_lock'') in [''on'',''off''] }}'\n - condition: template\n value_template: '{{ trigger.from_state.state != trigger.to_state.state }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: lock_top\n sequence:\n - action: notify.telegram\n data:\n message: '{% if is_state(''binary_sensor.top_lock'',''on'') %}🔓🔼 Верхний\n замок открыт!{% else %}🔒🔼 Верхний замок закрыт!{% endif %}'\n - conditions:\n - condition: trigger\n id: lock_bottom\n sequence:\n - action: notify.telegram\n data:\n message: '{% if is_state(''binary_sensor.bottom_lock'',''on'') %}🔓🔽 Нижний\n замок открыт!{% else %}🔒🔽 Нижний замок закрыт!{% endif %}'\n - action: script.turn_on\n entity_id: script.domofon_locks_indicator", "config": [ { "name": "input boolean ha shutdown", "room": "system", "type": "input_boolean", "id": { "entity_id": "input_boolean.ha_shutdown", "device_id": null } }, { "name": "top lock", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.top_lock", "device_id": null } }, { "name": "bottom lock", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.bottom_lock", "device_id": null } }, { "name": "ha uptime", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.ha_uptime", "device_id": null } }, { "name": "Domofon Locks Indicator Script", "room": null, "type": "script", "id": { "entity_id": "script.domofon_locks_indicator", "device_id": null } } ] }, { "id": "hall_big_main_door_not_closed_3m", "automation": "- alias: hall_big_main_door_not_closed_3m\n id: hall_big_main_door_not_closed_3m\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /3\n conditions:\n - condition: state\n entity_id:\n - binary_sensor.0x00158d0001e5d6be_contact\n state: 'on'\n for:\n minutes: 3\n actions:\n - if:\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'on'\n then:\n - action: media_player.volume_set\n data:\n entity_id:\n - media_player.yandex_hb\n volume_level: '0.7'\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id: media_player.yandex_hb\n media_content_id: Вним+ание! Входн+ая дв+ерь н+е закр+ыта! Входн+ая дв+ерь\n н+е закр+ыта!\n - action: notify.telegram\n data:\n message: 👁 Внимание! Входная дверь НЕ закрыта!\n - action: script.turn_on\n entity_id: script.open_door_photo\n - action: media_player.volume_set\n data:\n entity_id: media_player.yandex_hb\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'", "config": [ { "name": "yandex hall big", "room": "hall_big", "type": "media_player", "id": { "entity_id": "media_player.yandex_hb", "device_id": null } }, { "name": "main volume", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.main_volume", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "alice mode", "room": "system", "type": "input_select", "id": { "entity_id": "input_select.alice_mode", "device_id": null } }, { "name": "main door contact", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001e5d6be_contact", "device_id": null } }, { "name": "Open Door Photo Script", "room": null, "type": "script", "id": { "entity_id": "script.open_door_photo", "device_id": null } } ] }, { "id": "hall_big_main_door_closed", "automation": "- alias: hall_big_main_door_closed\n id: hall_big_main_door_closed\n initial_state: true\n triggers:\n - trigger: state\n entity_id:\n - binary_sensor.0x00158d0001e5d6be_contact\n from: 'on'\n to: 'off'\n actions:\n - action: notify.telegram\n data:\n title: Doorbell photo\n message: 🔔 Входная дверь закрыта!\n data:\n photo:\n - url: http://localhost:1984/api/frame.jpeg?src=g4_doorbell\n caption: 🚪 Входная дверь закрыта {{ states('sensor.time') }}, была открыта\n {{(as_timestamp(now())|int(0)-states('input_number.main_door_open')|int(0))\n | timestamp_custom('%H:%M:%S',false,0)}}\n - action: timer.cancel\n entity_id: timer.main_door_open_hb", "config": [ { "name": "time", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.time", "device_id": null } }, { "name": "main door contact", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001e5d6be_contact", "device_id": null } }, { "name": "main door open", "room": "hall_big", "type": "input_number", "id": { "entity_id": "input_number.main_door_open", "device_id": null } }, { "name": "timer main door open hb", "room": "hall_big", "type": "timer", "id": { "entity_id": "timer.main_door_open_hb", "device_id": null } } ] }, { "id": "mqtt_sensors_discovery", "automation": "- id: mqtt_sensors_discovery\n alias: mqtt_sensors_discovery\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.mqtt_broker_main\n to: 'on'\n - event: start\n platform: homeassistant\n - trigger: event\n event_type: automation_reloaded\n conditions:\n - condition: state\n entity_id: binary_sensor.mqtt_broker_main\n state: 'on'\n actions:\n - action: mqtt.publish\n data:\n topic: homeassistant/binary_sensor/lxc_plex_media_mount/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"LXC Plex Media Mount\\\", \\n \\\"state_topic\\\":\\\"lxc_plex/binary\\\"\\\n ,\\n \\\"unique_id\\\":\\\"lxc_plex_media_mount\\\",\\n \\\"device_class\\\":\\\"connectivity\\\"\\\n ,\\n \\\"payload_on\\\":\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"device\\\":{\\\"\\\n identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"System\\\"\\\n }\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/config_line_count/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Config Line Count\\\", \\n \\\"state_topic\\\":\\\"hp600g6/config_linecount\\\"\\\n ,\\n \\\"unique_id\\\":\\\"config_line_count\\\",\\n \\\"icon\\\":\\\"mdi:format-list-bulleted\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"lines\\\",\\n \\\"entity_category\\\": \\\"diagnostic\\\"\\\n ,\\n \\\"value_template\\\":\\\"{{ '{{' }} value|int(0) {{ '}}' }}\\\", \\n \\\"device\\\"\\\n :{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"\\\n System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/config_line_count_code/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Config Line Count Code\\\", \\n \\\"state_topic\\\":\\\"\\\n hp600g6/config_linecount_code\\\",\\n \\\"unique_id\\\":\\\"config_line_count_code\\\"\\\n ,\\n \\\"icon\\\":\\\"mdi:format-list-numbered\\\",\\n \\\"unit_of_measurement\\\":\\\"\\\n lines\\\",\\n \\\"entity_category\\\": \\\"diagnostic\\\",\\n \\\"value_template\\\":\\\"\\\n {{ '{{' }} value|int(0) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"\\\n sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/music_allowed/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Music Allowed\\\",\\n \\\"command_topic\\\":\\\"servers/main_states/music_allowed\\\"\\\n ,\\n \\\"state_topic\\\":\\\"servers/main_states/music_allowed\\\",\\n \\\"payload_on\\\"\\\n :\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"ON\\\",\\n \\\"state_off\\\"\\\n :\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\":\\\"true\\\",\\n \\\"unique_id\\\"\\\n :\\\"music_allowed\\\",\\n \\\"icon\\\":\\\"mdi:volume-high\\\",\\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/guest_mode/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Guest Mode\\\",\\n \\\"command_topic\\\":\\\"servers/main_states/guest_mode\\\"\\\n ,\\n \\\"state_topic\\\":\\\"servers/main_states/guest_mode\\\",\\n \\\"payload_on\\\"\\\n :\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"ON\\\",\\n \\\"state_off\\\"\\\n :\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\":\\\"true\\\",\\n \\\"unique_id\\\"\\\n :\\\"guest_mode\\\",\\n \\\"icon\\\":\\\"mdi:account-question\\\",\\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/main_lead/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Main Lead\\\",\\n \\\"command_topic\\\":\\\"servers/main_states/main_lead\\\"\\\n ,\\n \\\"state_topic\\\":\\\"servers/main_states/main_lead\\\",\\n \\\"payload_on\\\"\\\n :\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"ON\\\",\\n \\\"state_off\\\"\\\n :\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\":\\\"true\\\",\\n \\\"unique_id\\\"\\\n :\\\"main_lead\\\",\\n \\\"icon\\\":\\\"mdi:server-network\\\",\\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/led_strip_bed_v_restart_key/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"LED Strip Bed V Restart Key\\\",\\n \\\"command_topic\\\"\\\n :\\\"servers/main_states/led_strip_bed_v_restart_key\\\",\\n \\\"state_topic\\\":\\\"\\\n servers/main_states/led_strip_bed_v_restart_key\\\",\\n \\\"payload_on\\\":\\\"ON\\\"\\\n ,\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"ON\\\",\\n \\\"state_off\\\":\\\"\\\n OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\":\\\"true\\\",\\n \\\"unique_id\\\"\\\n :\\\"led_strip_bed_v_restart_key\\\",\\n \\\"icon\\\":\\\"mdi:restart\\\",\\n \\\"device\\\"\\\n :{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"\\\n System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/square_led_v_restart_key/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Square LED V Restart Key\\\",\\n \\\"command_topic\\\"\\\n :\\\"servers/main_states/square_led_v_restart_key\\\",\\n \\\"state_topic\\\":\\\"servers/main_states/square_led_v_restart_key\\\"\\\n ,\\n \\\"payload_on\\\":\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"\\\n ON\\\",\\n \\\"state_off\\\":\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\"\\\n :\\\"true\\\",\\n \\\"unique_id\\\":\\\"square_led_v_restart_key\\\",\\n \\\"icon\\\":\\\"mdi:restart\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\"\\\n ,\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/led_color_v_restart_key/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"LED Color V Restart Key\\\",\\n \\\"command_topic\\\":\\\"\\\n servers/main_states/led_color_v_restart_key\\\",\\n \\\"state_topic\\\":\\\"servers/main_states/led_color_v_restart_key\\\"\\\n ,\\n \\\"payload_on\\\":\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"\\\n ON\\\",\\n \\\"state_off\\\":\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\"\\\n :\\\"true\\\",\\n \\\"unique_id\\\":\\\"led_color_v_restart_key\\\",\\n \\\"icon\\\":\\\"mdi:restart\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\"\\\n ,\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/led_color_s_restart_key/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"LED Color S Restart Key\\\",\\n \\\"command_topic\\\":\\\"\\\n servers/main_states/led_color_s_restart_key\\\",\\n \\\"state_topic\\\":\\\"servers/main_states/led_color_s_restart_key\\\"\\\n ,\\n \\\"payload_on\\\":\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"\\\n ON\\\",\\n \\\"state_off\\\":\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\"\\\n :\\\"true\\\",\\n \\\"unique_id\\\":\\\"led_color_s_restart_key\\\",\\n \\\"icon\\\":\\\"mdi:restart\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\"\\\n ,\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/led_white_s_restart_key/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"LED White S Restart Key\\\",\\n \\\"command_topic\\\":\\\"\\\n servers/main_states/led_white_s_restart_key\\\",\\n \\\"state_topic\\\":\\\"servers/main_states/led_white_s_restart_key\\\"\\\n ,\\n \\\"payload_on\\\":\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"\\\n ON\\\",\\n \\\"state_off\\\":\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\"\\\n :\\\"true\\\",\\n \\\"unique_id\\\":\\\"led_white_s_restart_key\\\",\\n \\\"icon\\\":\\\"mdi:restart\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\"\\\n ,\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/led_white_mb_restart_key/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"LED White MB Restart Key\\\",\\n \\\"command_topic\\\"\\\n :\\\"servers/main_states/led_white_mb_restart_key\\\",\\n \\\"state_topic\\\":\\\"servers/main_states/led_white_mb_restart_key\\\"\\\n ,\\n \\\"payload_on\\\":\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"\\\n ON\\\",\\n \\\"state_off\\\":\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\"\\\n :\\\"true\\\",\\n \\\"unique_id\\\":\\\"led_white_mb_restart_key\\\",\\n \\\"icon\\\":\\\"mdi:restart\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\"\\\n ,\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/square_led_s_restart_key/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Square LED S Restart Key\\\",\\n \\\"command_topic\\\"\\\n :\\\"servers/main_states/square_led_s_restart_key\\\",\\n \\\"state_topic\\\":\\\"servers/main_states/square_led_s_restart_key\\\"\\\n ,\\n \\\"payload_on\\\":\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"\\\n ON\\\",\\n \\\"state_off\\\":\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\"\\\n :\\\"true\\\",\\n \\\"unique_id\\\":\\\"square_led_s_restart_key\\\",\\n \\\"icon\\\":\\\"mdi:restart\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\"\\\n ,\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/light_bar_s_restart_key/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Light Bar S Restart Key\\\",\\n \\\"command_topic\\\":\\\"\\\n servers/main_states/light_bar_s_restart_key\\\",\\n \\\"state_topic\\\":\\\"servers/main_states/light_bar_s_restart_key\\\"\\\n ,\\n \\\"payload_on\\\":\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"\\\n ON\\\",\\n \\\"state_off\\\":\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\"\\\n :\\\"true\\\",\\n \\\"unique_id\\\":\\\"light_bar_s_restart_key\\\",\\n \\\"icon\\\":\\\"mdi:restart\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\"\\\n ,\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/bedside_restart_key/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Bedside Restart Key\\\",\\n \\\"command_topic\\\":\\\"servers/main_states/bedside_restart_key\\\"\\\n ,\\n \\\"state_topic\\\":\\\"servers/main_states/bedside_restart_key\\\",\\n \\\"payload_on\\\"\\\n :\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"ON\\\",\\n \\\"state_off\\\"\\\n :\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\":\\\"true\\\",\\n \\\"unique_id\\\"\\\n :\\\"bedside_restart_key\\\",\\n \\\"icon\\\":\\\"mdi:restart\\\",\\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/round_led_mb_restart_key/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Round LED MB Restart Key\\\",\\n \\\"command_topic\\\"\\\n :\\\"servers/main_states/round_led_mb_restart_key\\\",\\n \\\"state_topic\\\":\\\"servers/main_states/round_led_mb_restart_key\\\"\\\n ,\\n \\\"payload_on\\\":\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"\\\n ON\\\",\\n \\\"state_off\\\":\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\"\\\n :\\\"true\\\",\\n \\\"unique_id\\\":\\\"round_led_mb_restart_key\\\",\\n \\\"icon\\\":\\\"mdi:restart\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\"\\\n ,\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/round_led_k_restart_key/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Round LED K Restart Key\\\",\\n \\\"command_topic\\\":\\\"\\\n servers/main_states/round_led_k_restart_key\\\",\\n \\\"state_topic\\\":\\\"servers/main_states/round_led_k_restart_key\\\"\\\n ,\\n \\\"payload_on\\\":\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"\\\n ON\\\",\\n \\\"state_off\\\":\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\"\\\n :\\\"true\\\",\\n \\\"unique_id\\\":\\\"round_led_k_restart_key\\\",\\n \\\"icon\\\":\\\"mdi:restart\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\"\\\n ,\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/round_led_hs_restart_key/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Round LED HS Restart Key\\\",\\n \\\"command_topic\\\"\\\n :\\\"servers/main_states/round_led_hs_restart_key\\\",\\n \\\"state_topic\\\":\\\"servers/main_states/round_led_hs_restart_key\\\"\\\n ,\\n \\\"payload_on\\\":\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"\\\n ON\\\",\\n \\\"state_off\\\":\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\"\\\n :\\\"true\\\",\\n \\\"unique_id\\\":\\\"round_led_hs_restart_key\\\",\\n \\\"icon\\\":\\\"mdi:restart\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\"\\\n ,\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/round_led_st_restart_key/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Round LED St Restart Key\\\",\\n \\\"command_topic\\\"\\\n :\\\"servers/main_states/round_led_st_restart_key\\\",\\n \\\"state_topic\\\":\\\"servers/main_states/round_led_st_restart_key\\\"\\\n ,\\n \\\"payload_on\\\":\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"\\\n ON\\\",\\n \\\"state_off\\\":\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\"\\\n :\\\"true\\\",\\n \\\"unique_id\\\":\\\"round_led_st_restart_key\\\",\\n \\\"icon\\\":\\\"mdi:restart\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\"\\\n ,\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/mirror_light_b_restart_key/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Mirror Light B Restart Key\\\",\\n \\\"command_topic\\\"\\\n :\\\"servers/main_states/mirror_light_b_restart_key\\\",\\n \\\"state_topic\\\":\\\"\\\n servers/main_states/mirror_light_b_restart_key\\\",\\n \\\"payload_on\\\":\\\"ON\\\"\\\n ,\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"ON\\\",\\n \\\"state_off\\\":\\\"\\\n OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\":\\\"true\\\",\\n \\\"unique_id\\\"\\\n :\\\"mirror_light_b_restart_key\\\",\\n \\\"icon\\\":\\\"mdi:restart\\\",\\n \\\"device\\\"\\\n :{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"\\\n System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/led_strip_entrance_hb_restart_key/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"LED Strip Entrance HB Restart Key\\\",\\n \\\"command_topic\\\"\\\n :\\\"servers/main_states/led_strip_entrance_hb_restart_key\\\",\\n \\\"state_topic\\\"\\\n :\\\"servers/main_states/led_strip_entrance_hb_restart_key\\\",\\n \\\"payload_on\\\"\\\n :\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"ON\\\",\\n \\\"state_off\\\"\\\n :\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\":\\\"true\\\",\\n \\\"unique_id\\\"\\\n :\\\"led_strip_entrance_hb_restart_key\\\",\\n \\\"icon\\\":\\\"mdi:restart\\\",\\n \\\"\\\n device\\\":{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"\\\n name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/led_strip_hb_restart_key/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"LED Strip HB Restart Key\\\",\\n \\\"command_topic\\\"\\\n :\\\"servers/main_states/led_strip_hb_restart_key\\\",\\n \\\"state_topic\\\":\\\"servers/main_states/led_strip_hb_restart_key\\\"\\\n ,\\n \\\"payload_on\\\":\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"\\\n ON\\\",\\n \\\"state_off\\\":\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\"\\\n :\\\"true\\\",\\n \\\"unique_id\\\":\\\"led_strip_hb_restart_key\\\",\\n \\\"icon\\\":\\\"mdi:restart\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\"\\\n ,\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/maintenance_mode/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Maintenance Mode\\\",\\n \\\"command_topic\\\":\\\"servers/main_states/maintenance_mode\\\"\\\n ,\\n \\\"state_topic\\\":\\\"servers/main_states/maintenance_mode\\\",\\n \\\"payload_on\\\"\\\n :\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"ON\\\",\\n \\\"state_off\\\"\\\n :\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\":\\\"true\\\",\\n \\\"unique_id\\\"\\\n :\\\"maintenance_mode\\\",\\n \\\"icon\\\":\\\"mdi:hammer-wrench\\\",\\n \\\"device\\\":{\\\"\\\n identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"System\\\"\\\n } \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/security_mode/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Security Mode\\\",\\n \\\"command_topic\\\":\\\"servers/main_states/security_mode\\\"\\\n ,\\n \\\"state_topic\\\":\\\"servers/main_states/security_mode\\\",\\n \\\"payload_on\\\"\\\n :\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"ON\\\",\\n \\\"state_off\\\"\\\n :\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\":\\\"true\\\",\\n \\\"unique_id\\\"\\\n :\\\"security_mode\\\",\\n \\\"icon\\\":\\\"mdi:police-badge\\\",\\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/select/mode_breather_v/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Mode Breather V\\\",\\n \\\"command_topic\\\":\\\"servers/main_states/mode_breather_v\\\"\\\n ,\\n \\\"state_topic\\\":\\\"servers/main_states/mode_breather_v\\\",\\n \\\"options\\\"\\\n : [\\\"Auto\\\", \\\"Manual\\\", \\\"Programm\\\", \\\"Off\\\"],\\n \\\"optimistic\\\":\\\"false\\\"\\\n ,\\n \\\"retain\\\":\\\"true\\\",\\n \\\"unique_id\\\":\\\"mode_breather_v\\\",\\n \\\"icon\\\"\\\n :\\\"mdi:fan\\\",\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\"\\\n :\\\"DTsymbal\\\",\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/select/mode_breather_s/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Mode Breather S\\\",\\n \\\"command_topic\\\":\\\"servers/main_states/mode_breather_s\\\"\\\n ,\\n \\\"state_topic\\\":\\\"servers/main_states/mode_breather_s\\\",\\n \\\"options\\\"\\\n : [\\\"Auto\\\", \\\"Manual\\\", \\\"Programm\\\", \\\"Off\\\"],\\n \\\"optimistic\\\":\\\"false\\\"\\\n ,\\n \\\"retain\\\":\\\"true\\\",\\n \\\"unique_id\\\":\\\"mode_breather_s\\\",\\n \\\"icon\\\"\\\n :\\\"mdi:fan\\\",\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\"\\\n :\\\"DTsymbal\\\",\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/select/mode_breather_mb/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Mode Breather MB\\\",\\n \\\"command_topic\\\":\\\"servers/main_states/mode_breather_mb\\\"\\\n ,\\n \\\"state_topic\\\":\\\"servers/main_states/mode_breather_mb\\\",\\n \\\"options\\\"\\\n : [\\\"Auto\\\", \\\"Manual\\\", \\\"Programm\\\", \\\"Off\\\"],\\n \\\"optimistic\\\":\\\"false\\\"\\\n ,\\n \\\"retain\\\":\\\"true\\\",\\n \\\"unique_id\\\":\\\"mode_breather_mb\\\",\\n \\\"icon\\\"\\\n :\\\"mdi:fan\\\",\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\"\\\n :\\\"DTsymbal\\\",\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/hourly_mode_breather_v/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Hourly Mode Breather V\\\",\\n \\\"command_topic\\\":\\\"\\\n servers/main_states/hourly_mode_breather_v\\\",\\n \\\"state_topic\\\":\\\"servers/main_states/hourly_mode_breather_v\\\"\\\n ,\\n \\\"payload_on\\\":\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"\\\n ON\\\",\\n \\\"state_off\\\":\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\"\\\n :\\\"true\\\",\\n \\\"unique_id\\\":\\\"hourly_mode_breather_v\\\",\\n \\\"icon\\\":\\\"mdi:flash-auto\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\"\\\n ,\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/breather_auto_v/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Breather Auto V\\\",\\n \\\"command_topic\\\":\\\"servers/main_states/breather_auto_v\\\"\\\n ,\\n \\\"state_topic\\\":\\\"servers/main_states/breather_auto_v\\\",\\n \\\"payload_on\\\"\\\n :\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"ON\\\",\\n \\\"state_off\\\"\\\n :\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\":\\\"true\\\",\\n \\\"unique_id\\\"\\\n :\\\"breather_auto_v\\\",\\n \\\"icon\\\":\\\"mdi:flash-auto\\\",\\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/breather_auto_mb/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Breather Auto MB\\\",\\n \\\"command_topic\\\":\\\"servers/main_states/breather_auto_mb\\\"\\\n ,\\n \\\"state_topic\\\":\\\"servers/main_states/breather_auto_mb\\\",\\n \\\"payload_on\\\"\\\n :\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"ON\\\",\\n \\\"state_off\\\"\\\n :\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\":\\\"true\\\",\\n \\\"unique_id\\\"\\\n :\\\"breather_auto_mb\\\",\\n \\\"icon\\\":\\\"mdi:flash-auto\\\",\\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/breather_auto_s/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Breather Auto S\\\",\\n \\\"command_topic\\\":\\\"servers/main_states/breather_auto_s\\\"\\\n ,\\n \\\"state_topic\\\":\\\"servers/main_states/breather_auto_s\\\",\\n \\\"payload_on\\\"\\\n :\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"ON\\\",\\n \\\"state_off\\\"\\\n :\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\":\\\"true\\\",\\n \\\"unique_id\\\"\\\n :\\\"breather_auto_s\\\",\\n \\\"icon\\\":\\\"mdi:flash-auto\\\",\\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/breather_speed_auto_v/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Breather Auto Speed V\\\",\\n \\\"command_topic\\\":\\\"\\\n servers/main_states/breather_speed_auto_v\\\",\\n \\\"state_topic\\\":\\\"servers/main_states/breather_speed_auto_v\\\"\\\n ,\\n \\\"payload_on\\\":\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"retain\\\":\\\"true\\\"\\\n ,\\n \\\"state_on\\\":\\\"ON\\\",\\n \\\"state_off\\\":\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\"\\\n ,\\n \\\"unique_id\\\":\\\"breather_speed_auto_v\\\",\\n \\\"icon\\\":\\\"mdi:fan-auto\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\"\\\n ,\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/breather_speed_auto_mb/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Breather Auto Speed MB\\\",\\n \\\"command_topic\\\":\\\"\\\n servers/main_states/breather_speed_auto_mb\\\",\\n \\\"state_topic\\\":\\\"servers/main_states/breather_speed_auto_mb\\\"\\\n ,\\n \\\"payload_on\\\":\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"\\\n ON\\\",\\n \\\"state_off\\\":\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\"\\\n :\\\"true\\\",\\n \\\"unique_id\\\":\\\"breather_speed_auto_mb\\\",\\n \\\"icon\\\":\\\"mdi:fan-auto\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\"\\\n ,\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/breather_speed_auto_s/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Breather Auto Speed S\\\",\\n \\\"command_topic\\\":\\\"\\\n servers/main_states/breather_speed_auto_s\\\",\\n \\\"state_topic\\\":\\\"servers/main_states/breather_speed_auto_s\\\"\\\n ,\\n \\\"payload_on\\\":\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"\\\n ON\\\",\\n \\\"state_off\\\":\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\"\\\n :\\\"true\\\",\\n \\\"unique_id\\\":\\\"breather_speed_auto_s\\\",\\n \\\"icon\\\":\\\"mdi:fan-auto\\\"\\\n ,\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\"\\\n ,\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/breather_manual_v/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Breather Manual V\\\",\\n \\\"command_topic\\\":\\\"servers/main_states/breather_manual_v\\\"\\\n ,\\n \\\"state_topic\\\":\\\"servers/main_states/breather_manual_v\\\",\\n \\\"payload_on\\\"\\\n :\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"ON\\\",\\n \\\"state_off\\\"\\\n :\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\":\\\"true\\\",\\n \\\"unique_id\\\"\\\n :\\\"breather_manual_v\\\",\\n \\\"icon\\\":\\\"mdi:flash-red-eye\\\",\\n \\\"device\\\":{\\\"\\\n identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"System\\\"\\\n } \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/breather_manual_s/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Breather Manual S\\\",\\n \\\"command_topic\\\":\\\"servers/main_states/breather_manual_s\\\"\\\n ,\\n \\\"state_topic\\\":\\\"servers/main_states/breather_manual_s\\\",\\n \\\"payload_on\\\"\\\n :\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"ON\\\",\\n \\\"state_off\\\"\\\n :\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\":\\\"true\\\",\\n \\\"unique_id\\\"\\\n :\\\"breather_manual_s\\\",\\n \\\"icon\\\":\\\"mdi:flash-red-eye\\\",\\n \\\"device\\\":{\\\"\\\n identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"System\\\"\\\n } \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/breather_manual_mb/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Breather Manual MB\\\",\\n \\\"command_topic\\\":\\\"servers/main_states/breather_manual_mb\\\"\\\n ,\\n \\\"state_topic\\\":\\\"servers/main_states/breather_manual_mb\\\",\\n \\\"payload_on\\\"\\\n :\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"ON\\\",\\n \\\"state_off\\\"\\\n :\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\":\\\"true\\\",\\n \\\"unique_id\\\"\\\n :\\\"breather_manual_mb\\\",\\n \\\"icon\\\":\\\"mdi:flash-red-eye\\\",\\n \\\"device\\\"\\\n :{\\\"identifiers\\\":[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"\\\n System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/silent_mode/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Silent Mode\\\",\\n \\\"command_topic\\\":\\\"servers/main_states/silent_mode\\\"\\\n ,\\n \\\"state_topic\\\":\\\"servers/main_states/silent_mode\\\",\\n \\\"payload_on\\\"\\\n :\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"ON\\\",\\n \\\"state_off\\\"\\\n :\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\":\\\"true\\\",\\n \\\"unique_id\\\"\\\n :\\\"silent_mode\\\",\\n \\\"icon\\\":\\\"mdi:volume-off\\\",\\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/switch/dark_mode/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Dark Mode\\\",\\n \\\"command_topic\\\":\\\"servers/main_states/dark_mode\\\"\\\n ,\\n \\\"state_topic\\\":\\\"servers/main_states/dark_mode\\\",\\n \\\"payload_on\\\"\\\n :\\\"ON\\\",\\n \\\"payload_off\\\":\\\"OFF\\\",\\n \\\"state_on\\\":\\\"ON\\\",\\n \\\"state_off\\\"\\\n :\\\"OFF\\\",\\n \\\"optimistic\\\":\\\"false\\\",\\n \\\"retain\\\":\\\"true\\\",\\n \\\"unique_id\\\"\\\n :\\\"dark_mode\\\",\\n \\\"icon\\\":\\\"mdi:weather-night\\\",\\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/binary_sensor/main_server_state/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Main Server State\\\", \\n \\\"state_topic\\\":\\\"servers/main_server\\\"\\\n ,\\n \\\"device_class\\\":\\\"connectivity\\\",\\n \\\"payload_on\\\":\\\"ON\\\",\\n \\\"payload_off\\\"\\\n :\\\"OFF\\\",\\n \\\"unique_id\\\":\\\"main_server_state\\\",\\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/binary_sensor/backup_server_state/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Backup Server State\\\", \\n \\\"state_topic\\\":\\\"servers/backup_server\\\"\\\n ,\\n \\\"device_class\\\":\\\"connectivity\\\",\\n \\\"payload_on\\\":\\\"ON\\\",\\n \\\"payload_off\\\"\\\n :\\\"OFF\\\",\\n \\\"unique_id\\\":\\\"backup_server_state\\\",\\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"sys_info\\\"],\\\"manufacturer\\\":\\\"DTsymbal\\\",\\\"name\\\":\\\"System\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds1621plus_fan_speed/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Fan Speed\\\", \\n \\\"state_topic\\\":\\\"1621/fan_speed\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds1621plus_fan_speed\\\",\\n \\\"icon\\\":\\\"mdi:fan\\\",\\n \\\"\\\n entity_category\\\": \\\"diagnostic\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} value\\\n \\ | capitalize {{ '}}' }}\\\",\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"1621\\\"],\\\"\\\n manufacturer\\\":\\\"Synology\\\",\\\"model\\\":\\\"DS1621+\\\",\\\"name\\\":\\\"ds1621plus\\\"\\\n }\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds1621plus_fan1_rpm/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Fan1 RPM\\\", \\n \\\"state_topic\\\":\\\"1621/fan1\\\", \\n\\\n \\ \\\"icon\\\":\\\"mdi:fan\\\", \\n \\\"unit_of_measurement\\\": \\\"RPM\\\",\\n \\\"unique_id\\\"\\\n :\\\"ds1621plus_fan1\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} ( value|int(0) ) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"1621\\\"],\\\"manufacturer\\\":\\\"Synology\\\",\\\"model\\\":\\\"DS1621+\\\",\\\"name\\\":\\\"\\\n ds1621plus\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds1621plus_fan2_rpm/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Fan2 RPM\\\", \\n \\\"state_topic\\\":\\\"1621/fan2\\\", \\n\\\n \\ \\\"icon\\\":\\\"mdi:fan\\\", \\n \\\"unit_of_measurement\\\": \\\"RPM\\\",\\n \\\"unique_id\\\"\\\n :\\\"ds1621plus_fan2\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} ( value|int(0) ) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"1621\\\"],\\\"manufacturer\\\":\\\"Synology\\\",\\\"model\\\":\\\"DS1621+\\\",\\\"name\\\":\\\"\\\n ds1621plus\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds1621plus_nvme0_data_units_read/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Data Units Read\\\", \\n \\\"state_topic\\\":\\\"1621/nvme0/read\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds1621plus_nvme0_data_units_read\\\",\\n \\\"icon\\\":\\\"mdi:alpha-r-circle\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Gb\\\",\\n \\\"entity_category\\\": \\\"diagnostic\\\"\\\n ,\\n \\\"value_template\\\":\\\"{{ '{{' }} ( value|int(0) * 512 / 1024 / 1024 /\\\n \\ 1024 ) | round(2) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"1621_nvme0\\\"\\\n ],\\\"manufacturer\\\":\\\"Silicon Power\\\",\\\"model\\\":\\\"A80 1Tb\\\",\\\"name\\\":\\\"ds1621plus\\\n \\ nvme0\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds1621plus_nvme0_data_units_written/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Data Units Written\\\", \\n \\\"state_topic\\\":\\\"1621/nvme0/write\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds1621plus_nvme0_data_units_written\\\",\\n \\\"icon\\\":\\\"\\\n mdi:alpha-w-circle\\\",\\n \\\"unit_of_measurement\\\":\\\"Gb\\\",\\n \\\"entity_category\\\"\\\n : \\\"diagnostic\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} ( value|int(0) * 512\\\n \\ / 1024 / 1024 / 1024 ) | round(2) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"1621_nvme0\\\"],\\\"manufacturer\\\":\\\"Silicon Power\\\",\\\"model\\\":\\\"A80 1Tb\\\"\\\n ,\\\"name\\\":\\\"ds1621plus nvme0\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds1621plus_nvme0_power_on_hours/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Power On Hours\\\", \\n \\\"state_topic\\\":\\\"1621/nvme0/power_on_hours\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds1621plus_nvme0_power_on_hours\\\",\\n \\\"icon\\\":\\\"mdi:calendar-clock\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"hr\\\",\\n \\\"entity_category\\\": \\\"diagnostic\\\"\\\n ,\\n \\\"value_template\\\":\\\"{{ '{{' }} ( value|int(0) ) {{ '}}' }}\\\", \\n \\\"\\\n device\\\":{\\\"identifiers\\\":[\\\"1621_nvme0\\\"],\\\"manufacturer\\\":\\\"Silicon Power\\\"\\\n ,\\\"model\\\":\\\"A80 1Tb\\\",\\\"name\\\":\\\"ds1621plus nvme0\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds1621plus_nvme0_wear_leveling_count/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Wear Leveling Count\\\", \\n \\\"state_topic\\\":\\\"1621/nvme0/percent\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds1621plus_nvme0_wear_leveling_count\\\",\\n \\\"icon\\\":\\\"\\\n mdi:percent-circle\\\",\\n \\\"unit_of_measurement\\\":\\\"%\\\",\\n \\\"entity_category\\\"\\\n : \\\"diagnostic\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} ( value|int(0) ) {{ '}}'\\\n \\ }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"1621_nvme0\\\"],\\\"manufacturer\\\"\\\n :\\\"Silicon Power\\\",\\\"model\\\":\\\"A80 1Tb\\\",\\\"name\\\":\\\"ds1621plus nvme0\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds1621plus_nvme1_data_units_read/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Data Units Read\\\", \\n \\\"state_topic\\\":\\\"1621/nvme1/read\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds1621plus_nvme1_data_units_read\\\",\\n \\\"icon\\\":\\\"mdi:alpha-r-circle\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Gb\\\",\\n \\\"entity_category\\\": \\\"diagnostic\\\"\\\n ,\\n \\\"value_template\\\":\\\"{{ '{{' }} ( value|int(0) * 512 / 1024 / 1024 /\\\n \\ 1024 ) | round(2) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"1621_nvme1\\\"\\\n ],\\\"manufacturer\\\":\\\"Silicon Power\\\",\\\"model\\\":\\\"A80 1Tb\\\",\\\"name\\\":\\\"ds1621plus\\\n \\ nvme1\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds1621plus_nvme1_data_units_written/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Data Units Written\\\", \\n \\\"state_topic\\\":\\\"1621/nvme1/write\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds1621plus_nvme1_data_units_written\\\",\\n \\\"icon\\\":\\\"\\\n mdi:alpha-w-circle\\\",\\n \\\"unit_of_measurement\\\":\\\"Gb\\\",\\n \\\"entity_category\\\"\\\n : \\\"diagnostic\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} ( value|int(0) * 512\\\n \\ / 1024 / 1024 / 1024 ) | round(2) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"1621_nvme1\\\"],\\\"manufacturer\\\":\\\"Silicon Power\\\",\\\"model\\\":\\\"A80 1Tb\\\"\\\n ,\\\"name\\\":\\\"ds1621plus nvme1\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds1621plus_nvme1_power_on_hours/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Power On Hours\\\", \\n \\\"state_topic\\\":\\\"1621/nvme1/power_on_hours\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds1621plus_nvme1_power_on_hours\\\",\\n \\\"icon\\\":\\\"mdi:calendar-clock\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"hr\\\",\\n \\\"entity_category\\\": \\\"diagnostic\\\"\\\n ,\\n \\\"value_template\\\":\\\"{{ '{{' }} ( value|int(0) ) {{ '}}' }}\\\", \\n \\\"\\\n device\\\":{\\\"identifiers\\\":[\\\"1621_nvme1\\\"],\\\"manufacturer\\\":\\\"Silicon Power\\\"\\\n ,\\\"model\\\":\\\"A80 1Tb\\\",\\\"name\\\":\\\"ds1621plus nvme1\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds1621plus_nvme1_wear_leveling_count/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Wear Leveling Count\\\", \\n \\\"state_topic\\\":\\\"1621/nvme1/percent\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds1621plus_nvme1_wear_leveling_count\\\",\\n \\\"icon\\\":\\\"\\\n mdi:percent-circle\\\",\\n \\\"unit_of_measurement\\\":\\\"%\\\",\\n \\\"entity_category\\\"\\\n : \\\"diagnostic\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} ( value|int(0) ) {{ '}}'\\\n \\ }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"1621_nvme1\\\"],\\\"manufacturer\\\"\\\n :\\\"Silicon Power\\\",\\\"model\\\":\\\"A80 1Tb\\\",\\\"name\\\":\\\"ds1621plus nvme1\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds1621plus_usb1_wear_leveling_count/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Wear Leveling Count\\\", \\n \\\"state_topic\\\":\\\"1621/usb1/wear_leveling_count\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds1621plus_usb1_wear_leveling_count\\\",\\n \\\"icon\\\":\\\"\\\n mdi:percent-circle\\\",\\n \\\"unit_of_measurement\\\":\\\"%\\\",\\n \\\"entity_category\\\"\\\n : \\\"diagnostic\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} ( value|int(0) ) {{ '}}'\\\n \\ }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"1621_usb1\\\"],\\\"manufacturer\\\":\\\"\\\n Samsung\\\",\\\"model\\\":\\\"PM883 960Gb\\\",\\\"name\\\":\\\"ds1621plus usb1\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds1621plus_usb1_total_lbas_written/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Total LBAs Written\\\", \\n \\\"state_topic\\\":\\\"1621/usb1/total_lbas_written\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds1621plus_usb1_total_lbas_written\\\",\\n \\\"icon\\\":\\\"\\\n mdi:alpha-w-circle\\\",\\n \\\"unit_of_measurement\\\":\\\"Tb\\\",\\n \\\"entity_category\\\"\\\n : \\\"diagnostic\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} ( value|int(0) * 512000\\\n \\ / 1024 / 1024 / 1024 / 1024 / 1024 ) | round(2) {{ '}}' }}\\\", \\n \\\"device\\\"\\\n :{\\\"identifiers\\\":[\\\"1621_usb1\\\"],\\\"manufacturer\\\":\\\"Samsung\\\",\\\"model\\\":\\\"\\\n PM883 960Gb\\\",\\\"name\\\":\\\"ds1621plus usb1\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds1621plus_usb1_power_on_hours/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Power On Hours\\\", \\n \\\"state_topic\\\":\\\"1621/usb1/power_on_hours\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds1621plus_usb1_power_on_hours\\\",\\n \\\"unit_of_measurement\\\"\\\n :\\\"hr\\\",\\n \\\"entity_category\\\": \\\"diagnostic\\\",\\n \\\"value_template\\\":\\\"\\\n {{ '{{' }} ( value|int(0) ) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"1621_usb1\\\"],\\\"manufacturer\\\":\\\"Samsung\\\",\\\"model\\\":\\\"PM883 960Gb\\\",\\\"\\\n name\\\":\\\"ds1621plus usb1\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds1621plus_usb1_temperature/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Temperature\\\", \\n \\\"state_topic\\\":\\\"1621/usb1/temperature\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds1621plus_usb1_temperature\\\",\\n \\\"unit_of_measurement\\\"\\\n :\\\"°C\\\",\\n \\\"device_class\\\":\\\"temperature\\\",\\n \\\"entity_category\\\": \\\"diagnostic\\\"\\\n ,\\n \\\"value_template\\\":\\\"{{ '{{' }} ( value|int(0) ) {{ '}}' }}\\\", \\n \\\"\\\n device\\\":{\\\"identifiers\\\":[\\\"1621_usb1\\\"],\\\"manufacturer\\\":\\\"Samsung\\\",\\\"\\\n model\\\":\\\"PM883 960Gb\\\",\\\"name\\\":\\\"ds1621plus usb1\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/binary_sensor/kiosk_motion/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Motion\\\", \\n \\\"state_topic\\\":\\\"xiaoxin/event\\\",\\n\\\n \\ \\\"unique_id\\\":\\\"kisok_motion\\\",\\n \\\"device_class\\\":\\\"motion\\\",\\n \\\"payload_on\\\"\\\n :\\\"onMotion\\\",\\n \\\"payload_off\\\":\\\" \\\",\\n \\\"off_delay\\\": \\\"2\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value_json.event {{ '}}' }}\\\",\\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"Xiaoxin Kiosk\\\"],\\\"manufacturer\\\":\\\"Fully Kiosk Broser\\\",\\\"name\\\":\\\"Xiaoxin\\\n \\ Kiosk\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds920plus_nvme0_data_units_read/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Data Units Read\\\", \\n \\\"state_topic\\\":\\\"920/nvme0/read\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds920plus_nvme0_data_units_read\\\",\\n \\\"icon\\\":\\\"mdi:alpha-r-circle\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Gb\\\",\\n \\\"entity_category\\\": \\\"diagnostic\\\"\\\n ,\\n \\\"value_template\\\":\\\"{{ '{{' }} ( value|int(0) * 512 / 1024 / 1024 /\\\n \\ 1024 ) | round(2) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"920_nvme0\\\"\\\n ],\\\"manufacturer\\\":\\\"A-Data\\\",\\\"model\\\":\\\"SX6000 Lite 256Gb\\\",\\\"name\\\":\\\"\\\n ds920plus nvme0\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds920plus_nvme0_data_units_written/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Data Units Written\\\", \\n \\\"state_topic\\\":\\\"920/nvme0/write\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds920plus_nvme0_data_units_written\\\",\\n \\\"icon\\\":\\\"\\\n mdi:alpha-w-circle\\\",\\n \\\"unit_of_measurement\\\":\\\"Gb\\\",\\n \\\"entity_category\\\"\\\n : \\\"diagnostic\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} ( value|int(0) * 512\\\n \\ / 1024 / 1024 / 1024 ) | round(2) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"920_nvme0\\\"],\\\"manufacturer\\\":\\\"A-Data\\\",\\\"model\\\":\\\"SX6000 Lite 256Gb\\\"\\\n ,\\\"name\\\":\\\"ds920plus nvme0\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds920plus_nvme0_power_on_hours/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Power On Hours\\\", \\n \\\"state_topic\\\":\\\"920/nvme0/power_on_hours\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds920plus_nvme0_power_on_hours\\\",\\n \\\"icon\\\":\\\"mdi:calendar-clock\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"hr\\\",\\n \\\"entity_category\\\": \\\"diagnostic\\\"\\\n ,\\n \\\"value_template\\\":\\\"{{ '{{' }} ( value|int(0) ) {{ '}}' }}\\\", \\n \\\"\\\n device\\\":{\\\"identifiers\\\":[\\\"920_nvme0\\\"],\\\"manufacturer\\\":\\\"A-Data\\\",\\\"model\\\"\\\n :\\\"SX6000 Lite 256Gb\\\",\\\"name\\\":\\\"ds920plus nvme0\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds920plus_nvme0_wear_leveling_count/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Wear Leveling Count\\\", \\n \\\"state_topic\\\":\\\"920/nvme0/percent\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds920plus_nvme0_wear_leveling_count\\\",\\n \\\"icon\\\":\\\"\\\n mdi:percent-circle\\\",\\n \\\"unit_of_measurement\\\":\\\"%\\\",\\n \\\"entity_category\\\"\\\n : \\\"diagnostic\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} ( value|int(0) ) {{ '}}'\\\n \\ }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"920_nvme0\\\"],\\\"manufacturer\\\":\\\"\\\n A-Data\\\",\\\"model\\\":\\\"SX6000 Lite 256Gb\\\",\\\"name\\\":\\\"ds920plus nvme0\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds920plus_nvme1_data_units_read/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Data Units Read\\\", \\n \\\"state_topic\\\":\\\"920/nvme1/read\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds920plus_nvme1_data_units_read\\\",\\n \\\"icon\\\":\\\"mdi:alpha-r-circle\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Gb\\\",\\n \\\"entity_category\\\": \\\"diagnostic\\\"\\\n ,\\n \\\"value_template\\\":\\\"{{ '{{' }} ( value|int(0) * 512 / 1024 / 1024 /\\\n \\ 1024 ) | round(2) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"920_nvme1\\\"\\\n ],\\\"manufacturer\\\":\\\"A-Data\\\",\\\"model\\\":\\\"SX6000 Lite 256Gb\\\",\\\"name\\\":\\\"\\\n ds920plus nvme1\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds920plus_nvme1_data_units_written/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Data Units Written\\\", \\n \\\"state_topic\\\":\\\"920/nvme1/write\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds920plus_nvme1_data_units_written\\\",\\n \\\"icon\\\":\\\"\\\n mdi:alpha-w-circle\\\",\\n \\\"unit_of_measurement\\\":\\\"Gb\\\",\\n \\\"entity_category\\\"\\\n : \\\"diagnostic\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} ( value|int(0) * 512\\\n \\ / 1024 / 1024 / 1024 ) | round(2) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"920_nvme1\\\"],\\\"manufacturer\\\":\\\"A-Data\\\",\\\"model\\\":\\\"SX6000 Lite 256Gb\\\"\\\n ,\\\"name\\\":\\\"ds920plus nvme1\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds920plus_nvme1_power_on_hours/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Power On Hours\\\", \\n \\\"state_topic\\\":\\\"920/nvme1/power_on_hours\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds920plus_nvme1_power_on_hours\\\",\\n \\\"icon\\\":\\\"mdi:calendar-clock\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"hr\\\",\\n \\\"entity_category\\\": \\\"diagnostic\\\"\\\n ,\\n \\\"value_template\\\":\\\"{{ '{{' }} ( value|int(0) ) {{ '}}' }}\\\", \\n \\\"\\\n device\\\":{\\\"identifiers\\\":[\\\"920_nvme1\\\"],\\\"manufacturer\\\":\\\"A-Data\\\",\\\"model\\\"\\\n :\\\"SX6000 Lite 256Gb\\\",\\\"name\\\":\\\"ds920plus nvme1\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ds920plus_nvme1_wear_leveling_count/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Wear Leveling Count\\\", \\n \\\"state_topic\\\":\\\"920/nvme1/percent\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ds920plus_nvme1_wear_leveling_count\\\",\\n \\\"icon\\\":\\\"\\\n mdi:percent-circle\\\",\\n \\\"unit_of_measurement\\\":\\\"%\\\",\\n \\\"entity_category\\\"\\\n : \\\"diagnostic\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} ( value|int(0) ) {{ '}}'\\\n \\ }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"920_nvme1\\\"],\\\"manufacturer\\\":\\\"\\\n A-Data\\\",\\\"model\\\":\\\"SX6000 Lite 256Gb\\\",\\\"name\\\":\\\"ds920plus nvme1\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pikvm_telemetry_last_update/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Telemetry Last Update\\\", \\n \\\"state_topic\\\":\\\"pikvm/last_update\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:calendar\\\", \\n \\\"unique_id\\\":\\\"pikvm_telemetry_last_update\\\"\\\n ,\\n \\\"entity_category\\\": \\\"diagnostic\\\",\\n \\\"value_template\\\":\\\"{{ '{{'\\\n \\ }} value {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"pikvm\\\"],\\\"manufacturer\\\"\\\n :\\\"BLICUBE\\\",\\\"model\\\":\\\"PIKVM V3 HAT\\\",\\\"name\\\":\\\"PIKVM\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pikvm_uptime/config\n retain: true\n payload: \"{\\n \\\"name\\\":\\\"Uptime\\\",\\n \\\"state_topic\\\":\\\"pikvm/system_uptime\\\"\\\n ,\\n \\\"icon\\\":\\\"mdi:clock-digital\\\",\\n \\\"unit_of_measurement\\\": \\\"h\\\",\\n\\\n \\ \\\"unique_id\\\":\\\"blikvm_uptime\\\",\\n \\\"entity_category\\\": \\\"diagnostic\\\"\\\n ,\\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} ((value\\\n \\ | float(0))/3600) | round(2, 'common') {{ '}}' }}\\\",\\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"pikvm\\\"],\\\"manufacturer\\\":\\\"BLICUBE\\\",\\\"model\\\":\\\"BLIKVM V3 HAT\\\",\\\"name\\\"\\\n :\\\"PIKVM\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pikvm_cpu_load/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"CPU Load\\\", \\n \\\"state_topic\\\":\\\"pikvm/psmqtt/cpu_percent\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:cpu-64-bit\\\", \\n \\\"unit_of_measurement\\\": \\\"%\\\",\\n\\\n \\ \\\"unique_id\\\":\\\"pikvm_cpu_load\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | float(0) | round(0, 'common') {{ '}}' }}\\\", \\n \\\"device\\\"\\\n :{\\\"identifiers\\\":[\\\"pikvm\\\"],\\\"manufacturer\\\":\\\"BLICUBE\\\",\\\"model\\\":\\\"PIKVM\\\n \\ V3 HAT\\\",\\\"name\\\":\\\"PIKVM\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pikvm_cpu_temp/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"CPU Temp\\\", \\n \\\"state_topic\\\":\\\"pikvm/psmqtt/sensors_temperatures/cpu_thermal\\\"\\\n , \\n \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"device_class\\\":\\\"temperature\\\"\\\n ,\\n \\\"unique_id\\\":\\\"pikvm_cpu_temp\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"\\\n value_template\\\":\\\"{{ '{{' }} value | float(0) | round(1, 'common') {{ '}}'\\\n \\ }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"pikvm\\\"],\\\"manufacturer\\\":\\\"BLICUBE\\\"\\\n ,\\\"model\\\":\\\"PIKVM V3 HAT\\\",\\\"name\\\":\\\"PIKVM\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pikvm2w_telemetry_last_update/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Telemetry Last Update\\\", \\n \\\"state_topic\\\":\\\"pikvm2w/last_update\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:calendar\\\", \\n \\\"unique_id\\\":\\\"pikvm2w_telemetry_last_update\\\"\\\n ,\\n \\\"entity_category\\\": \\\"diagnostic\\\",\\n \\\"value_template\\\":\\\"{{ '{{'\\\n \\ }} value {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"pikvm2w\\\"],\\\"\\\n manufacturer\\\":\\\"DIY\\\",\\\"model\\\":\\\"PIKVM DIY\\\",\\\"name\\\":\\\"PIKVM 2w\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pikvm2w_uptime/config\n retain: true\n payload: \"{\\n \\\"name\\\":\\\"Uptime\\\",\\n \\\"state_topic\\\":\\\"pikvm2w/system_uptime\\\"\\\n ,\\n \\\"icon\\\":\\\"mdi:clock-digital\\\",\\n \\\"unit_of_measurement\\\": \\\"h\\\",\\n\\\n \\ \\\"unique_id\\\":\\\"pikvm2w_uptime\\\",\\n \\\"entity_category\\\": \\\"diagnostic\\\"\\\n ,\\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} ((value\\\n \\ | float(0))/3600) | round(2, 'common') {{ '}}' }}\\\",\\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"pikvm2w\\\"],\\\"manufacturer\\\":\\\"DIY\\\",\\\"model\\\":\\\"PIKVM DIY\\\",\\\"name\\\":\\\"\\\n PIKVM 2w\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pikvm2w_cpu_load/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"CPU Load\\\", \\n \\\"state_topic\\\":\\\"pikvm2w/psmqtt/cpu_percent\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:cpu-64-bit\\\", \\n \\\"unit_of_measurement\\\": \\\"%\\\",\\n\\\n \\ \\\"unique_id\\\":\\\"pikvm2w_cpu_load\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"\\\n value_template\\\":\\\"{{ '{{' }} value | float(0) | round(0, 'common') {{ '}}'\\\n \\ }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"pikvm2w\\\"],\\\"manufacturer\\\":\\\"\\\n DIY\\\",\\\"model\\\":\\\"PIKVM DIY\\\",\\\"name\\\":\\\"PIKVM 2w\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pikvm2w_cpu_temp/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"CPU Temp\\\", \\n \\\"state_topic\\\":\\\"pikvm2w/psmqtt/sensors_temperatures/cpu_thermal\\\"\\\n , \\n \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"device_class\\\":\\\"temperature\\\"\\\n ,\\n \\\"unique_id\\\":\\\"pikvm2w_cpu_temp\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\n \\ \\\"value_template\\\":\\\"{{ '{{' }} value | float(0) | round(1, 'common') {{\\\n \\ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"pikvm2w\\\"],\\\"manufacturer\\\"\\\n :\\\"DIY\\\",\\\"model\\\":\\\"PIKVM DIY\\\",\\\"name\\\":\\\"PIKVM 2w\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/rpi3_telemetry_last_update/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Telemetry Last Update\\\", \\n \\\"state_topic\\\":\\\"rpi3/last_update\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:calendar\\\", \\n \\\"unique_id\\\":\\\"rpi3_telemetry_last_update\\\"\\\n ,\\n \\\"entity_category\\\": \\\"diagnostic\\\",\\n \\\"value_template\\\":\\\"{{ '{{'\\\n \\ }} value {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"rpi3\\\"],\\\"manufacturer\\\"\\\n :\\\"Raspberry\\\",\\\"model\\\":\\\"3 B+\\\",\\\"name\\\":\\\"RPI3\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/rpi3_uptime/config\n retain: true\n payload: \"{\\n \\\"name\\\":\\\"Uptime\\\",\\n \\\"state_topic\\\":\\\"rpi3/system_uptime\\\"\\\n ,\\n \\\"icon\\\":\\\"mdi:clock-digital\\\",\\n \\\"unit_of_measurement\\\": \\\"h\\\",\\n\\\n \\ \\\"unique_id\\\":\\\"rpi3_uptime\\\",\\n \\\"entity_category\\\": \\\"diagnostic\\\",\\n\\\n \\ \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} ((value |\\\n \\ float(0))/3600) | round(2, 'common') {{ '}}' }}\\\",\\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"rpi3\\\"],\\\"manufacturer\\\":\\\"Raspberry\\\",\\\"model\\\":\\\"3 B+\\\",\\\"name\\\":\\\"\\\n RPI3\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/rpi3_cpu_load/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"CPU Load\\\", \\n \\\"state_topic\\\":\\\"rpi3/psmqtt/cpu_percent\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:cpu-64-bit\\\", \\n \\\"unit_of_measurement\\\": \\\"%\\\",\\n\\\n \\ \\\"unique_id\\\":\\\"rpi3_cpu_load\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | float(0) | round(0, 'common') {{ '}}' }}\\\", \\n \\\"device\\\"\\\n :{\\\"identifiers\\\":[\\\"rpi3\\\"],\\\"manufacturer\\\":\\\"Raspberry\\\",\\\"model\\\":\\\"3\\\n \\ B+\\\",\\\"name\\\":\\\"RPI3\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/rpi3_cpu_temp/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"CPU Temp\\\", \\n \\\"state_topic\\\":\\\"rpi3/psmqtt/sensors_temperatures/cpu_thermal\\\"\\\n , \\n \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"device_class\\\":\\\"temperature\\\"\\\n ,\\n \\\"unique_id\\\":\\\"rpi3_cpu_temp\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"\\\n value_template\\\":\\\"{{ '{{' }} value | float(0) | round(1, 'common') {{ '}}'\\\n \\ }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"rpi3\\\"],\\\"manufacturer\\\":\\\"Raspberry\\\"\\\n ,\\\"model\\\":\\\"3 B+\\\",\\\"name\\\":\\\"RPI3\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/rpi3_memory_used/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Memory Used\\\", \\n \\\"state_topic\\\":\\\"rpi3/psmqtt/virtual_memory/percent\\\"\\\n ,\\n \\\"value_template\\\":\\\"{{ '{{' }} value | float(100) | round(1, 'common')\\\n \\ {{ '}}' }}\\\", \\n \\\"unique_id\\\":\\\"rpi3_memory_used\\\",\\n \\\"unit_of_measurement\\\"\\\n :\\\"%\\\",\\n \\\"icon\\\":\\\"mdi:memory\\\",\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"rpi3\\\"\\\n ],\\\"manufacturer\\\":\\\"Raspberry\\\",\\\"model\\\":\\\"3 B+\\\",\\\"name\\\":\\\"RPI3\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_telemetry_last_update/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Telemetry Last Update\\\", \\n \\\"state_topic\\\":\\\"ms01a/last_update\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:calendar\\\", \\n \\\"unique_id\\\":\\\"ms01a_telemetry_last_update\\\"\\\n ,\\n \\\"entity_category\\\": \\\"diagnostic\\\",\\n \\\"value_template\\\":\\\"{{ '{{'\\\n \\ }} value {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01a\\\"],\\\"manufacturer\\\"\\\n :\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_uptime/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Uptime\\\", \\n \\\"state_topic\\\":\\\"ms01a/system_uptime\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:clock-digital\\\", \\n \\\"unit_of_measurement\\\": \\\"m\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ms01a_uptime\\\", \\n \\\"entity_category\\\": \\\"diagnostic\\\"\\\n ,\\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} ((value\\\n \\ | float(0))/60) | round(2, 'common') {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"ms01a\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"\\\n ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_iowait/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"IoWait\\\", \\n \\\"state_topic\\\":\\\"ms01a/kernel_stat\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:speedometer-medium\\\", \\n \\\"unit_of_measurement\\\": \\\"\\\n %\\\",\\n \\\"unique_id\\\":\\\"ms01a_iowait\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"\\\n value_template\\\":\\\"{{ '{{' }} ((value_json.sysstat.hosts[0].statistics[0]['avg-cpu'].iowait)\\\n \\ | float(0)) | round(2, 'common') {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"ms01a\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"\\\n ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_nvme0_usage/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 Usage\\\", \\n \\\"state_topic\\\":\\\"ms01a/disk_usage/nvme0\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:chip\\\", \\n \\\"unit_of_measurement\\\": \\\"%\\\",\\n \\\"unique_id\\\"\\\n :\\\"ms01a_nvme0_usage\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | float(0) | round(0, 'common') {{ '}}' }}\\\", \\n \\\"device\\\"\\\n :{\\\"identifiers\\\":[\\\"ms01a\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"\\\n MS01\\\",\\\"name\\\":\\\"ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_nvme0_temp/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 Temp\\\", \\n \\\"state_topic\\\":\\\"ms01a/disk_temp/nvme0\\\"\\\n , \\n \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"device_class\\\":\\\"temperature\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ms01a_nvme0_temp\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\n \\ \\\"value_template\\\":\\\"{{ '{{' }} value | float(0) | round(0, 'common') {{\\\n \\ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01a\\\"],\\\"manufacturer\\\"\\\n :\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_nvme0_tb_written/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 TB Written\\\", \\n \\\"state_topic\\\":\\\"ms01a/ssd_smart/nvme0_lba_written\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Tb\\\",\\n \\\"icon\\\":\\\"mdi:chip\\\",\\n \\\"unique_id\\\"\\\n :\\\"ms01a_nvme0_tb_written\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} ( value | float(0) * 512000 / 1024 / 1024 / 1024 / 1024) |round(1,\\\n \\ 'common') {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01a\\\"],\\\"manufacturer\\\"\\\n :\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_nvme0_power_on_hours/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 Power On Hours\\\", \\n \\\"state_topic\\\":\\\"ms01a/ssd_smart/nvme0_power_on_hours\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"h\\\",\\n \\\"icon\\\":\\\"mdi:clock-alert-outline\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ms01a_nvme0_power_on_hours\\\", \\n \\\"expire_after\\\":\\\"\\\n 150\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n\\\n \\ \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01a\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\"\\\n ,\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_nvme0_life_left_smart/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 Life Left Smart\\\", \\n \\\"state_topic\\\":\\\"ms01a/ssd_smart/nvme0_life_left\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"%\\\",\\n \\\"icon\\\":\\\"mdi:calendar-heart\\\",\\n\\\n \\ \\\"unique_id\\\":\\\"ms01a_nvme0_life_left_smart\\\", \\n \\\"expire_after\\\":\\\"\\\n 150\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n\\\n \\ \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01a\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\"\\\n ,\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_nvme0_gb_write/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 Session Write\\\", \\n \\\"state_topic\\\":\\\"ms01a/disk_stat/nvme0_gb_write\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Gb\\\",\\n \\\"icon\\\":\\\"mdi:alpha-w-box\\\",\\n \\\"\\\n unique_id\\\":\\\"ms01a_nvme0_session_write\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n\\\n \\ \\\"value_template\\\":\\\"{{ '{{' }} value| float(0)| round(1, 'common') {{\\\n \\ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01a\\\"],\\\"manufacturer\\\"\\\n :\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_nvme0_gb_read/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 Session Read\\\", \\n \\\"state_topic\\\":\\\"ms01a/disk_stat/nvme0_gb_read\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Gb\\\",\\n \\\"icon\\\":\\\"mdi:alpha-r-box\\\",\\n \\\"\\\n unique_id\\\":\\\"ms01a_nvme0_session_read\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n\\\n \\ \\\"value_template\\\":\\\"{{ '{{' }} value| float(0)| round(1, 'common') {{\\\n \\ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01a\\\"],\\\"manufacturer\\\"\\\n :\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_nvme1_usage/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME1 Usage\\\", \\n \\\"state_topic\\\":\\\"ms01a/disk_usage/nvme1\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:chip\\\", \\n \\\"unit_of_measurement\\\": \\\"%\\\",\\n \\\"unique_id\\\"\\\n :\\\"ms01a_nvme1_usage\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | float(0) | round(0, 'common') {{ '}}' }}\\\", \\n \\\"device\\\"\\\n :{\\\"identifiers\\\":[\\\"ms01a\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"\\\n MS01\\\",\\\"name\\\":\\\"ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_nvme1_temp/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME1 Temp\\\", \\n \\\"state_topic\\\":\\\"ms01a/disk_temp/nvme1\\\"\\\n , \\n \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"device_class\\\":\\\"temperature\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ms01a_nvme1_temp\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\n \\ \\\"value_template\\\":\\\"{{ '{{' }} value | float(0) | round(0, 'common') {{\\\n \\ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01a\\\"],\\\"manufacturer\\\"\\\n :\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_nvme1_tb_written/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME1 TB Written\\\", \\n \\\"state_topic\\\":\\\"ms01a/ssd_smart/nvme1_lba_written\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Tb\\\",\\n \\\"icon\\\":\\\"mdi:chip\\\",\\n \\\"unique_id\\\"\\\n :\\\"ms01a_nvme1_tb_written\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} ( value | float(0) * 512000 / 1024 / 1024 / 1024 / 1024) |round(1,\\\n \\ 'common') {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01a\\\"],\\\"manufacturer\\\"\\\n :\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_nvme1_power_on_hours/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME1 Power On Hours\\\", \\n \\\"state_topic\\\":\\\"ms01a/ssd_smart/nvme1_power_on_hours\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"h\\\",\\n \\\"icon\\\":\\\"mdi:clock-alert-outline\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ms01a_nvme1_power_on_hours\\\", \\n \\\"expire_after\\\":\\\"\\\n 150\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n\\\n \\ \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01a\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\"\\\n ,\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_nvme1_life_left_smart/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME1 Life Left Smart\\\", \\n \\\"state_topic\\\":\\\"ms01a/ssd_smart/nvme1_life_left\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"%\\\",\\n \\\"icon\\\":\\\"mdi:calendar-heart\\\",\\n\\\n \\ \\\"unique_id\\\":\\\"ms01a_nvme1_life_left_smart\\\", \\n \\\"expire_after\\\":\\\"\\\n 150\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n\\\n \\ \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01a\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\"\\\n ,\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_nvme1_gb_write/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME1 Session Write\\\", \\n \\\"state_topic\\\":\\\"ms01a/disk_stat/nvme1_gb_write\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Gb\\\",\\n \\\"icon\\\":\\\"mdi:alpha-w-box\\\",\\n \\\"\\\n unique_id\\\":\\\"ms01a_nvme1_session_write\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n\\\n \\ \\\"value_template\\\":\\\"{{ '{{' }} value| float(0)| round(1, 'common') {{\\\n \\ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01a\\\"],\\\"manufacturer\\\"\\\n :\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_nvme1_gb_read/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME1 Session Read\\\", \\n \\\"state_topic\\\":\\\"ms01a/disk_stat/nvme1_gb_read\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Gb\\\",\\n \\\"icon\\\":\\\"mdi:alpha-r-box\\\",\\n \\\"\\\n unique_id\\\":\\\"ms01a_nvme1_session_read\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n\\\n \\ \\\"value_template\\\":\\\"{{ '{{' }} value| float(0)| round(1, 'common') {{\\\n \\ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01a\\\"],\\\"manufacturer\\\"\\\n :\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_cpu_temp/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"CPU Temp\\\", \\n \\\"state_topic\\\":\\\"ms01a/psmqtt/sensors_temperatures/coretemp\\\"\\\n , \\n \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"device_class\\\":\\\"temperature\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ms01a_cpu_temp\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"\\\n value_template\\\":\\\"{{ '{{' }} value_json[0] | float(0) | round(0, 'common')\\\n \\ {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01a\\\"],\\\"manufacturer\\\"\\\n :\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_cpu_load/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"CPU Load\\\", \\n \\\"state_topic\\\":\\\"ms01a/psmqtt/cpu_percent\\\"\\\n , \\n \\\"unit_of_measurement\\\":\\\"%\\\",\\n \\\"unique_id\\\":\\\"ms01a_cpu_load\\\",\\n\\\n \\ \\\"icon\\\":\\\"mdi:cpu-64-bit\\\",\\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | float(0) | round(1, 'common') {{ '}}' }}\\\", \\n \\\"device\\\"\\\n :{\\\"identifiers\\\":[\\\"ms01a\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"\\\n MS01\\\",\\\"name\\\":\\\"ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_memory_used/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Memory Used\\\", \\n \\\"state_topic\\\":\\\"ms01a/psmqtt/virtual_memory/percent\\\"\\\n ,\\n \\\"value_template\\\":\\\"{{ '{{' }} value | float(100) | round(1, 'common')\\\n \\ {{ '}}' }}\\\", \\n \\\"unique_id\\\":\\\"ms01a_memory_used\\\",\\n \\\"unit_of_measurement\\\"\\\n :\\\"%\\\",\\n \\\"icon\\\":\\\"mdi:memory\\\",\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01a\\\"\\\n ],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01a\\\"}\\n\\\n }\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_enp88s0_speed/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"enp88s0 Speed\\\", \\n \\\"state_topic\\\":\\\"ms01a/net/enp88s0\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"MB/s\\\",\\n \\\"icon\\\":\\\"mdi:speedometer\\\",\\n\\\n \\ \\\"device_class\\\":\\\"data_rate\\\",\\n \\\"force_update\\\": true,\\n \\\"unique_id\\\"\\\n :\\\"ms01a_enp88s0_speed\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"ms01a\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"\\\n ms01a\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_enp90s0_speed/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"enp90s0 Speed\\\", \\n \\\"state_topic\\\":\\\"ms01a/net/enp90s0\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"MB/s\\\",\\n \\\"icon\\\":\\\"mdi:speedometer\\\",\\n\\\n \\ \\\"device_class\\\":\\\"data_rate\\\",\\n \\\"force_update\\\": true,\\n \\\"unique_id\\\"\\\n :\\\"ms01a_enp90s0_speed\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"ms01a\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"\\\n ms01a\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_enp3s0f0np0_speed/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"enp3s0f0np0 Speed\\\", \\n \\\"state_topic\\\":\\\"ms01a/net/enp3s0f0np0\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"MB/s\\\",\\n \\\"icon\\\":\\\"mdi:speedometer\\\",\\n\\\n \\ \\\"device_class\\\":\\\"data_rate\\\",\\n \\\"force_update\\\": true,\\n \\\"unique_id\\\"\\\n :\\\"ms01a_enp3s0f0np0_speed\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"ms01a\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"\\\n ms01a\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_enp3s0f1np1_speed/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"enp3s0f1np1 Speed\\\", \\n \\\"state_topic\\\":\\\"ms01a/net/enp3s0f1np1\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"MB/s\\\",\\n \\\"icon\\\":\\\"mdi:speedometer\\\",\\n\\\n \\ \\\"device_class\\\":\\\"data_rate\\\",\\n \\\"force_update\\\": true,\\n \\\"unique_id\\\"\\\n :\\\"ms01a_enp3s0f1np1_speed\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"ms01a\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"\\\n ms01a\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_enp1s0f0_speed/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"enp1s0f0 Speed\\\", \\n \\\"state_topic\\\":\\\"ms01a/net/enp1s0f0\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"MB/s\\\",\\n \\\"icon\\\":\\\"mdi:speedometer\\\",\\n\\\n \\ \\\"device_class\\\":\\\"data_rate\\\",\\n \\\"force_update\\\": true,\\n \\\"unique_id\\\"\\\n :\\\"ms01a_enp1s0f0_speed\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"ms01a\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"\\\n ms01a\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_enp1s0f1_speed/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"enp1s0f1 Speed\\\", \\n \\\"state_topic\\\":\\\"ms01a/net/enp1s0f1\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"MB/s\\\",\\n \\\"icon\\\":\\\"mdi:speedometer\\\",\\n\\\n \\ \\\"device_class\\\":\\\"data_rate\\\",\\n \\\"force_update\\\": true,\\n \\\"unique_id\\\"\\\n :\\\"ms01a_enp1s0f1_speed\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"ms01a\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"\\\n ms01a\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_enp1s0f2_speed/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"enp1s0f2 Speed\\\", \\n \\\"state_topic\\\":\\\"ms01a/net/enp1s0f2\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"MB/s\\\",\\n \\\"icon\\\":\\\"mdi:speedometer\\\",\\n\\\n \\ \\\"device_class\\\":\\\"data_rate\\\",\\n \\\"force_update\\\": true,\\n \\\"unique_id\\\"\\\n :\\\"ms01a_enp1s0f2_speed\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"ms01a\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"\\\n ms01a\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_enp1s0f3_speed/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"enp1s0f3 Speed\\\", \\n \\\"state_topic\\\":\\\"ms01a/net/enp1s0f3\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"MB/s\\\",\\n \\\"icon\\\":\\\"mdi:speedometer\\\",\\n\\\n \\ \\\"device_class\\\":\\\"data_rate\\\",\\n \\\"force_update\\\": true,\\n \\\"unique_id\\\"\\\n :\\\"ms01a_enp1s0f3_speed\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"ms01a\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"\\\n ms01a\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_fan1/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Fan 1\\\", \\n \\\"state_topic\\\":\\\"ms01a/psmqtt/sensors_fans/nct6798\\\"\\\n , \\n \\\"unit_of_measurement\\\":\\\"rpm\\\",\\n \\\"unique_id\\\":\\\"ms01a_fan_1\\\", \\n\\\n \\ \\\"icon\\\":\\\"mdi:fan\\\",\\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value_json[0] | float(0) | round(0, 'common') {{ '}}' }}\\\",\\\n \\ \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01a\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\"\\\n ,\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01a_fan2/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Fan 2\\\", \\n \\\"state_topic\\\":\\\"ms01a/psmqtt/sensors_fans/nct6798\\\"\\\n , \\n \\\"unit_of_measurement\\\":\\\"rpm\\\",\\n \\\"unique_id\\\":\\\"ms01a_fan_2\\\", \\n\\\n \\ \\\"icon\\\":\\\"mdi:fan\\\",\\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value_json[1] | float(0) | round(0, 'common') {{ '}}' }}\\\",\\\n \\ \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01a\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\"\\\n ,\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01a\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_telemetry_last_update/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Telemetry Last Update\\\", \\n \\\"state_topic\\\":\\\"ms01b/last_update\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:calendar\\\", \\n \\\"unique_id\\\":\\\"ms01b_telemetry_last_update\\\"\\\n ,\\n \\\"entity_category\\\": \\\"diagnostic\\\",\\n \\\"value_template\\\":\\\"{{ '{{'\\\n \\ }} value {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01b\\\"],\\\"manufacturer\\\"\\\n :\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_uptime/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Uptime\\\", \\n \\\"state_topic\\\":\\\"ms01b/system_uptime\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:clock-digital\\\", \\n \\\"unit_of_measurement\\\": \\\"m\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ms01b_uptime\\\", \\n \\\"entity_category\\\": \\\"diagnostic\\\"\\\n ,\\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} ((value\\\n \\ | float(0))/60) | round(2, 'common') {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"ms01b\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"\\\n ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_iowait/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"IoWait\\\", \\n \\\"state_topic\\\":\\\"ms01b/kernel_stat\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:speedometer-medium\\\", \\n \\\"unit_of_measurement\\\": \\\"\\\n %\\\",\\n \\\"unique_id\\\":\\\"ms01b_iowait\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"\\\n value_template\\\":\\\"{{ '{{' }} ((value_json.sysstat.hosts[0].statistics[0]['avg-cpu'].iowait)\\\n \\ | float(0)) | round(2, 'common') {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"ms01b\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"\\\n ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_nvme0_usage/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 Usage\\\", \\n \\\"state_topic\\\":\\\"ms01b/disk_usage/nvme0\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:chip\\\", \\n \\\"unit_of_measurement\\\": \\\"%\\\",\\n \\\"unique_id\\\"\\\n :\\\"ms01b_nvme0_usage\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | float(0) | round(0, 'common') {{ '}}' }}\\\", \\n \\\"device\\\"\\\n :{\\\"identifiers\\\":[\\\"ms01b\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"\\\n MS01\\\",\\\"name\\\":\\\"ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_nvme0_temp/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 Temp\\\", \\n \\\"state_topic\\\":\\\"ms01b/disk_temp/nvme0\\\"\\\n , \\n \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"device_class\\\":\\\"temperature\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ms01b_nvme0_temp\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\n \\ \\\"value_template\\\":\\\"{{ '{{' }} value | float(0) | round(0, 'common') {{\\\n \\ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01b\\\"],\\\"manufacturer\\\"\\\n :\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_nvme0_tb_written/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 TB Written\\\", \\n \\\"state_topic\\\":\\\"ms01b/ssd_smart/nvme0_lba_written\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Tb\\\",\\n \\\"icon\\\":\\\"mdi:chip\\\",\\n \\\"unique_id\\\"\\\n :\\\"ms01b_nvme0_tb_written\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} ( value | float(0) * 512000 / 1024 / 1024 / 1024 / 1024) |round(1,\\\n \\ 'common') {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01b\\\"],\\\"manufacturer\\\"\\\n :\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_nvme0_power_on_hours/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 Power On Hours\\\", \\n \\\"state_topic\\\":\\\"ms01b/ssd_smart/nvme0_power_on_hours\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"h\\\",\\n \\\"icon\\\":\\\"mdi:clock-alert-outline\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ms01b_nvme0_power_on_hours\\\", \\n \\\"expire_after\\\":\\\"\\\n 150\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n\\\n \\ \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01b\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\"\\\n ,\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_nvme0_life_left_smart/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 Life Left Smart\\\", \\n \\\"state_topic\\\":\\\"ms01b/ssd_smart/nvme0_life_left\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"%\\\",\\n \\\"icon\\\":\\\"mdi:calendar-heart\\\",\\n\\\n \\ \\\"unique_id\\\":\\\"ms01b_nvme0_life_left_smart\\\", \\n \\\"expire_after\\\":\\\"\\\n 150\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n\\\n \\ \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01b\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\"\\\n ,\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_nvme0_gb_write/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 Session Write\\\", \\n \\\"state_topic\\\":\\\"ms01b/disk_stat/nvme0_gb_write\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Gb\\\",\\n \\\"icon\\\":\\\"mdi:alpha-w-box\\\",\\n \\\"\\\n unique_id\\\":\\\"ms01b_nvme0_session_write\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n\\\n \\ \\\"value_template\\\":\\\"{{ '{{' }} value| float(0)| round(1, 'common') {{\\\n \\ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01b\\\"],\\\"manufacturer\\\"\\\n :\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_nvme0_gb_read/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 Session Read\\\", \\n \\\"state_topic\\\":\\\"ms01b/disk_stat/nvme0_gb_read\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Gb\\\",\\n \\\"icon\\\":\\\"mdi:alpha-r-box\\\",\\n \\\"\\\n unique_id\\\":\\\"ms01b_nvme0_session_read\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n\\\n \\ \\\"value_template\\\":\\\"{{ '{{' }} value| float(0)| round(1, 'common') {{\\\n \\ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01b\\\"],\\\"manufacturer\\\"\\\n :\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_nvme1_usage/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME1 Usage\\\", \\n \\\"state_topic\\\":\\\"ms01b/disk_usage/nvme1\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:chip\\\", \\n \\\"unit_of_measurement\\\": \\\"%\\\",\\n \\\"unique_id\\\"\\\n :\\\"ms01b_nvme1_usage\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | float(0) | round(0, 'common') {{ '}}' }}\\\", \\n \\\"device\\\"\\\n :{\\\"identifiers\\\":[\\\"ms01b\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"\\\n MS01\\\",\\\"name\\\":\\\"ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_nvme1_temp/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME1 Temp\\\", \\n \\\"state_topic\\\":\\\"ms01b/disk_temp/nvme1\\\"\\\n , \\n \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"device_class\\\":\\\"temperature\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ms01b_nvme1_temp\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\n \\ \\\"value_template\\\":\\\"{{ '{{' }} value | float(0) | round(0, 'common') {{\\\n \\ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01b\\\"],\\\"manufacturer\\\"\\\n :\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_nvme1_tb_written/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME1 TB Written\\\", \\n \\\"state_topic\\\":\\\"ms01b/ssd_smart/nvme1_lba_written\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Tb\\\",\\n \\\"icon\\\":\\\"mdi:chip\\\",\\n \\\"unique_id\\\"\\\n :\\\"ms01b_nvme1_tb_written\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} ( value | float(0) * 512000 / 1024 / 1024 / 1024 / 1024) |round(1,\\\n \\ 'common') {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01b\\\"],\\\"manufacturer\\\"\\\n :\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_nvme1_power_on_hours/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME1 Power On Hours\\\", \\n \\\"state_topic\\\":\\\"ms01b/ssd_smart/nvme1_power_on_hours\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"h\\\",\\n \\\"icon\\\":\\\"mdi:clock-alert-outline\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ms01b_nvme1_power_on_hours\\\", \\n \\\"expire_after\\\":\\\"\\\n 150\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n\\\n \\ \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01b\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\"\\\n ,\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_nvme1_life_left_smart/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME1 Life Left Smart\\\", \\n \\\"state_topic\\\":\\\"ms01b/ssd_smart/nvme1_life_left\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"%\\\",\\n \\\"icon\\\":\\\"mdi:calendar-heart\\\",\\n\\\n \\ \\\"unique_id\\\":\\\"ms01b_nvme1_life_left_smart\\\", \\n \\\"expire_after\\\":\\\"\\\n 150\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n\\\n \\ \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01b\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\"\\\n ,\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_nvme1_gb_write/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME1 Session Write\\\", \\n \\\"state_topic\\\":\\\"ms01b/disk_stat/nvme1_gb_write\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Gb\\\",\\n \\\"icon\\\":\\\"mdi:alpha-w-box\\\",\\n \\\"\\\n unique_id\\\":\\\"ms01b_nvme1_session_write\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n\\\n \\ \\\"value_template\\\":\\\"{{ '{{' }} value| float(0)| round(1, 'common') {{\\\n \\ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01b\\\"],\\\"manufacturer\\\"\\\n :\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_nvme1_gb_read/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME1 Session Read\\\", \\n \\\"state_topic\\\":\\\"ms01b/disk_stat/nvme1_gb_read\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Gb\\\",\\n \\\"icon\\\":\\\"mdi:alpha-r-box\\\",\\n \\\"\\\n unique_id\\\":\\\"ms01b_nvme1_session_read\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n\\\n \\ \\\"value_template\\\":\\\"{{ '{{' }} value| float(0)| round(1, 'common') {{\\\n \\ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01b\\\"],\\\"manufacturer\\\"\\\n :\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_cpu_temp/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"CPU Temp\\\", \\n \\\"state_topic\\\":\\\"ms01b/psmqtt/sensors_temperatures/coretemp\\\"\\\n , \\n \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"device_class\\\":\\\"temperature\\\"\\\n ,\\n \\\"unique_id\\\":\\\"ms01b_cpu_temp\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"\\\n value_template\\\":\\\"{{ '{{' }} value_json[0] | float(0) | round(0, 'common')\\\n \\ {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01b\\\"],\\\"manufacturer\\\"\\\n :\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_cpu_load/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"CPU Load\\\", \\n \\\"state_topic\\\":\\\"ms01b/psmqtt/cpu_percent\\\"\\\n , \\n \\\"unit_of_measurement\\\":\\\"%\\\",\\n \\\"unique_id\\\":\\\"ms01b_cpu_load\\\",\\n\\\n \\ \\\"icon\\\":\\\"mdi:cpu-64-bit\\\",\\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | float(0) | round(1, 'common') {{ '}}' }}\\\", \\n \\\"device\\\"\\\n :{\\\"identifiers\\\":[\\\"ms01b\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"\\\n MS01\\\",\\\"name\\\":\\\"ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_memory_used/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Memory Used\\\", \\n \\\"state_topic\\\":\\\"ms01b/psmqtt/virtual_memory/percent\\\"\\\n ,\\n \\\"value_template\\\":\\\"{{ '{{' }} value | float(100) | round(1, 'common')\\\n \\ {{ '}}' }}\\\", \\n \\\"unique_id\\\":\\\"ms01b_memory_used\\\",\\n \\\"unit_of_measurement\\\"\\\n :\\\"%\\\",\\n \\\"icon\\\":\\\"mdi:memory\\\",\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01b\\\"\\\n ],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01b\\\"}\\n\\\n }\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_enp88s0_speed/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"enp88s0 Speed\\\", \\n \\\"state_topic\\\":\\\"ms01b/net/enp88s0\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"MB/s\\\",\\n \\\"icon\\\":\\\"mdi:speedometer\\\",\\n\\\n \\ \\\"device_class\\\":\\\"data_rate\\\",\\n \\\"force_update\\\": true,\\n \\\"unique_id\\\"\\\n :\\\"ms01b_enp88s0_speed\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"ms01b\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"\\\n ms01b\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_enp90s0_speed/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"enp90s0 Speed\\\", \\n \\\"state_topic\\\":\\\"ms01b/net/enp90s0\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"MB/s\\\",\\n \\\"icon\\\":\\\"mdi:speedometer\\\",\\n\\\n \\ \\\"device_class\\\":\\\"data_rate\\\",\\n \\\"force_update\\\": true,\\n \\\"unique_id\\\"\\\n :\\\"ms01b_enp90s0_speed\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"ms01b\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"\\\n ms01b\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_enp3s0f0np0_speed/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"enp3s0f0np0 Speed\\\", \\n \\\"state_topic\\\":\\\"ms01b/net/enp3s0f0np0\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"MB/s\\\",\\n \\\"icon\\\":\\\"mdi:speedometer\\\",\\n\\\n \\ \\\"device_class\\\":\\\"data_rate\\\",\\n \\\"force_update\\\": true,\\n \\\"unique_id\\\"\\\n :\\\"ms01b_enp3s0f0np0_speed\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"ms01b\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"\\\n ms01b\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_enp3s0f1np1_speed/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"enp3s0f1np1 Speed\\\", \\n \\\"state_topic\\\":\\\"ms01b/net/enp3s0f1np1\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"MB/s\\\",\\n \\\"icon\\\":\\\"mdi:speedometer\\\",\\n\\\n \\ \\\"device_class\\\":\\\"data_rate\\\",\\n \\\"force_update\\\": true,\\n \\\"unique_id\\\"\\\n :\\\"ms01b_enp3s0f1np1_speed\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"ms01b\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"\\\n ms01b\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_enp1s0f0_speed/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"enp1s0f0 Speed\\\", \\n \\\"state_topic\\\":\\\"ms01b/net/enp1s0f0\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"MB/s\\\",\\n \\\"icon\\\":\\\"mdi:speedometer\\\",\\n\\\n \\ \\\"device_class\\\":\\\"data_rate\\\",\\n \\\"force_update\\\": true,\\n \\\"unique_id\\\"\\\n :\\\"ms01b_enp1s0f0_speed\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"ms01b\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"\\\n ms01b\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_enp1s0f1_speed/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"enp1s0f1 Speed\\\", \\n \\\"state_topic\\\":\\\"ms01b/net/enp1s0f1\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"MB/s\\\",\\n \\\"icon\\\":\\\"mdi:speedometer\\\",\\n\\\n \\ \\\"device_class\\\":\\\"data_rate\\\",\\n \\\"force_update\\\": true,\\n \\\"unique_id\\\"\\\n :\\\"ms01b_enp1s0f1_speed\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"ms01b\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"\\\n ms01b\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_enp1s0f2_speed/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"enp1s0f2 Speed\\\", \\n \\\"state_topic\\\":\\\"ms01b/net/enp1s0f2\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"MB/s\\\",\\n \\\"icon\\\":\\\"mdi:speedometer\\\",\\n\\\n \\ \\\"device_class\\\":\\\"data_rate\\\",\\n \\\"force_update\\\": true,\\n \\\"unique_id\\\"\\\n :\\\"ms01b_enp1s0f2_speed\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"ms01b\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"\\\n ms01b\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_enp1s0f3_speed/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"enp1s0f3 Speed\\\", \\n \\\"state_topic\\\":\\\"ms01b/net/enp1s0f3\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"MB/s\\\",\\n \\\"icon\\\":\\\"mdi:speedometer\\\",\\n\\\n \\ \\\"device_class\\\":\\\"data_rate\\\",\\n \\\"force_update\\\": true,\\n \\\"unique_id\\\"\\\n :\\\"ms01b_enp1s0f3_speed\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"ms01b\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\",\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"\\\n ms01b\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_fan1/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Fan 1\\\", \\n \\\"state_topic\\\":\\\"ms01b/psmqtt/sensors_fans/nct6798\\\"\\\n , \\n \\\"unit_of_measurement\\\":\\\"rpm\\\",\\n \\\"unique_id\\\":\\\"ms01b_fan_1\\\", \\n\\\n \\ \\\"icon\\\":\\\"mdi:fan\\\",\\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value_json[0] | float(0) | round(0, 'common') {{ '}}' }}\\\",\\\n \\ \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01b\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\"\\\n ,\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/ms01b_fan2/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Fan 2\\\", \\n \\\"state_topic\\\":\\\"ms01b/psmqtt/sensors_fans/nct6798\\\"\\\n , \\n \\\"unit_of_measurement\\\":\\\"rpm\\\",\\n \\\"unique_id\\\":\\\"ms01b_fan_2\\\", \\n\\\n \\ \\\"icon\\\":\\\"mdi:fan\\\",\\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value_json[1] | float(0) | round(0, 'common') {{ '}}' }}\\\",\\\n \\ \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"ms01b\\\"],\\\"manufacturer\\\":\\\"Minisforum\\\"\\\n ,\\\"model\\\":\\\"MS01\\\",\\\"name\\\":\\\"ms01b\\\"}\\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_telemetry_last_update/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Telemetry Last Update\\\", \\n \\\"state_topic\\\":\\\"pbs100/last_update\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:calendar\\\", \\n \\\"unique_id\\\":\\\"pbs100_telemetry_last_update\\\"\\\n ,\\n \\\"entity_category\\\": \\\"diagnostic\\\",\\n \\\"value_template\\\":\\\"{{ '{{'\\\n \\ }} value {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"pbs100\\\"],\\\"manufacturer\\\"\\\n :\\\"zxipc\\\",\\\"model\\\":\\\"4500u\\\",\\\"name\\\":\\\"pbs100\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_uptime/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Uptime\\\", \\n \\\"state_topic\\\":\\\"pbs100/system_uptime\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:clock-digital\\\", \\n \\\"unit_of_measurement\\\": \\\"m\\\"\\\n ,\\n \\\"unique_id\\\":\\\"pbs100_uptime\\\", \\n \\\"entity_category\\\": \\\"diagnostic\\\"\\\n ,\\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} ((value\\\n \\ | float(0))/60) | round(2, 'common') {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"pbs100\\\"],\\\"manufacturer\\\":\\\"zxipc\\\",\\\"model\\\":\\\"4500u\\\",\\\"name\\\":\\\"pbs100\\\"\\\n } \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_iowait/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"IoWait\\\", \\n \\\"state_topic\\\":\\\"pbs100/kernel_stat\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:speedometer-medium\\\", \\n \\\"unit_of_measurement\\\": \\\"\\\n %\\\",\\n \\\"unique_id\\\":\\\"pbs100_iowait\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\n \\ \\\"value_template\\\":\\\"{{ '{{' }} ((value_json.sysstat.hosts[0].statistics[0]['avg-cpu'].iowait)\\\n \\ | float(0)) | round(2, 'common') {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"pbs100\\\"],\\\"manufacturer\\\":\\\"zxipc\\\",\\\"model\\\":\\\"4500u\\\",\\\"name\\\":\\\"pbs100\\\"\\\n } \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_nvme0_usage/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 Usage\\\", \\n \\\"state_topic\\\":\\\"pbs100/disk_usage/nvme0\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:chip\\\", \\n \\\"unit_of_measurement\\\": \\\"%\\\",\\n \\\"unique_id\\\"\\\n :\\\"pbs100_nvme0_usage\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | float(0) | round(0, 'common') {{ '}}' }}\\\", \\n \\\"device\\\"\\\n :{\\\"identifiers\\\":[\\\"pbs100\\\"],\\\"manufacturer\\\":\\\"zxipc\\\",\\\"model\\\":\\\"4500u\\\"\\\n ,\\\"name\\\":\\\"pbs100\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_nvme0_temp/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 Temp\\\", \\n \\\"state_topic\\\":\\\"pbs100/disk_temp/nvme0\\\"\\\n , \\n \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"device_class\\\":\\\"temperature\\\"\\\n ,\\n \\\"unique_id\\\":\\\"pbs100_nvme0_temp\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n\\\n \\ \\\"value_template\\\":\\\"{{ '{{' }} value | float(0) | round(0, 'common') {{\\\n \\ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"pbs100\\\"],\\\"manufacturer\\\"\\\n :\\\"zxipc\\\",\\\"model\\\":\\\"4500u\\\",\\\"name\\\":\\\"pbs100\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_nvme0_tb_written/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 TB Written\\\", \\n \\\"state_topic\\\":\\\"pbs100/ssd_smart/nvme0_lba_written\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Tb\\\",\\n \\\"icon\\\":\\\"mdi:chip\\\",\\n \\\"unique_id\\\"\\\n :\\\"pbs100_nvme0_tb_written\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} ( value | float(0) * 512000 / 1024 / 1024 / 1024 / 1024) |round(1,\\\n \\ 'common') {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"pbs100\\\"],\\\"\\\n manufacturer\\\":\\\"zxipc\\\",\\\"model\\\":\\\"4500u\\\",\\\"name\\\":\\\"pbs100\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_nvme0_power_on_hours/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 Power On Hours\\\", \\n \\\"state_topic\\\":\\\"pbs100/ssd_smart/nvme0_power_on_hours\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"h\\\",\\n \\\"icon\\\":\\\"mdi:clock-alert-outline\\\"\\\n ,\\n \\\"unique_id\\\":\\\"pbs100_nvme0_power_on_hours\\\", \\n \\\"expire_after\\\":\\\"\\\n 150\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n\\\n \\ \\\"device\\\":{\\\"identifiers\\\":[\\\"pbs100\\\"],\\\"manufacturer\\\":\\\"zxipc\\\",\\\"\\\n model\\\":\\\"4500u\\\",\\\"name\\\":\\\"pbs100\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_nvme0_life_left_smart/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 Life Left Smart\\\", \\n \\\"state_topic\\\":\\\"pbs100/ssd_smart/nvme0_life_left\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"%\\\",\\n \\\"icon\\\":\\\"mdi:calendar-heart\\\",\\n\\\n \\ \\\"unique_id\\\":\\\"pbs100_nvme0_life_left_smart\\\", \\n \\\"expire_after\\\":\\\"\\\n 150\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n\\\n \\ \\\"device\\\":{\\\"identifiers\\\":[\\\"pbs100\\\"],\\\"manufacturer\\\":\\\"zxipc\\\",\\\"\\\n model\\\":\\\"4500u\\\",\\\"name\\\":\\\"pbs100\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_nvme0_gb_write/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 Session Write\\\", \\n \\\"state_topic\\\":\\\"pbs100/disk_stat/nvme0_gb_write\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Gb\\\",\\n \\\"icon\\\":\\\"mdi:alpha-w-box\\\",\\n \\\"\\\n unique_id\\\":\\\"pbs100_nvme0_session_write\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n\\\n \\ \\\"value_template\\\":\\\"{{ '{{' }} value| float(0)| round(1, 'common') {{\\\n \\ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"pbs100\\\"],\\\"manufacturer\\\"\\\n :\\\"zxipc\\\",\\\"model\\\":\\\"4500u\\\",\\\"name\\\":\\\"pbs100\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_nvme0_gb_read/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"NVME0 Session Read\\\", \\n \\\"state_topic\\\":\\\"pbs100/disk_stat/nvme0_gb_read\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Gb\\\",\\n \\\"icon\\\":\\\"mdi:alpha-r-box\\\",\\n \\\"\\\n unique_id\\\":\\\"pbs100_nvme0_session_read\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n\\\n \\ \\\"value_template\\\":\\\"{{ '{{' }} value| float(0)| round(1, 'common') {{\\\n \\ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"pbs100\\\"],\\\"manufacturer\\\"\\\n :\\\"zxipc\\\",\\\"model\\\":\\\"4500u\\\",\\\"name\\\":\\\"pbs100\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_sda_usage/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"SDA Usage\\\", \\n \\\"state_topic\\\":\\\"pbs100/disk_usage/sda\\\"\\\n , \\n \\\"icon\\\":\\\"mdi:chip\\\", \\n \\\"unit_of_measurement\\\": \\\"%\\\",\\n \\\"unique_id\\\"\\\n :\\\"pbs100_sda_usage\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | float(0) | round(0, 'common') {{ '}}' }}\\\", \\n \\\"device\\\"\\\n :{\\\"identifiers\\\":[\\\"pbs100\\\"],\\\"manufacturer\\\":\\\"zxipc\\\",\\\"model\\\":\\\"4500u\\\"\\\n ,\\\"name\\\":\\\"pbs100\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_sda_temp/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"SDA Temp\\\", \\n \\\"state_topic\\\":\\\"pbs100/disk_temp/sda\\\"\\\n , \\n \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"device_class\\\":\\\"temperature\\\"\\\n ,\\n \\\"unique_id\\\":\\\"pbs100_sda_temp\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"\\\n value_template\\\":\\\"{{ '{{' }} value | float(0) | round(0, 'common') {{ '}}'\\\n \\ }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"pbs100\\\"],\\\"manufacturer\\\":\\\"zxipc\\\"\\\n ,\\\"model\\\":\\\"4500u\\\",\\\"name\\\":\\\"pbs100\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_sda_tb_written/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"SDA TB Written\\\", \\n \\\"state_topic\\\":\\\"pbs100/ssd_smart/sda_lba_written\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Tb\\\",\\n \\\"icon\\\":\\\"mdi:chip\\\",\\n \\\"unique_id\\\"\\\n :\\\"pbs100_sda_tb_written\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} ( value | float(0) * 512 / 1024 / 1024 / 1024 / 1024) |round(1,\\\n \\ 'common') {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"pbs100\\\"],\\\"\\\n manufacturer\\\":\\\"zxipc\\\",\\\"model\\\":\\\"4500u\\\",\\\"name\\\":\\\"pbs100\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_sda_power_on_hours/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"SDA Power On Hours\\\", \\n \\\"state_topic\\\":\\\"pbs100/ssd_smart/sda_power_on_hours\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"h\\\",\\n \\\"icon\\\":\\\"mdi:clock-alert-outline\\\"\\\n ,\\n \\\"unique_id\\\":\\\"pbs100_sda_power_on_hours\\\", \\n \\\"expire_after\\\":\\\"\\\n 150\\\",\\n \\\"value_template\\\":\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n\\\n \\ \\\"device\\\":{\\\"identifiers\\\":[\\\"pbs100\\\"],\\\"manufacturer\\\":\\\"zxipc\\\",\\\"\\\n model\\\":\\\"4500u\\\",\\\"name\\\":\\\"pbs100\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_sda_life_left_smart/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"SDA Life Left Smart\\\", \\n \\\"state_topic\\\":\\\"pbs100/ssd_smart/sda_life_left\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"%\\\",\\n \\\"icon\\\":\\\"mdi:calendar-heart\\\",\\n\\\n \\ \\\"unique_id\\\":\\\"pbs100_sda_life_left_smart\\\", \\n \\\"expire_after\\\":\\\"150\\\"\\\n ,\\n \\\"value_template\\\":\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n \\\"device\\\"\\\n :{\\\"identifiers\\\":[\\\"pbs100\\\"],\\\"manufacturer\\\":\\\"zxipc\\\",\\\"model\\\":\\\"4500u\\\"\\\n ,\\\"name\\\":\\\"pbs100\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_sda_gb_write/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"SDA Session Write\\\", \\n \\\"state_topic\\\":\\\"pbs100/disk_stat/sda_gb_write\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Gb\\\",\\n \\\"icon\\\":\\\"mdi:alpha-w-box\\\",\\n \\\"\\\n unique_id\\\":\\\"pbs100_sda_session_write\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n\\\n \\ \\\"value_template\\\":\\\"{{ '{{' }} value| float(0)| round(1, 'common') {{\\\n \\ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"pbs100\\\"],\\\"manufacturer\\\"\\\n :\\\"zxipc\\\",\\\"model\\\":\\\"4500u\\\",\\\"name\\\":\\\"pbs100\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_sda_gb_read/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"SDA Session Read\\\", \\n \\\"state_topic\\\":\\\"pbs100/disk_stat/sda_gb_read\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"Gb\\\",\\n \\\"icon\\\":\\\"mdi:alpha-r-box\\\",\\n \\\"\\\n unique_id\\\":\\\"pbs100_sda_session_read\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\n \\ \\\"value_template\\\":\\\"{{ '{{' }} value| float(0)| round(1, 'common') {{ '}}'\\\n \\ }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"pbs100\\\"],\\\"manufacturer\\\":\\\"zxipc\\\"\\\n ,\\\"model\\\":\\\"4500u\\\",\\\"name\\\":\\\"pbs100\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_cpu_temp/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"CPU Temp\\\", \\n \\\"state_topic\\\":\\\"pbs100/psmqtt/sensors_temperatures/k10temp\\\"\\\n , \\n \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"device_class\\\":\\\"temperature\\\"\\\n ,\\n \\\"unique_id\\\":\\\"pbs100_cpu_temp\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"\\\n value_template\\\":\\\"{{ '{{' }} value | float(0) | round(0, 'common') {{ '}}'\\\n \\ }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"pbs100\\\"],\\\"manufacturer\\\":\\\"zxipc\\\"\\\n ,\\\"model\\\":\\\"4500u\\\",\\\"name\\\":\\\"pbs100\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_gpu_temp/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"GPU Temp\\\", \\n \\\"state_topic\\\":\\\"pbs100/psmqtt/sensors_temperatures/amdgpu\\\"\\\n , \\n \\\"unit_of_measurement\\\":\\\"°C\\\",\\n \\\"device_class\\\":\\\"temperature\\\"\\\n ,\\n \\\"unique_id\\\":\\\"pbs100_gpu_temp\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"\\\n value_template\\\":\\\"{{ '{{' }} value | float(0) | round(0, 'common') {{ '}}'\\\n \\ }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\":[\\\"pbs100\\\"],\\\"manufacturer\\\":\\\"zxipc\\\"\\\n ,\\\"model\\\":\\\"4500u\\\",\\\"name\\\":\\\"pbs100\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_cpu_load/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"CPU Load\\\", \\n \\\"state_topic\\\":\\\"pbs100/psmqtt/cpu_percent\\\"\\\n , \\n \\\"unit_of_measurement\\\":\\\"%\\\",\\n \\\"unique_id\\\":\\\"pbs100_cpu_load\\\"\\\n ,\\n \\\"icon\\\":\\\"mdi:cpu-64-bit\\\",\\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | float(0) | round(1, 'common') {{ '}}' }}\\\", \\n \\\"device\\\"\\\n :{\\\"identifiers\\\":[\\\"pbs100\\\"],\\\"manufacturer\\\":\\\"zxipc\\\",\\\"model\\\":\\\"4500u\\\"\\\n ,\\\"name\\\":\\\"pbs100\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_memory_used/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"Memory Used\\\", \\n \\\"state_topic\\\":\\\"pbs100/psmqtt/virtual_memory/percent\\\"\\\n ,\\n \\\"value_template\\\":\\\"{{ '{{' }} value | float(100) | round(1, 'common')\\\n \\ {{ '}}' }}\\\", \\n \\\"unique_id\\\":\\\"pbs100_memory_used\\\",\\n \\\"unit_of_measurement\\\"\\\n :\\\"%\\\",\\n \\\"icon\\\":\\\"mdi:memory\\\",\\n \\\"device\\\":{\\\"identifiers\\\":[\\\"pbs100\\\"\\\n ],\\\"manufacturer\\\":\\\"zxipc\\\",\\\"model\\\":\\\"4500u\\\",\\\"name\\\":\\\"pbs100\\\"} \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_enp1s0_speed/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"enp1s0 Speed\\\", \\n \\\"state_topic\\\":\\\"pbs100/net/enp1s0\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"MB/s\\\",\\n \\\"icon\\\":\\\"mdi:speedometer\\\",\\n\\\n \\ \\\"device_class\\\":\\\"data_rate\\\",\\n \\\"force_update\\\": true,\\n \\\"unique_id\\\"\\\n :\\\"pbs100_enp1s0_speed\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"pbs100\\\"],\\\"manufacturer\\\":\\\"zxipc\\\",\\\"model\\\":\\\"4500u\\\",\\\"name\\\":\\\"pbs100\\\"\\\n } \\n}\"\n - action: mqtt.publish\n data:\n topic: homeassistant/sensor/pbs100_enp3s0_speed/config\n retain: true\n payload: \"{ \\n \\\"name\\\":\\\"enp3s0 Speed\\\", \\n \\\"state_topic\\\":\\\"pbs100/net/enp3s0\\\"\\\n ,\\n \\\"unit_of_measurement\\\":\\\"MB/s\\\",\\n \\\"icon\\\":\\\"mdi:speedometer\\\",\\n\\\n \\ \\\"device_class\\\":\\\"data_rate\\\",\\n \\\"force_update\\\": true,\\n \\\"unique_id\\\"\\\n :\\\"pbs100_enp3s0_speed\\\", \\n \\\"expire_after\\\":\\\"150\\\",\\n \\\"value_template\\\"\\\n :\\\"{{ '{{' }} value | int(0) {{ '}}' }}\\\", \\n \\\"device\\\":{\\\"identifiers\\\"\\\n :[\\\"pbs100\\\"],\\\"manufacturer\\\":\\\"zxipc\\\",\\\"model\\\":\\\"4500u\\\",\\\"name\\\":\\\"pbs100\\\"\\\n } \\n}\"", "config": [ { "name": "mqtt broker main", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.mqtt_broker_main", "device_id": null } } ] }, { "id": "bathroom_button_b_single", "automation": "- alias: bathroom_button_b_single\n id: bathroom_button_b_single\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0001b94abe_action\n click_type: single\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: group.lights_b\n state: 'off'\n sequence:\n - action: xiaomi_miio.light_set_scene\n data:\n entity_id: light.mirror_light_b\n scene: 4\n - conditions:\n - condition: state\n entity_id: fan.esp32_node_b_fan_b\n state: 'off'\n - condition: state\n entity_id: group.lights_b\n state: 'on'\n - condition: state\n entity_id: switch.esp32_node_b_fan_b_force_mode\n state: 'off'\n sequence:\n - action: fan.turn_off\n entity_id: fan.esp32_node_b_fan_t\n - action: timer.pause\n entity_id: timer.fan_t\n - action: switch.turn_on\n entity_id: switch.esp32_node_b_fan_b_manual_mode\n - conditions:\n - condition: state\n entity_id: fan.esp32_node_b_fan_b\n state: 'on'\n - condition: state\n entity_id: switch.esp32_node_b_fan_b_force_mode\n state: 'off'\n sequence:\n - action: switch.turn_off\n entity_id: switch.esp32_node_b_fan_b_manual_mode\n - action: switch.turn_on\n entity_id: switch.esp32_node_b_fan_b_auto_mode", "config": [ { "name": "mirror light b", "room": "bathroom", "type": "light", "id": { "entity_id": "light.mirror_light_b", "device_id": null } }, { "name": "esp32 node b fan b", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.esp32_node_b_fan_b", "device_id": null } }, { "name": "esp32 node b fan b force mode", "room": "bathroom", "type": "switch", "id": { "entity_id": "switch.esp32_node_b_fan_b_force_mode", "device_id": null } }, { "name": "esp32 node b fan b manual mode", "room": "bathroom", "type": "switch", "id": { "entity_id": "switch.esp32_node_b_fan_b_manual_mode", "device_id": null } }, { "name": "esp32 node b fan b auto mode", "room": "bathroom", "type": "switch", "id": { "entity_id": "switch.esp32_node_b_fan_b_auto_mode", "device_id": null } }, { "name": "esp32 node b fan t", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.esp32_node_b_fan_t", "device_id": null } }, { "name": "timer fan t", "room": "bathroom", "type": "timer", "id": { "entity_id": "timer.fan_t", "device_id": null } }, { "name": "Lights B Group", "room": "Bathroom", "type": "group", "id": { "entity_id": "group.lights_b", "device_id": null } }, { "name": "Action Sensor 1b94abe", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x00158d0001b94abe_action", "device_id": null } } ] }, { "id": "bathroom_button_b_double", "automation": "- alias: bathroom_button_b_double\n id: bathroom_button_b_double\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0001b94abe_action\n click_type: double\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: group.lights_b\n state: 'off'\n sequence:\n - action: xiaomi_miio.light_set_scene\n data:\n entity_id: light.mirror_light_b\n scene: 1\n - conditions:\n - condition: state\n entity_id: group.lights_b\n state: 'on'\n sequence:\n - action: fan.toggle\n entity_id: fan.sonoff_pow_r2_1_bottom_fan", "config": [ { "name": "mirror light b", "room": "bathroom", "type": "light", "id": { "entity_id": "light.mirror_light_b", "device_id": null } }, { "name": "sonoff bottom fan", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.sonoff_pow_r2_1_bottom_fan", "device_id": null } }, { "name": "Lights B Group", "room": "Bathroom", "type": "group", "id": { "entity_id": "group.lights_b", "device_id": null } }, { "name": "Action Sensor 1b94abe", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x00158d0001b94abe_action", "device_id": null } } ] }, { "id": "bathroom_fan_with_light", "automation": "- alias: bathroom_fan_with_light\n id: bathroom_fan_with_light\n initial_state: true\n triggers:\n - trigger: state\n entity_id: light.0x00158d0002a36433_channel_2\n to: 'on'\n id: to_on\n - trigger: state\n entity_id: light.0x00158d0002a36433_channel_2\n to: 'off'\n id: to_off\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: to_on\n sequence:\n - action: switch.turn_off\n entity_id: switch.esp32_node_b_fan_b_auto_mode\n - action: fan.turn_off\n entity_id: fan.esp32_node_b_fan_b, fan.sonoff_pow_r2_1_bottom_fan\n - conditions:\n - condition: trigger\n id: to_off\n sequence:\n - action: switch.turn_on\n entity_id: switch.esp32_node_b_fan_b_auto_mode", "config": [ { "name": "esp32 node b fan b", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.esp32_node_b_fan_b", "device_id": null } }, { "name": "esp32 node b fan b auto mode", "room": "bathroom", "type": "switch", "id": { "entity_id": "switch.esp32_node_b_fan_b_auto_mode", "device_id": null } }, { "name": "sonoff bottom fan", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.sonoff_pow_r2_1_bottom_fan", "device_id": null } }, { "name": "bathroom channel 2 light", "room": "bathroom", "type": "light", "id": { "entity_id": "light.0x00158d0002a36433_channel_2", "device_id": null } } ] }, { "id": "bathroom_fan_night_mode", "automation": "- alias: bathroom_fan_night_mode\n id: bathroom_fan_night_mode\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /5\n conditions:\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: template\n value_template: '{{ states(''fan.esp32_node_b_fan_b'') in [''on'',''off''] }}'\n - condition: template\n value_template: '{{ 1 <= now().hour < 6 }}'\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: binary_sensor.0x00158d0002a14c5e_contact\n state: 'off'\n for:\n minutes: 3\n sequence:\n - action: number.set_value\n data:\n value: '30'\n target:\n entity_id: number.esp32_node_b_humidity_set\n - conditions:\n - condition: state\n entity_id: binary_sensor.0x00158d0002a14c5e_contact\n state: 'on'\n for:\n minutes: 3\n sequence:\n - action: number.set_value\n data:\n value: '65'\n target:\n entity_id: number.esp32_node_b_humidity_set", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "bathroom contact sensor", "room": "bathroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002a14c5e_contact", "device_id": null } }, { "name": "esp32 node b fan b", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.esp32_node_b_fan_b", "device_id": null } }, { "name": "esp32 node b humidity set", "room": "bathroom", "type": "number", "id": { "entity_id": "number.esp32_node_b_humidity_set", "device_id": null } } ] }, { "id": "bathroom_fan_to_normal_mode", "automation": "- alias: bathroom_fan_to_normal_mode\n id: bathroom_fan_to_normal_mode\n initial_state: true\n triggers:\n - trigger: time\n at: 06:20:00\n conditions:\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: template\n value_template: '{{ states(''fan.esp32_node_b_fan_b'') in [''on'',''off''] }}'\n - condition: template\n value_template: '{{states(''number.esp32_node_b_humidity_set'')|int(0) < 50 }}'\n actions:\n - action: number.set_value\n data:\n value: '65'\n target:\n entity_id: number.esp32_node_b_humidity_set\n - action: switch.turn_off\n entity_id: switch.esp32_node_b_fan_b_force_mode", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "esp32 node b fan b", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.esp32_node_b_fan_b", "device_id": null } }, { "name": "esp32 node b fan b force mode", "room": "bathroom", "type": "switch", "id": { "entity_id": "switch.esp32_node_b_fan_b_force_mode", "device_id": null } }, { "name": "esp32 node b humidity set", "room": "bathroom", "type": "number", "id": { "entity_id": "number.esp32_node_b_humidity_set", "device_id": null } } ] }, { "id": "bathroom_bottom_fan_with_fan", "automation": "- alias: bathroom_bottom_fan_with_fan\n id: bathroom_bottom_fan_with_fan\n initial_state: true\n triggers:\n - trigger: state\n entity_id: fan.esp32_node_b_fan_b\n to: null\n conditions:\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: template\n value_template: '{{ states(''fan.esp32_node_b_fan_b'') in [''on'',''off''] }}'\n actions:\n - action: fan.turn_{{ states('fan.esp32_node_b_fan_b') }}\n entity_id: fan.sonoff_pow_r2_1_bottom_fan", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "esp32 node b fan b", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.esp32_node_b_fan_b", "device_id": null } }, { "name": "sonoff bottom fan", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.sonoff_pow_r2_1_bottom_fan", "device_id": null } } ] }, { "id": "bathroom_bottom_fan", "automation": "- alias: bathroom_bottom_fan\n id: bathroom_bottom_fan\n initial_state: true\n triggers:\n - trigger: time\n at: 07:00:03\n - trigger: time\n at: '23:00:03'\n conditions:\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n actions:\n - action: fan.turn_{%if states('binary_sensor.tod_day')%}off{%else%}on{%endif%}\n entity_id: fan.sonoff_pow_r2_1_bottom_fan", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "sonoff bottom fan", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.sonoff_pow_r2_1_bottom_fan", "device_id": null } } ] }, { "id": "bathroom_bottom_fan_toggle", "automation": "- alias: bathroom_bottom_fan_toggle\n id: bathroom_bottom_fan_toggle\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /30\n conditions:\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'off'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: state\n entity_id: switch.esp32_node_b_fan_b_force_mode\n state: 'off'\n actions:\n - condition: template\n value_template: '{{ is_state(''group.lights_b'',''off'') or is_state(''fan.sonoff_pow_r2_1_bottom_fan'',''on'')\n }}'\n - action: fan.toggle\n entity_id: fan.sonoff_pow_r2_1_bottom_fan", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "esp32 node b fan b force mode", "room": "bathroom", "type": "switch", "id": { "entity_id": "switch.esp32_node_b_fan_b_force_mode", "device_id": null } }, { "name": "sonoff bottom fan", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.sonoff_pow_r2_1_bottom_fan", "device_id": null } }, { "name": "Lights B Group", "room": "Bathroom", "type": "group", "id": { "entity_id": "group.lights_b", "device_id": null } } ] }, { "id": "bathroom_fan_off_by_timer", "automation": "- alias: bathroom_fan_off_by_timer\n id: bathroom_fan_off_by_timer\n initial_state: true\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.fan_b\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: fan.turn_off\n entity_id: fan.esp32_node_b_fan_b\n - action: switch.turn_off\n entity_id: switch.esp32_node_b_fan_b_manual_mode\n - condition: state\n entity_id: timer.fan_t\n state: paused\n - action: fan.turn_on\n entity_id: fan.esp32_node_b_fan_t\n - action: timer.start\n entity_id: timer.fan_t", "config": [ { "name": "esp32 node b fan b", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.esp32_node_b_fan_b", "device_id": null } }, { "name": "esp32 node b fan b manual mode", "room": "bathroom", "type": "switch", "id": { "entity_id": "switch.esp32_node_b_fan_b_manual_mode", "device_id": null } }, { "name": "esp32 node b fan t", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.esp32_node_b_fan_t", "device_id": null } }, { "name": "timer fan b", "room": "bathroom", "type": "timer", "id": { "entity_id": "timer.fan_b", "device_id": null } }, { "name": "timer fan t", "room": "bathroom", "type": "timer", "id": { "entity_id": "timer.fan_t", "device_id": null } } ] }, { "id": "bathroom_main_fan_timer_with_switch", "automation": "- alias: bathroom_main_fan_timer_with_switch\n id: bathroom_main_fan_timer_with_switch\n mode: single\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: state\n entity_id: fan.esp32_node_b_fan_b\n to: null\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: template\n value_template: '{{ states(''fan.esp32_node_b_fan_b'') in [''on'',''off''] }}'\n - condition: state\n entity_id: switch.esp32_node_b_fan_b_force_mode\n state: 'off'\n actions:\n - if:\n - condition: state\n entity_id: fan.esp32_node_b_fan_b\n state: 'on'\n then:\n - action: timer.start\n entity_id: timer.fan_b", "config": [ { "name": "esp32 node b fan b", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.esp32_node_b_fan_b", "device_id": null } }, { "name": "esp32 node b fan b force mode", "room": "bathroom", "type": "switch", "id": { "entity_id": "switch.esp32_node_b_fan_b_force_mode", "device_id": null } }, { "name": "timer fan b", "room": "bathroom", "type": "timer", "id": { "entity_id": "timer.fan_b", "device_id": null } } ] }, { "id": "bathroom_light_off_auto", "automation": "- alias: bathroom_light_off_auto\n id: bathroom_light_off_auto\n initial_state: true\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.main_light_b\n conditions:\n - condition: state\n entity_id: binary_sensor.presence_b\n state: 'off'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: state\n entity_id: group.lights_b\n state: 'on'\n actions:\n - action: light.turn_off\n entity_id: light.0x00158d0002a36433_channel_2\n - action: light.turn_off\n entity_id: light.mirror_light_b\n data:\n transition: 5", "config": [ { "name": "mirror light b", "room": "bathroom", "type": "light", "id": { "entity_id": "light.mirror_light_b", "device_id": null } }, { "name": "bathroom channel 2 light", "room": "bathroom", "type": "light", "id": { "entity_id": "light.0x00158d0002a36433_channel_2", "device_id": null } }, { "name": "presence bathroom", "room": "bathroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.presence_b", "device_id": null } }, { "name": "timer main light b", "room": "bathroom", "type": "timer", "id": { "entity_id": "timer.main_light_b", "device_id": null } }, { "name": "Lights B Group", "room": "Bathroom", "type": "group", "id": { "entity_id": "group.lights_b", "device_id": null } } ] }, { "id": "bathroom_light_timer_on", "automation": "- alias: bathroom_light_timer_on\n id: bathroom_light_timer_on\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.presence_b\n from: 'on'\n to: 'off'\n - trigger: state\n entity_id: group.lights_b\n to: 'on'\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_b\n - action: timer.start\n entity_id: timer.main_light_b", "config": [ { "name": "presence bathroom", "room": "bathroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.presence_b", "device_id": null } }, { "name": "timer main light b", "room": "bathroom", "type": "timer", "id": { "entity_id": "timer.main_light_b", "device_id": null } }, { "name": "Lights B Group", "room": "Bathroom", "type": "group", "id": { "entity_id": "group.lights_b", "device_id": null } } ] }, { "id": "bathroom_timer_stop", "automation": "- alias: bathroom_timer_stop\n id: bathroom_timer_stop\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.presence_b\n from: 'off'\n to: 'on'\n - trigger: state\n entity_id: group.lights_b\n to: 'off'\n conditions:\n - condition: state\n entity_id: timer.main_light_b\n state: active\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_b, timer.door_b", "config": [ { "name": "presence bathroom", "room": "bathroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.presence_b", "device_id": null } }, { "name": "timer main light b", "room": "bathroom", "type": "timer", "id": { "entity_id": "timer.main_light_b", "device_id": null } }, { "name": "timer door b", "room": "bathroom", "type": "timer", "id": { "entity_id": "timer.door_b", "device_id": null } }, { "name": "Lights B Group", "room": "Bathroom", "type": "group", "id": { "entity_id": "group.lights_b", "device_id": null } } ] }, { "id": "bathroom_timer_stop_motion_with_light_presence", "automation": "- alias: bathroom_timer_stop_motion_with_light_presence\n id: bathroom_timer_stop_motion_with_light_presence\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x00158d000236bc6d_motion\n to: 'on'\n conditions:\n and:\n - condition: state\n entity_id: binary_sensor.presence_b\n state: 'on'\n - condition: state\n entity_id: group.lights_b\n state: 'on'\n - or:\n - condition: state\n entity_id: timer.main_light_b\n state: active\n - condition: state\n entity_id: timer.door_b\n state: active\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_b, timer.door_b", "config": [ { "name": "presence bathroom", "room": "bathroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.presence_b", "device_id": null } }, { "name": "timer main light b", "room": "bathroom", "type": "timer", "id": { "entity_id": "timer.main_light_b", "device_id": null } }, { "name": "timer door b", "room": "bathroom", "type": "timer", "id": { "entity_id": "timer.door_b", "device_id": null } }, { "name": "bathroom motion sensor", "room": "bathroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d000236bc6d_motion", "device_id": null } }, { "name": "Lights B Group", "room": "Bathroom", "type": "group", "id": { "entity_id": "group.lights_b", "device_id": null } } ] }, { "id": "bathroom_input_on_off", "automation": "- alias: bathroom_input_on_off\n id: bathroom_input_on_off\n mode: queued\n max: 10\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.wasp_b\n to: 'on'\n id: id_to_on\n - trigger: state\n entity_id: binary_sensor.wasp_b\n to: 'off'\n id: id_to_off\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: id_to_on\n - condition: state\n entity_id: group.lights_b\n state: 'on'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n sequence:\n - action: timer.pause\n entity_id: timer.main_light_b\n - action: input_boolean.turn_on\n data:\n entity_id: input_boolean.bathroom_occupancy\n - conditions:\n - condition: trigger\n id: id_to_off\n sequence:\n - action: input_boolean.turn_off\n data:\n entity_id: input_boolean.bathroom_occupancy", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "timer main light b", "room": "bathroom", "type": "timer", "id": { "entity_id": "timer.main_light_b", "device_id": null } }, { "name": "wasp b", "room": "bathroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.wasp_b", "device_id": null } }, { "name": "input boolean bathroom occupancy", "room": "bathroom", "type": "input_boolean", "id": { "entity_id": "input_boolean.bathroom_occupancy", "device_id": null } }, { "name": "Lights B Group", "room": "Bathroom", "type": "group", "id": { "entity_id": "group.lights_b", "device_id": null } } ] }, { "id": "bathroom_auto_light_on_soft", "automation": "- alias: bathroom_auto_light_on_soft\n id: bathroom_auto_light_on_soft\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d000236bc6d_motion\n conditions:\n - condition: state\n entity_id: group.lights_b\n state: 'off'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: xiaomi_miio.light_set_scene\n data:\n entity_id: light.mirror_light_b\n scene: '{{4 if (is_state(''binary_sensor.tod_day'',''off'') or is_state(''switch.system_dark_mode'',''on''))\n else 1}}'", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "system dark mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_dark_mode", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "mirror light b", "room": "bathroom", "type": "light", "id": { "entity_id": "light.mirror_light_b", "device_id": null } }, { "name": "bathroom motion sensor", "room": "bathroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d000236bc6d_motion", "device_id": null } }, { "name": "Lights B Group", "room": "Bathroom", "type": "group", "id": { "entity_id": "group.lights_b", "device_id": null } } ] }, { "id": "bathroom_light_toggle_repeater", "automation": "- alias: bathroom_light_toggle_repeater\n id: bathroom_light_toggle_repeater\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x54ef4410005054cc_action\n click_type: button_1_single\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: group.lights_b\n state: 'on'\n sequence:\n - action: light.turn_off\n entity_id: light.0x00158d0002a36433_channel_2, light.mirror_light_b\n - conditions:\n - condition: state\n entity_id: group.lights_b\n state: 'off'\n sequence:\n - action: light.turn_on\n entity_id: light.0x00158d0002a36433_channel_2", "config": [ { "name": "mirror light b", "room": "bathroom", "type": "light", "id": { "entity_id": "light.mirror_light_b", "device_id": null } }, { "name": "bathroom channel 2 light", "room": "bathroom", "type": "light", "id": { "entity_id": "light.0x00158d0002a36433_channel_2", "device_id": null } }, { "name": "action sensor bathroom repeater", "room": "bathroom", "type": "sensor", "id": { "entity_id": "sensor.0x54ef4410005054cc_action", "device_id": null } }, { "name": "Lights B Group", "room": "Bathroom", "type": "group", "id": { "entity_id": "group.lights_b", "device_id": null } } ] }, { "id": "bathroom_mirror_light_manual", "automation": "- alias: bathroom_mirror_light_manual\n id: bathroom_mirror_light_manual\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0001ef6089_action\n conditions:\n - condition: template\n value_template: '{{ states(''light.mirror_light_b'') in [''on'',''off''] }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: light.mirror_light_b\n state: 'on'\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''single'' }}'\n sequence:\n - action: light.turn_off\n entity_id: light.mirror_light_b\n - conditions:\n - condition: state\n entity_id: light.mirror_light_b\n state: 'off'\n - condition: state\n entity_id: light.0x00158d0002a36433_channel_2\n state: 'off'\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''single'' }}'\n sequence:\n - action: xiaomi_miio.light_set_scene\n data:\n entity_id: light.mirror_light_b\n scene: 4\n - conditions:\n - condition: state\n entity_id: light.mirror_light_b\n state: 'off'\n - condition: state\n entity_id: light.0x00158d0002a36433_channel_2\n state: 'on'\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''single'' }}'\n sequence:\n - action: xiaomi_miio.light_set_scene\n data:\n entity_id: light.mirror_light_b\n scene: 1\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''double'' }}'\n sequence:\n - action: xiaomi_miio.light_set_scene\n data:\n entity_id: light.mirror_light_b\n scene: 1\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''hold'' }}'\n sequence:\n - action: xiaomi_miio.light_set_scene\n data:\n entity_id: light.mirror_light_b\n scene: 4", "config": [ { "name": "mirror light b", "room": "bathroom", "type": "light", "id": { "entity_id": "light.mirror_light_b", "device_id": null } }, { "name": "bathroom channel 2 light", "room": "bathroom", "type": "light", "id": { "entity_id": "light.0x00158d0002a36433_channel_2", "device_id": null } }, { "name": "action sensor bathroom mirror", "room": "bathroom", "type": "sensor", "id": { "entity_id": "sensor.0x00158d0001ef6089_action", "device_id": null } } ] }, { "id": "bathroom_mirror_light_restart", "automation": "- alias: bathroom_mirror_light_restart\n id: bathroom_mirror_light_restart\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /1\n conditions:\n - condition: state\n entity_id: light.mirror_light_b\n state: unavailable\n for:\n minutes: 2\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: state\n entity_id: switch.system_mirror_light_b_restart_key\n state: 'on'\n - condition: template\n value_template: \"{% set ignore = ['unknown', 'unavailable', 'none'] %} {{ states('switch.esp32_node_b_relay_5')\\\n \\ not in ignore }} \\n\"\n actions:\n - repeat:\n while:\n - condition: state\n entity_id: light.mirror_light_b\n state: unavailable\n - condition: template\n value_template: '{{ repeat.index <= 5 }}'\n sequence:\n - action: switch.turn_off\n entity_id: switch.esp32_node_b_relay_5\n - delay:\n seconds: 15\n - action: switch.turn_on\n entity_id: switch.esp32_node_b_relay_5\n - action: notify.telegram\n data:\n message: 🚨 Mirror LED B restart done({{repeat.index}})!\n - delay:\n seconds: 30\n - condition: state\n entity_id: light.mirror_light_b\n state: unavailable\n - action: notify.telegram\n data:\n message: 🚨 Mirror LED B restart unsuccessful!\n - action: switch.turn_off\n entity_id: switch.system_mirror_light_b_restart_key", "config": [ { "name": "mirror light b", "room": "bathroom", "type": "light", "id": { "entity_id": "light.mirror_light_b", "device_id": null } }, { "name": "system mirror light b restart key", "room": "bathroom", "type": "switch", "id": { "entity_id": "switch.system_mirror_light_b_restart_key", "device_id": null } }, { "name": "esp32 node b relay 5", "room": "bathroom", "type": "switch", "id": { "entity_id": "switch.esp32_node_b_relay_5", "device_id": null } } ] }, { "id": "bathroom_mirror_led_restart_key_toggle", "automation": "- alias: bathroom_mirror_led_restart_key_toggle\n id: bathroom_mirror_led_restart_key_toggle\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: light.mirror_light_b\n from: unavailable\n actions:\n - action: switch.turn_on\n entity_id: switch.system_mirror_light_b_restart_key", "config": [ { "name": "mirror light b", "room": "bathroom", "type": "light", "id": { "entity_id": "light.mirror_light_b", "device_id": null } }, { "name": "system mirror light b restart key", "room": "bathroom", "type": "switch", "id": { "entity_id": "switch.system_mirror_light_b_restart_key", "device_id": null } } ] }, { "id": "bathroom_indicator", "automation": "- alias: bathroom_indicator\n id: bathroom_indicator\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: input_boolean.bathroom_occupancy\n to: null\n conditions:\n - condition: template\n value_template: '{{ states(''input_boolean.bathroom_occupancy'') in [''on'',''off'']\n }}'\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: input_boolean.bathroom_occupancy\n state: 'off'\n sequence:\n - action: light.turn_off\n entity_id: light.esp32_node_hs_bathroom\n - conditions:\n - condition: state\n entity_id: input_boolean.bathroom_occupancy\n state: 'on'\n sequence:\n - action: light.turn_on\n data:\n entity_id: light.esp32_node_hs_bathroom\n effect: Color Wipe\n brightness: 100", "config": [ { "name": "input boolean bathroom occupancy", "room": "bathroom", "type": "input_boolean", "id": { "entity_id": "input_boolean.bathroom_occupancy", "device_id": null } }, { "name": "esp32 node hs bathroom", "room": "bathroom", "type": "light", "id": { "entity_id": "light.esp32_node_hs_bathroom", "device_id": null } } ] }, { "id": "bathroom_mirror_light_sync", "automation": "- alias: bathroom_mirror_light_sync\n id: bathroom_mirror_light_sync\n initial_state: true\n mode: queued\n max: 10\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: light.0x00158d0002a36433_channel_2\n to: 'off'\n from: 'on'\n id: to_off\n - trigger: state\n entity_id: light.0x00158d0002a36433_channel_2\n to: 'on'\n from: 'off'\n id: to_on\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: to_off\n - condition: state\n entity_id: light.mirror_light_b\n state: 'on'\n sequence:\n - action: light.turn_off\n entity_id: light.mirror_light_b\n data:\n transition: 5\n - conditions:\n - condition: trigger\n id: to_on\n - condition: state\n entity_id: light.mirror_light_b\n state: 'on'\n sequence:\n - action: xiaomi_miio.light_set_scene\n data:\n entity_id: light.mirror_light_b\n scene: 1", "config": [ { "name": "mirror light b", "room": "bathroom", "type": "light", "id": { "entity_id": "light.mirror_light_b", "device_id": null } }, { "name": "bathroom channel 2 light", "room": "bathroom", "type": "light", "id": { "entity_id": "light.0x00158d0002a36433_channel_2", "device_id": null } } ] }, { "id": "hall_big_auto_night_light_on", "automation": "- alias: hall_big_auto_night_light_on\n id: hall_big_auto_night_light_on\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0001e05856_motion\n conditions:\n - or:\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'off'\n - condition: state\n entity_id: switch.system_dark_mode\n state: 'on'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: state\n entity_id: group.lights_hb\n state: 'off'\n actions:\n - action: light.turn_on\n entity_id: light.esp32_strip_1s_entrance_hb_rgb\n data:\n brightness: 10\n rgb_color:\n - 250\n - 95\n - 85", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "system dark mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_dark_mode", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "entrance motion sensor", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001e05856_motion", "device_id": null } }, { "name": "esp32 strip 1s entrance hb rgb", "room": "hall_big", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_entrance_hb_rgb", "device_id": null } }, { "name": "Lights HB Group", "room": "Hall Big", "type": "group", "id": { "entity_id": "group.lights_hb", "device_id": null } } ] }, { "id": "hall_big_auto_light_on", "automation": "- alias: hall_big_auto_light_on\n id: hall_big_auto_light_on\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0001e05856_motion\n id: entr\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0002b482e9_motion\n id: fridge\n conditions:\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'on'\n - condition: state\n entity_id: switch.system_dark_mode\n state: 'off'\n - condition: state\n entity_id: group.lights_main_hb\n state: 'off'\n actions:\n - action: script.hall_big_led_strip_on\n data:\n strips: '{{ trigger.id }}'", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "system dark mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_dark_mode", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "entrance motion sensor", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001e05856_motion", "device_id": null } }, { "name": "fridge motion sensor", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b482e9_motion", "device_id": null } }, { "name": "Lights Main HB Group", "room": "Hall Big", "type": "group", "id": { "entity_id": "group.lights_main_hb", "device_id": null } } ] }, { "id": "hall_big_night_mode_preparation", "automation": "- alias: hall_big_night_mode_preparation\n id: hall_big_night_mode_preparation\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.tod_day\n from: 'on'\n to: 'off'\n actions:\n - action: light.turn_off\n entity_id: light.esp32_strip_1s_wadrobe_hb_rgb, light.esp32_strip_1s_entrance_hb_rgb\n data:\n transition: 5\n - action: switch.turn_off\n entity_id: switch.system_dark_mode", "config": [ { "name": "system dark mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_dark_mode", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "esp32 strip 1s entrance hb rgb", "room": "hall_big", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_entrance_hb_rgb", "device_id": null } }, { "name": "esp32 strip 1s wadrobe hb rgb", "room": "hall_big", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_wadrobe_hb_rgb", "device_id": null } } ] }, { "id": "hall_big_main_door_open", "automation": "- alias: hall_big_main_door_open\n id: hall_big_main_door_open\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id:\n - binary_sensor.0x00158d0001e5d6be_contact\n from: 'off'\n to: 'on'\n actions:\n - action: script.hall_big_led_strip_on\n data:\n strips: both\n - action: input_number.set_value\n data:\n entity_id: input_number.main_door_open\n value: '{{as_timestamp(now())|int(0) }}'\n - action: counter.increment\n entity_id: counter.main_door_hb\n - action: notify.telegram\n data:\n message: 🚪 Внимание! Входная дверь открыта! ({{states('sensor.time')}} {{states('sensor.date')}},\n {{ states('counter.main_door_hb') }})\n - action: notify.telegram_cam\n data:\n message: 🚪 Внимание! Входная дверь открыта! ({{states('sensor.time')}} {{states('sensor.date')}},\n {{ states('counter.main_door_hb') }})\n - delay: 00:00:09\n - action: script.turn_on\n entity_id: script.open_door_photo", "config": [ { "name": "time", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.time", "device_id": null } }, { "name": "date", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.date", "device_id": null } }, { "name": "main door contact", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001e5d6be_contact", "device_id": null } }, { "name": "main door open", "room": "hall_big", "type": "input_number", "id": { "entity_id": "input_number.main_door_open", "device_id": null } }, { "name": "counter main door hb", "room": "hall_big", "type": "counter", "id": { "entity_id": "counter.main_door_hb", "device_id": null } }, { "name": "Open Door Photo Script", "room": null, "type": "script", "id": { "entity_id": "script.open_door_photo", "device_id": null } } ] }, { "id": "hall_big_timer_on", "automation": "- alias: hall_big_timer_on\n id: hall_big_timer_on\n initial_state: true\n triggers:\n - trigger: state\n entity_id: light.0x00158d000223921b_channel_1\n to: 'on'\n from: 'off'\n - trigger: state\n entity_id: light.0x00158d000253f04a_channel_2\n to: 'on'\n from: 'off'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_hb\n - action: timer.start\n entity_id: timer.main_light_hb", "config": [ { "name": "channel 1 light", "room": "hall_big", "type": "light", "id": { "entity_id": "light.0x00158d000223921b_channel_1", "device_id": null } }, { "name": "channel 2 light fridge", "room": "hall_big", "type": "light", "id": { "entity_id": "light.0x00158d000253f04a_channel_2", "device_id": null } }, { "name": "timer main light hb", "room": "hall_big", "type": "timer", "id": { "entity_id": "timer.main_light_hb", "device_id": null } } ] }, { "id": "hall_big_timer_off", "automation": "- alias: hall_big_timer_off\n id: hall_big_timer_off\n initial_state: true\n triggers:\n - trigger: template\n value_template: '{{not is_state(''light.0x00158d000253f04a_channel_2'',''on'')\n and not is_state(''light.0x00158d000223921b_channel_1'',''on'') }}'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_hb", "config": [ { "name": "channel 1 light", "room": "hall_big", "type": "light", "id": { "entity_id": "light.0x00158d000223921b_channel_1", "device_id": null } }, { "name": "channel 2 light fridge", "room": "hall_big", "type": "light", "id": { "entity_id": "light.0x00158d000253f04a_channel_2", "device_id": null } }, { "name": "timer main light hb", "room": "hall_big", "type": "timer", "id": { "entity_id": "timer.main_light_hb", "device_id": null } } ] }, { "id": "hall_big_led_strip_with_main_off", "automation": "- alias: hall_big_led_strip_with_main_off\n id: hall_big_led_strip_with_main_off\n initial_state: true\n triggers:\n - trigger: state\n entity_id: group.lights_main_hb\n to: 'off'\n from: 'on'\n - trigger: state\n entity_id: group.lights_main_hb\n to: 'on'\n from: 'off'\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: group.lights_main_hb\n state: 'off'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n sequence:\n - action: script.hall_big_led_strip_on\n data:\n strips: both\n - conditions:\n - condition: state\n entity_id: group.lights_main_hb\n state: 'on'\n sequence:\n - action: light.turn_off\n entity_id: light.esp32_strip_1s_entrance_hb_rgb, light.esp32_strip_1s_wadrobe_hb_rgb\n data:\n transition: 5", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "esp32 strip 1s entrance hb rgb", "room": "hall_big", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_entrance_hb_rgb", "device_id": null } }, { "name": "esp32 strip 1s wadrobe hb rgb", "room": "hall_big", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_wadrobe_hb_rgb", "device_id": null } }, { "name": "Lights Main HB Group", "room": "Hall Big", "type": "group", "id": { "entity_id": "group.lights_main_hb", "device_id": null } } ] }, { "id": "hall_big_auto_off_10m", "automation": "- alias: hall_big_auto_off_10m\n id: hall_big_auto_off_10m\n initial_state: true\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.main_light_hb\n actions:\n - action: light.turn_off\n entity_id: light.0x00158d000223921b_channel_1, light.0x00158d000253f04a_channel_2", "config": [ { "name": "channel 1 light", "room": "hall_big", "type": "light", "id": { "entity_id": "light.0x00158d000223921b_channel_1", "device_id": null } }, { "name": "channel 2 light fridge", "room": "hall_big", "type": "light", "id": { "entity_id": "light.0x00158d000253f04a_channel_2", "device_id": null } }, { "name": "timer main light hb", "room": "hall_big", "type": "timer", "id": { "entity_id": "timer.main_light_hb", "device_id": null } } ] }, { "id": "hall_big_timer_restart", "automation": "- alias: hall_big_timer_restart\n id: hall_big_timer_restart\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0001e05856_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0002b482e9_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.582d34609600_motion\n conditions:\n - condition: state\n entity_id: group.lights_main_hb\n state: 'on'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_hb\n - action: timer.start\n entity_id: timer.main_light_hb", "config": [ { "name": "entrance motion sensor", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001e05856_motion", "device_id": null } }, { "name": "fridge motion sensor", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b482e9_motion", "device_id": null } }, { "name": "timer main light hb", "room": "hall_big", "type": "timer", "id": { "entity_id": "timer.main_light_hb", "device_id": null } }, { "name": "wardrobe motion sensor", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.582d34609600_motion", "device_id": null } }, { "name": "Lights Main HB Group", "room": "Hall Big", "type": "group", "id": { "entity_id": "group.lights_main_hb", "device_id": null } } ] }, { "id": "hall_big_entrance_light_on_from_fridge", "automation": "- alias: hall_big_entrance_light_on_from_fridge\n id: hall_big_entrance_light_on_from_fridge\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d000253f04a_action\n click_type: button_1_single\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0001e0784e_action\n click_type: button_1_single\n conditions:\n - condition: numeric_state\n entity_id: sensor.ha_uptime\n above: 0\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: light.toggle\n entity_id: light.0x00158d000223921b_channel_1", "config": [ { "name": "ha uptime", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.ha_uptime", "device_id": null } }, { "name": "channel 1 light", "room": "hall_big", "type": "light", "id": { "entity_id": "light.0x00158d000223921b_channel_1", "device_id": null } }, { "name": "action sensor fridge light", "room": "hall_big", "type": "sensor", "id": { "entity_id": "sensor.0x00158d000253f04a_action", "device_id": null } }, { "name": "action sensor double button", "room": "hall_big", "type": "sensor", "id": { "entity_id": "sensor.0x00158d0001e0784e_action", "device_id": null } } ] }, { "id": "hall_big_fridge_light_on_from_entrance", "automation": "- alias: hall_big_fridge_light_on_from_entrance\n id: hall_big_fridge_light_on_from_entrance\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d000223921b_action\n click_type: button_2_single\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0001e0784e_action\n click_type: button_2_single\n conditions:\n - condition: numeric_state\n entity_id: sensor.ha_uptime\n above: 0\n actions:\n - action: light.toggle\n entity_id: light.0x00158d000253f04a_channel_2", "config": [ { "name": "ha uptime", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.ha_uptime", "device_id": null } }, { "name": "channel 2 light fridge", "room": "hall_big", "type": "light", "id": { "entity_id": "light.0x00158d000253f04a_channel_2", "device_id": null } }, { "name": "action sensor entrance light", "room": "hall_big", "type": "sensor", "id": { "entity_id": "sensor.0x00158d000223921b_action", "device_id": null } }, { "name": "action sensor double button", "room": "hall_big", "type": "sensor", "id": { "entity_id": "sensor.0x00158d0001e0784e_action", "device_id": null } } ] }, { "id": "hall_big_led_strip_restart", "automation": "- alias: hall_big_led_strip_restart\n id: hall_big_led_strip_restart\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /1\n conditions:\n - condition: state\n entity_id: light.esp32_strip_1s_wadrobe_hb_rgb\n state: unavailable\n for:\n minutes: 2\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: state\n entity_id: switch.system_led_strip_hb_restart_key\n state: 'on'\n - condition: template\n value_template: \"{% set ignore = ['unknown', 'unavailable', 'none'] %} {{ states('switch.0x00158d00023e5812_outlet')\\\n \\ not in ignore }} \\n\"\n actions:\n - repeat:\n while:\n - condition: state\n entity_id: light.esp32_strip_1s_wadrobe_hb_rgb\n state: unavailable\n - condition: template\n value_template: '{{ repeat.index <= 5 }}'\n sequence:\n - action: switch.turn_off\n entity_id: switch.0x00158d00023e5812_outlet\n - delay:\n seconds: 15\n - action: switch.turn_on\n entity_id: switch.0x00158d00023e5812_outlet\n - action: notify.telegram\n data:\n message: 🚨 LED Strip HB restart done({{repeat.index}})!\n - delay:\n seconds: 15\n - condition: state\n entity_id: light.esp32_strip_1s_wadrobe_hb_rgb\n state: unavailable\n - action: notify.telegram\n data:\n message: 🚨 LED Strip HB restart unsuccessful!\n - action: switch.turn_off\n entity_id: switch.system_led_strip_hb_restart_key", "config": [ { "name": "esp32 strip 1s wadrobe hb rgb", "room": "hall_big", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_wadrobe_hb_rgb", "device_id": null } }, { "name": "system led strip hb restart key", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.system_led_strip_hb_restart_key", "device_id": null } }, { "name": "zigbee outlet led strip", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.0x00158d00023e5812_outlet", "device_id": null } } ] }, { "id": "hall_big_led_strip_restart_key_toggle", "automation": "- alias: hall_big_led_strip_restart_key_toggle\n id: hall_big_led_strip_restart_key_toggle\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: light.esp32_strip_1s_wadrobe_hb_rgb\n from: unavailable\n actions:\n - action: switch.turn_on\n entity_id: switch.system_led_strip_hb_restart_key", "config": [ { "name": "esp32 strip 1s wadrobe hb rgb", "room": "hall_big", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_wadrobe_hb_rgb", "device_id": null } }, { "name": "system led strip hb restart key", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.system_led_strip_hb_restart_key", "device_id": null } } ] }, { "id": "hall_big_led_strip_entrance_restart", "automation": "- alias: hall_big_led_strip_entrance_restart\n id: hall_big_led_strip_entrance_restart\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: time_pattern\n minutes: /1\n conditions:\n - condition: state\n entity_id: light.esp32_strip_1s_entrance_hb_rgb\n state: unavailable\n for:\n minutes: 2\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: state\n entity_id: switch.system_led_strip_entrance_hb_restart_key\n state: 'on'\n - condition: template\n value_template: \"{% set ignore = ['unknown', 'unavailable', 'none'] %} {{ states('switch.digma_strip_hb_relay1')\\\n \\ not in ignore }} \\n\"\n actions:\n - repeat:\n while:\n - condition: state\n entity_id: light.esp32_strip_1s_entrance_hb_rgb\n state: unavailable\n - condition: template\n value_template: '{{ repeat.index <= 5 }}'\n sequence:\n - action: switch.turn_off\n entity_id: switch.digma_strip_hb_relay1\n - delay:\n seconds: 15\n - action: switch.turn_on\n entity_id: switch.digma_strip_hb_relay1\n - action: notify.telegram\n data:\n message: 🚨 LED Strip Entrance HB restart done({{repeat.index}})!\n - delay:\n seconds: 15\n - condition: state\n entity_id: light.esp32_strip_1s_entrance_hb_rgb\n state: unavailable\n - action: notify.telegram\n data:\n message: 🚨 LED Strip Entrance HB restart unsuccessful!\n - action: switch.turn_off\n entity_id: switch.system_led_strip_entrance_hb_restart_key", "config": [ { "name": "esp32 strip 1s entrance hb rgb", "room": "hall_big", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_entrance_hb_rgb", "device_id": null } }, { "name": "system led strip entrance hb restart key", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.system_led_strip_entrance_hb_restart_key", "device_id": null } }, { "name": "digma strip hb relay1", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.digma_strip_hb_relay1", "device_id": null } } ] }, { "id": "hall_big_led_strip_entrance_restart_key_toggle", "automation": "- alias: hall_big_led_strip_entrance_restart_key_toggle\n id: hall_big_led_strip_entrance_restart_key_toggle\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: light.esp32_strip_1s_entrance_hb_rgb\n from: unavailable\n actions:\n - action: switch.turn_on\n entity_id: switch.system_led_strip_entrance_hb_restart_key", "config": [ { "name": "esp32 strip 1s entrance hb rgb", "room": "hall_big", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_entrance_hb_rgb", "device_id": null } }, { "name": "system led strip entrance hb restart key", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.system_led_strip_entrance_hb_restart_key", "device_id": null } } ] }, { "id": "hall_big_led_entance_manual", "automation": "- alias: hall_big_led_entance_manual\n id: hall_big_led_entance_manual\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0003991051_action\n conditions:\n - condition: template\n value_template: '{{ states(''light.esp32_strip_1s_entrance_hb_rgb'') in [''on'',''off'']\n }}'\n actions:\n - choose:\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''single'' }}'\n sequence:\n - action: light.toggle\n entity_id: light.esp32_strip_1s_entrance_hb_rgb\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''double'' }}'\n sequence:\n - action: light.turn_on\n entity_id: light.esp32_strip_1s_entrance_hb_rgb\n data:\n brightness: 255\n color_temp_kelvin: 5000\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''hold'' }}'\n sequence:\n - action: light.turn_on\n entity_id: light.esp32_strip_1s_entrance_hb_rgb\n data:\n brightness: 40\n color_temp_kelvin: 3000", "config": [ { "name": "esp32 strip 1s entrance hb rgb", "room": "hall_big", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_entrance_hb_rgb", "device_id": null } }, { "name": "action sensor entrance led", "room": "hall_big", "type": "sensor", "id": { "entity_id": "sensor.0x00158d0003991051_action", "device_id": null } } ] }, { "id": "hall_big_led_strips_timer_on", "automation": "- alias: hall_big_led_strips_timer_on\n id: hall_big_led_strips_timer_on\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: light.esp32_strip_1s_entrance_hb_rgb, light.esp32_strip_1s_wadrobe_hb_rgb\n to: 'on'\n from: 'off'\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: timer.cancel\n entity_id: timer.led_strip_day_hb, timer.led_strip_night_hb\n - action: timer.start\n data:\n entity_id: 'timer.{% if is_state(''binary_sensor.tod_day'',''on'') %}led_strip_day_hb{%else%}led_strip_night_hb{%endif%}\n\n '", "config": [ { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "esp32 strip 1s entrance hb rgb", "room": "hall_big", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_entrance_hb_rgb", "device_id": null } }, { "name": "esp32 strip 1s wadrobe hb rgb", "room": "hall_big", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_wadrobe_hb_rgb", "device_id": null } }, { "name": "timer led strip day hb", "room": "hall_big", "type": "timer", "id": { "entity_id": "timer.led_strip_day_hb", "device_id": null } }, { "name": "timer led strip night hb", "room": "hall_big", "type": "timer", "id": { "entity_id": "timer.led_strip_night_hb", "device_id": null } } ] }, { "id": "hall_big_led_strips_auto_led_off", "automation": "- alias: hall_big_led_strips_auto_led_off\n id: hall_big_led_strips_auto_led_off\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.led_strip_day_hb\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.led_strip_night_hb\n actions:\n - action: light.turn_off\n entity_id: light.esp32_strip_1s_entrance_hb_rgb, light.esp32_strip_1s_wadrobe_hb_rgb\n data:\n transition: 5", "config": [ { "name": "esp32 strip 1s entrance hb rgb", "room": "hall_big", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_entrance_hb_rgb", "device_id": null } }, { "name": "esp32 strip 1s wadrobe hb rgb", "room": "hall_big", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_wadrobe_hb_rgb", "device_id": null } }, { "name": "timer led strip day hb", "room": "hall_big", "type": "timer", "id": { "entity_id": "timer.led_strip_day_hb", "device_id": null } }, { "name": "timer led strip night hb", "room": "hall_big", "type": "timer", "id": { "entity_id": "timer.led_strip_night_hb", "device_id": null } } ] }, { "id": "hall_big_led_strips_timer_restart", "automation": "- alias: hall_big_led_strips_timer_restart\n id: hall_big_led_strips_timer_restart\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0001e05856_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0002b482e9_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0001d5995e_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.582d34609600_motion\n - trigger: state\n entity_id: binary_sensor.g5_flex_entrance_motion\n from: 'off'\n to: 'on'\n conditions:\n - condition: state\n entity_id: group.lights_strips_hb\n state: 'on'\n - condition: template\n value_template: '{{(as_timestamp(now())-as_timestamp(state_attr(''automation.hall_big_led_strips_timer_restart'',\n ''last_triggered''),0)|int(0)) > 5 }}'\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'on'\n sequence:\n - action: timer.cancel\n entity_id: timer.led_strip_day_hb\n - action: timer.start\n entity_id: timer.led_strip_day_hb\n - conditions:\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'off'\n sequence:\n - action: timer.cancel\n entity_id: timer.led_strip_night_hb\n - action: timer.start\n entity_id: timer.led_strip_night_hb", "config": [ { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "entrance motion sensor", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001e05856_motion", "device_id": null } }, { "name": "fridge motion sensor", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b482e9_motion", "device_id": null } }, { "name": "wardrobe motion sensor", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.582d34609600_motion", "device_id": null } }, { "name": "timer led strip day hb", "room": "hall_big", "type": "timer", "id": { "entity_id": "timer.led_strip_day_hb", "device_id": null } }, { "name": "timer led strip night hb", "room": "hall_big", "type": "timer", "id": { "entity_id": "timer.led_strip_night_hb", "device_id": null } }, { "name": "g5 flex entrance motion", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.g5_flex_entrance_motion", "device_id": null } }, { "name": "Motion Sensor 1d5995e", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001d5995e_motion", "device_id": null } }, { "name": "Lights S Group", "room": "Sasha Room", "type": "group", "id": { "entity_id": "group.lights_s", "device_id": null } }, { "name": "Lights St Group", "room": null, "type": "group", "id": { "entity_id": "group.lights_st", "device_id": null } }, { "name": "Lights Strips HB Group", "room": "Hall Big", "type": "group", "id": { "entity_id": "group.lights_strips_hb", "device_id": null } } ] }, { "id": "hall_big_main_light_off_with_occupancy", "automation": "- alias: hall_big_main_light_off_with_occupancy\n id: hall_big_main_light_off_with_occupancy\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.occupancy_hb\n to: 'off'\n for:\n hours: 1\n conditions:\n - condition: state\n entity_id: group.lights_main_hb\n state: 'on'\n actions:\n - action: light.turn_off\n entity_id: light.0x00158d000223921b_channel_1, light.0x00158d000253f04a_channel_2", "config": [ { "name": "channel 1 light", "room": "hall_big", "type": "light", "id": { "entity_id": "light.0x00158d000223921b_channel_1", "device_id": null } }, { "name": "channel 2 light fridge", "room": "hall_big", "type": "light", "id": { "entity_id": "light.0x00158d000253f04a_channel_2", "device_id": null } }, { "name": "occupancy hb", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.occupancy_hb", "device_id": null } }, { "name": "Lights Main HB Group", "room": "Hall Big", "type": "group", "id": { "entity_id": "group.lights_main_hb", "device_id": null } } ] }, { "id": "hall_big_bedside_lamp_restart", "automation": "- alias: hall_big_bedside_lamp_restart\n id: hall_big_bedside_lamp_restart\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /1\n conditions:\n - condition: state\n entity_id: light.bedside\n state: unavailable\n for:\n minutes: 2\n - condition: state\n entity_id: switch.system_bedside_restart_key\n state: 'on'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: template\n value_template: '{% set ignore = [''unknown'', ''unavailable'', ''none''] %} {{\n states(''switch.0x00158d00039bd56d_plug'') not in ignore }}\n\n '\n actions:\n - repeat:\n while:\n - condition: state\n entity_id: light.bedside\n state: unavailable\n - condition: template\n value_template: '{{ repeat.index <= 5 }}'\n sequence:\n - action: switch.turn_off\n entity_id: switch.0x00158d00039bd56d_plug\n - delay:\n seconds: 15\n - action: switch.turn_on\n entity_id: switch.0x00158d00039bd56d_plug\n - action: notify.telegram\n data:\n message: 🚨 Bedside restart done({{repeat.index}})!\n - delay:\n seconds: 30\n - condition: state\n entity_id: light.bedside\n state: unavailable\n - action: notify.telegram\n data:\n message: 🚨 Bedside restart unsuccessful!\n - action: switch.turn_off\n entity_id: switch.system_bedside_restart_key", "config": [ { "name": "bedside light", "room": "hall_big", "type": "light", "id": { "entity_id": "light.bedside", "device_id": null } }, { "name": "system bedside restart key", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.system_bedside_restart_key", "device_id": null } }, { "name": "bedside plug", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.0x00158d00039bd56d_plug", "device_id": null } } ] }, { "id": "hall_big_bedside_restart_key_toggle", "automation": "- alias: hall_big_bedside_restart_key_toggle\n id: hall_big_bedside_restart_key_toggle\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: light.bedside\n from: unavailable\n actions:\n - action: switch.turn_on\n entity_id: switch.system_bedside_restart_key", "config": [ { "name": "bedside light", "room": "hall_big", "type": "light", "id": { "entity_id": "light.bedside", "device_id": null } }, { "name": "system bedside restart key", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.system_bedside_restart_key", "device_id": null } } ] }, { "id": "hall_small_auto_night_light", "automation": "- alias: hall_small_auto_night_light\n id: hall_small_auto_night_light\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0001ae9f61_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0002b43ad4_motion\n - trigger: state\n entity_id:\n - binary_sensor.0x00158d00025315e9_contact\n - binary_sensor.0x00158d0002a14c5e_contact\n - binary_sensor.0x00158d0001ef2ffc_contact\n from: 'off'\n to: 'on'\n conditions:\n - condition: state\n entity_id: light.round_led_k\n state: 'off'\n - condition: state\n entity_id: group.lights_main_hs\n state: 'off'\n - condition: state\n entity_id: binary_sensor.light_outside_mi\n state: 'off'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: light.turn_on\n entity_id: light.mono_strip_1_light\n data:\n brightness: 100", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "bathroom contact sensor", "room": "bathroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002a14c5e_contact", "device_id": null } }, { "name": "hall small motion sensor 1", "room": "hall_small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001ae9f61_motion", "device_id": null } }, { "name": "hall small motion sensor 2", "room": "hall_small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b43ad4_motion", "device_id": null } }, { "name": "wardrobe contact", "room": "hall_small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d00025315e9_contact", "device_id": null } }, { "name": "sasha door contact", "room": "hall_small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001ef2ffc_contact", "device_id": null } }, { "name": "round led k", "room": "kitchen", "type": "light", "id": { "entity_id": "light.round_led_k", "device_id": null } }, { "name": "light outside mi", "room": "outside", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.light_outside_mi", "device_id": null } }, { "name": "mono strip 1 light", "room": "hall_small", "type": "light", "id": { "entity_id": "light.mono_strip_1_light", "device_id": null } }, { "name": "Lights Main HS Group", "room": "Hall Small", "type": "group", "id": { "entity_id": "group.lights_main_hs", "device_id": null } } ] }, { "id": "hall_small_main_lamp_on_single", "automation": "- alias: hall_small_main_lamp_on_single\n id: hall_small_main_lamp_on_single\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0002a36433_action\n click_type: button_1_single\n conditions:\n - condition: template\n value_template: '{{ states(''light.round_led_hs'') in [''on'',''off''] }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - if:\n - condition: state\n entity_id: binary_sensor.round_led_hs_nightlight\n state: 'on'\n - condition: state\n entity_id: light.round_led_hs\n state: 'off'\n then:\n - action: yeelight.set_mode\n data:\n entity_id: light.round_led_hs\n mode: normal\n - choose:\n - conditions:\n - condition: state\n entity_id: light.round_led_hs\n state: 'on'\n sequence:\n - action: light.turn_off\n entity_id: light.round_led_hs\n - conditions:\n - condition: state\n entity_id: light.round_led_hs\n state: 'off'\n sequence:\n - action: light.turn_on\n entity_id: light.round_led_hs\n data:\n brightness: 65\n color_temp_kelvin: 5000", "config": [ { "name": "round led hs", "room": "hall_small", "type": "light", "id": { "entity_id": "light.round_led_hs", "device_id": null } }, { "name": "round led hs nightlight", "room": "hall_small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.round_led_hs_nightlight", "device_id": null } }, { "name": "Action Sensor 2a36433", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x00158d0002a36433_action", "device_id": null } } ] }, { "id": "hall_small_main_lamp_on_double", "automation": "- alias: hall_small_main_lamp_on_double\n id: hall_small_main_lamp_on_double\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0002a36433_action\n click_type: button_1_double\n conditions:\n - condition: template\n value_template: '{{ states(''light.round_led_k'') in [''on'',''off''] }}'\n actions:\n - if:\n - condition: state\n entity_id: binary_sensor.round_led_hs_nightlight\n state: 'on'\n - condition: state\n entity_id: light.round_led_hs\n state: 'off'\n then:\n - action: yeelight.set_mode\n data:\n entity_id: light.round_led_hs\n mode: normal\n - action: light.turn_on\n entity_id: light.round_led_hs\n data:\n brightness: 230\n color_temp_kelvin: 5000", "config": [ { "name": "round led k", "room": "kitchen", "type": "light", "id": { "entity_id": "light.round_led_k", "device_id": null } }, { "name": "round led hs", "room": "hall_small", "type": "light", "id": { "entity_id": "light.round_led_hs", "device_id": null } }, { "name": "round led hs nightlight", "room": "hall_small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.round_led_hs_nightlight", "device_id": null } }, { "name": "Action Sensor 2a36433", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x00158d0002a36433_action", "device_id": null } } ] }, { "id": "hall_small_main_lamp_restart", "automation": "- alias: hall_small_main_lamp_restart\n id: hall_small_main_lamp_restart\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /1\n conditions:\n - condition: state\n entity_id: light.round_led_hs\n state: unavailable\n for:\n minutes: 2\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: state\n entity_id: switch.system_round_led_hs_restart_key\n state: 'on'\n - condition: template\n value_template: '{% set ignore = [''unknown'', ''unavailable'', ''none''] %} {{\n states(''switch.0x00158d0002a36433_channel_1'') not in ignore }}\n\n '\n actions:\n - repeat:\n while:\n - condition: state\n entity_id: light.round_led_hs\n state: unavailable\n - condition: template\n value_template: '{{ repeat.index <= 5 }}'\n sequence:\n - action: switch.turn_off\n entity_id: switch.0x00158d0002a36433_channel_1\n - delay:\n seconds: 15\n - action: switch.turn_on\n entity_id: switch.0x00158d0002a36433_channel_1\n - action: notify.telegram\n data:\n message: 🚨 Round LED HS restart done({{repeat.index}})!\n - delay:\n seconds: 30\n - condition: state\n entity_id: light.round_led_hs\n state: unavailable\n - action: notify.telegram\n data:\n message: 🚨 Round LED HS restart unsuccessful!\n - action: switch.turn_off\n entity_id: switch.system_round_led_hs_restart_key", "config": [ { "name": "round led hs", "room": "hall_small", "type": "light", "id": { "entity_id": "light.round_led_hs", "device_id": null } }, { "name": "system round led hs restart key", "room": "hall_small", "type": "switch", "id": { "entity_id": "switch.system_round_led_hs_restart_key", "device_id": null } }, { "name": "round led hs channel 1", "room": "hall_small", "type": "switch", "id": { "entity_id": "switch.0x00158d0002a36433_channel_1", "device_id": null } } ] }, { "id": "hall_small_main_lamp_restart_key_toggle", "automation": "- alias: hall_small_main_lamp_restart_key_toggle\n id: hall_small_main_lamp_restart_key_toggle\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: light.round_led_hs\n from: unavailable\n actions:\n - action: switch.turn_on\n entity_id: switch.system_round_led_hs_restart_key", "config": [ { "name": "round led hs", "room": "hall_small", "type": "light", "id": { "entity_id": "light.round_led_hs", "device_id": null } }, { "name": "system round led hs restart key", "room": "hall_small", "type": "switch", "id": { "entity_id": "switch.system_round_led_hs_restart_key", "device_id": null } } ] }, { "id": "hall_small_led_strip_timer_on", "automation": "- alias: hall_small_led_strip_timer_on\n id: hall_small_led_strip_timer_on\n initial_state: true\n triggers:\n - trigger: state\n entity_id: light.mono_strip_1_light\n to: 'on'\n from: 'off'\n actions:\n - action: timer.cancel\n entity_id: timer.led_strip_night_hs\n - action: timer.start\n entity_id: timer.led_strip_night_hs", "config": [ { "name": "mono strip 1 light", "room": "hall_small", "type": "light", "id": { "entity_id": "light.mono_strip_1_light", "device_id": null } }, { "name": "timer led strip night hs", "room": "hall_small", "type": "timer", "id": { "entity_id": "timer.led_strip_night_hs", "device_id": null } } ] }, { "id": "hall_small_led_strip_auto_led_off", "automation": "- alias: hall_small_led_strip_auto_led_off\n id: hall_small_led_strip_auto_led_off\n initial_state: true\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.led_strip_night_hs\n actions:\n - action: light.turn_off\n entity_id: light.mono_strip_1_light\n data:\n transition: 5", "config": [ { "name": "mono strip 1 light", "room": "hall_small", "type": "light", "id": { "entity_id": "light.mono_strip_1_light", "device_id": null } }, { "name": "timer led strip night hs", "room": "hall_small", "type": "timer", "id": { "entity_id": "timer.led_strip_night_hs", "device_id": null } } ] }, { "id": "hall_small_led_strip_timer_restart", "automation": "- alias: hall_small_led_strip_timer_restart\n id: hall_small_led_strip_timer_restart\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0001ae9f61_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0002b43ad4_motion\n conditions:\n - condition: template\n value_template: '{{(as_timestamp(now())-as_timestamp(state_attr(''automation.hall_small_led_strip_timer_restart'',\n ''last_triggered''),0)|int(0)) > 5 }}'\n - condition: state\n entity_id: light.mono_strip_1_light\n state: 'on'\n actions:\n - action: timer.cancel\n entity_id: timer.led_strip_night_hs\n - action: timer.start\n entity_id: timer.led_strip_night_hs", "config": [ { "name": "hall small motion sensor 1", "room": "hall_small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001ae9f61_motion", "device_id": null } }, { "name": "hall small motion sensor 2", "room": "hall_small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b43ad4_motion", "device_id": null } }, { "name": "mono strip 1 light", "room": "hall_small", "type": "light", "id": { "entity_id": "light.mono_strip_1_light", "device_id": null } }, { "name": "timer led strip night hs", "room": "hall_small", "type": "timer", "id": { "entity_id": "timer.led_strip_night_hs", "device_id": null } } ] }, { "id": "hall_small_timer_restart", "automation": "- alias: hall_small_timer_restart\n id: hall_small_timer_restart\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0002b43ad4_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0001ae9f61_motion\n conditions:\n - condition: template\n value_template: '{{ not is_state(''light.round_led_hs'', ''off'') }}'\n - condition: template\n value_template: '{{(as_timestamp(now()) - as_timestamp(state_attr(''automation.hall_small_timer_restart'',\n ''last_triggered''),0)|int(0)) > 5 }}'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_hs\n - action: timer.start\n entity_id: timer.main_light_hs", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "hall small motion sensor 1", "room": "hall_small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001ae9f61_motion", "device_id": null } }, { "name": "hall small motion sensor 2", "room": "hall_small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b43ad4_motion", "device_id": null } }, { "name": "round led hs", "room": "hall_small", "type": "light", "id": { "entity_id": "light.round_led_hs", "device_id": null } }, { "name": "timer main light hs", "room": "hall_small", "type": "timer", "id": { "entity_id": "timer.main_light_hs", "device_id": null } } ] }, { "id": "hall_small_timer_off", "automation": "- alias: hall_small_timer_off\n id: hall_small_timer_off\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: light.round_led_hs\n to: 'off'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_hs", "config": [ { "name": "round led hs", "room": "hall_small", "type": "light", "id": { "entity_id": "light.round_led_hs", "device_id": null } }, { "name": "timer main light hs", "room": "hall_small", "type": "timer", "id": { "entity_id": "timer.main_light_hs", "device_id": null } } ] }, { "id": "hall_small_timer_on", "automation": "- alias: hall_small_timer_on\n id: hall_small_timer_on\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: light.round_led_hs\n to: 'on'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_hs\n - action: timer.start\n entity_id: timer.main_light_hs", "config": [ { "name": "round led hs", "room": "hall_small", "type": "light", "id": { "entity_id": "light.round_led_hs", "device_id": null } }, { "name": "timer main light hs", "room": "hall_small", "type": "timer", "id": { "entity_id": "timer.main_light_hs", "device_id": null } } ] }, { "id": "hall_small_auto_light_off", "automation": "- alias: hall_small_auto_light_off\n id: hall_small_auto_light_off\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.main_light_hs\n conditions:\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'on'\n actions:\n - action: light.turn_off\n entity_id: light.round_led_hs\n data:\n transition: 15", "config": [ { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "round led hs", "room": "hall_small", "type": "light", "id": { "entity_id": "light.round_led_hs", "device_id": null } }, { "name": "timer main light hs", "room": "hall_small", "type": "timer", "id": { "entity_id": "timer.main_light_hs", "device_id": null } } ] }, { "id": "hall_small_main_light_off_with_occupancy", "automation": "- alias: hall_small_main_light_off_with_occupancy\n id: hall_small_main_light_off_with_occupancy\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.occupancy_hs\n to: 'off'\n for:\n hours: 1\n conditions:\n - condition: state\n entity_id: group.lights_main_hs\n state: 'on'\n actions:\n - action: light.turn_off\n entity_id: light.round_led_hs, light.mono_strip_1_light\n data:\n transition: 15", "config": [ { "name": "mono strip 1 light", "room": "hall_small", "type": "light", "id": { "entity_id": "light.mono_strip_1_light", "device_id": null } }, { "name": "round led hs", "room": "hall_small", "type": "light", "id": { "entity_id": "light.round_led_hs", "device_id": null } }, { "name": "occupancy hs", "room": "hall_small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.occupancy_hs", "device_id": null } }, { "name": "Lights Main HS Group", "room": "Hall Small", "type": "group", "id": { "entity_id": "group.lights_main_hs", "device_id": null } } ] }, { "id": "kitchen_timer_restart", "automation": "- alias: kitchen_timer_restart\n id: kitchen_timer_restart\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0002b4729d_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0002b48381_motion\n - trigger: state\n entity_id: sensor.0x00158d0002a2412d_action\n to:\n - vibration\n - tilt\n conditions:\n - condition: state\n entity_id: group.lights_main_k\n state: 'on'\n - condition: template\n value_template: '{{(as_timestamp(now()) - as_timestamp(state_attr(''automation.kitchen_timer_restart'',\n ''last_triggered''),0)|int(0)) > 5 }}'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_k\n - action: timer.start\n entity_id: timer.main_light_k", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "motion sensor kitchen 1", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b4729d_motion", "device_id": null } }, { "name": "motion sensor kitchen 2", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b48381_motion", "device_id": null } }, { "name": "kitchen table action", "room": "kitchen", "type": "sensor", "id": { "entity_id": "sensor.0x00158d0002a2412d_action", "device_id": null } }, { "name": "timer main light k", "room": "kitchen", "type": "timer", "id": { "entity_id": "timer.main_light_k", "device_id": null } }, { "name": "Lights Main K Group", "room": "Kitchen", "type": "group", "id": { "entity_id": "group.lights_main_k", "device_id": null } } ] }, { "id": "kitchen_timer_off", "automation": "- alias: kitchen_timer_off\n id: kitchen_timer_off\n initial_state: true\n triggers:\n - trigger: state\n entity_id: light.round_led_k\n to: 'off'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_k, timer.main_light_delay_k\n - action: timer.start\n entity_id: timer.main_light_delay_k", "config": [ { "name": "round led k", "room": "kitchen", "type": "light", "id": { "entity_id": "light.round_led_k", "device_id": null } }, { "name": "timer main light k", "room": "kitchen", "type": "timer", "id": { "entity_id": "timer.main_light_k", "device_id": null } }, { "name": "timer main light delay k", "room": "kitchen", "type": "timer", "id": { "entity_id": "timer.main_light_delay_k", "device_id": null } } ] }, { "id": "kitchen_timer_on", "automation": "- alias: kitchen_timer_on\n id: kitchen_timer_on\n initial_state: true\n triggers:\n - trigger: state\n entity_id: light.round_led_k\n to: 'on'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_k\n - action: timer.start\n entity_id: timer.main_light_k\n - action: light.turn_off\n entity_id: light.esp32_node_k_light, light.mono_strip_1_light\n data:\n transition: 5", "config": [ { "name": "round led k", "room": "kitchen", "type": "light", "id": { "entity_id": "light.round_led_k", "device_id": null } }, { "name": "mono strip 1 light", "room": "hall_small", "type": "light", "id": { "entity_id": "light.mono_strip_1_light", "device_id": null } }, { "name": "timer main light k", "room": "kitchen", "type": "timer", "id": { "entity_id": "timer.main_light_k", "device_id": null } }, { "name": "esp32 node k light", "room": "kitchen", "type": "light", "id": { "entity_id": "light.esp32_node_k_light", "device_id": null } } ] }, { "id": "kitchen_auto_light_off", "automation": "- alias: kitchen_auto_light_off\n id: kitchen_auto_light_off\n initial_state: true\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.main_light_k\n conditions:\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'on'\n - condition: state\n entity_id: binary_sensor.presence_k\n state: 'off'\n actions:\n - action: light.turn_off\n entity_id: light.round_led_k\n data:\n transition: 15\n - action: light.turn_off\n entity_id: light.d1mini_light_l_led, light.sonoff_mini_4_led, light.esp8266_hood_k_main", "config": [ { "name": "presence kitchen", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.presence_k", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "round led k", "room": "kitchen", "type": "light", "id": { "entity_id": "light.round_led_k", "device_id": null } }, { "name": "timer main light k", "room": "kitchen", "type": "timer", "id": { "entity_id": "timer.main_light_k", "device_id": null } }, { "name": "d1mini light l led", "room": "kitchen", "type": "light", "id": { "entity_id": "light.d1mini_light_l_led", "device_id": null } }, { "name": "sonoff mini 4 led", "room": "kitchen", "type": "light", "id": { "entity_id": "light.sonoff_mini_4_led", "device_id": null } }, { "name": "esp8266 hood main light", "room": "kitchen", "type": "light", "id": { "entity_id": "light.esp8266_hood_k_main", "device_id": null } } ] }, { "id": "kitchen_auto_light_on", "automation": "- alias: kitchen_auto_light_on\n id: kitchen_auto_light_on\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0002b4729d_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0002b48381_motion\n conditions:\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'on'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: state\n entity_id: group.lights_main_k\n state: 'off'\n - condition: state\n entity_id: binary_sensor.light_outside_mi\n state: 'off'\n - condition: state\n entity_id: timer.main_light_delay_k\n state: idle\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: light.turn_on\n entity_id: light.esp32_node_k_light", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "motion sensor kitchen 1", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b4729d_motion", "device_id": null } }, { "name": "motion sensor kitchen 2", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b48381_motion", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "light outside mi", "room": "outside", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.light_outside_mi", "device_id": null } }, { "name": "timer main light delay k", "room": "kitchen", "type": "timer", "id": { "entity_id": "timer.main_light_delay_k", "device_id": null } }, { "name": "esp32 node k light", "room": "kitchen", "type": "light", "id": { "entity_id": "light.esp32_node_k_light", "device_id": null } }, { "name": "Lights Main K Group", "room": "Kitchen", "type": "group", "id": { "entity_id": "group.lights_main_k", "device_id": null } } ] }, { "id": "kitchen_auto_night_light", "automation": "- alias: kitchen_auto_night_light\n id: kitchen_auto_night_light\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0002b4729d_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0002b48381_motion\n conditions:\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'off'\n - condition: template\n value_template: '{{ not is_state(''light.esp32_node_k_light'', ''on'') }}'\n - condition: state\n entity_id: group.lights_main_k\n state: 'off'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: template\n value_template: '{{as_timestamp(now())-as_timestamp(state_attr(''automation.hall_small_auto_night_light'',\n ''last_triggered''),0) < 600 }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: light.turn_on\n entity_id: light.esp32_node_k_light\n data:\n brightness: 255", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "motion sensor kitchen 1", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b4729d_motion", "device_id": null } }, { "name": "motion sensor kitchen 2", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b48381_motion", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "esp32 node k light", "room": "kitchen", "type": "light", "id": { "entity_id": "light.esp32_node_k_light", "device_id": null } }, { "name": "Lights Main K Group", "room": "Kitchen", "type": "group", "id": { "entity_id": "group.lights_main_k", "device_id": null } } ] }, { "id": "kitchen_main_lamp_restart", "automation": "- alias: kitchen_main_lamp_restart\n id: kitchen_main_lamp_restart\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /1\n conditions:\n - condition: state\n entity_id: light.round_led_k\n state: unavailable\n for:\n minutes: 2\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: state\n entity_id: switch.system_round_led_k_restart_key\n state: 'on'\n - condition: template\n value_template: '{% set ignore = [''unknown'', ''unavailable'', ''none''] %} {{\n states(''switch.0x00158d0002a36f7f_channel_2'') not in ignore }}\n\n '\n actions:\n - repeat:\n while:\n - condition: state\n entity_id: light.round_led_k\n state: unavailable\n - condition: template\n value_template: '{{ repeat.index <= 5 }}'\n sequence:\n - action: switch.turn_off\n entity_id: switch.0x00158d0002a36f7f_channel_2\n - delay:\n seconds: 15\n - action: switch.turn_on\n entity_id: switch.0x00158d0002a36f7f_channel_2\n - action: notify.telegram\n data:\n message: 🚨 Round LED K restart done({{repeat.index}})!\n - delay:\n seconds: 30\n - if:\n - condition: state\n entity_id: light.round_led_k\n state: unavailable\n then:\n - action: notify.telegram\n data:\n message: 🚨 Round LED K restart unsuccessful!\n - action: switch.turn_off\n entity_id: switch.system_round_led_k_restart_key\n else:\n - action: light.turn_{{ states(\"binary_sensor.round_led_k_prev\") | lower }}\n entity_id: light.round_led_k\n - action: switch.turn_on\n entity_id: switch.system_round_led_k_restart_key", "config": [ { "name": "round led k", "room": "kitchen", "type": "light", "id": { "entity_id": "light.round_led_k", "device_id": null } }, { "name": "system round led k restart key", "room": "kitchen", "type": "switch", "id": { "entity_id": "switch.system_round_led_k_restart_key", "device_id": null } }, { "name": "round led k channel 2", "room": "kitchen", "type": "switch", "id": { "entity_id": "switch.0x00158d0002a36f7f_channel_2", "device_id": null } }, { "name": "round led k prev", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.round_led_k_prev", "device_id": null } } ] }, { "id": "kitchen_main_lamp_restart_key_toggle", "automation": "- alias: kitchen_main_lamp_restart_key_toggle\n id: kitchen_main_lamp_restart_key_toggle\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: light.round_led_k\n from: unavailable\n actions:\n - action: switch.turn_on\n entity_id: switch.system_round_led_k_restart_key", "config": [ { "name": "round led k", "room": "kitchen", "type": "light", "id": { "entity_id": "light.round_led_k", "device_id": null } }, { "name": "system round led k restart key", "room": "kitchen", "type": "switch", "id": { "entity_id": "switch.system_round_led_k_restart_key", "device_id": null } } ] }, { "id": "kitchen_main_lamp_switch_on_if_off", "automation": "- alias: kitchen_main_lamp_switch_on_if_off\n id: kitchen_main_lamp_switch_on_if_off\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0002a36f7f_action\n click_type: button_2_single\n conditions:\n - condition: state\n entity_id: switch.0x00158d0002a36f7f_channel_2\n state: 'off'\n actions:\n - action: switch.turn_on\n entity_id: switch.0x00158d0002a36f7f_channel_2", "config": [ { "name": "round led k channel 2", "room": "kitchen", "type": "switch", "id": { "entity_id": "switch.0x00158d0002a36f7f_channel_2", "device_id": null } }, { "name": "action sensor round led k", "room": "kitchen", "type": "sensor", "id": { "entity_id": "sensor.0x00158d0002a36f7f_action", "device_id": null } } ] }, { "id": "kitchen_main_lamp_on", "automation": "- alias: kitchen_main_lamp_on\n id: kitchen_main_lamp_on\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0002a36f7f_action\n click_type: button_2_single\n conditions:\n - condition: template\n value_template: '{{ states(''light.round_led_k'') in [''on'',''off''] }}'\n - condition: state\n entity_id: switch.0x00158d0002a36f7f_channel_2\n state: 'on'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: binary_sensor.round_led_k_nightlight\n state: 'on'\n - condition: state\n entity_id: light.round_led_k\n state: 'off'\n sequence:\n - action: yeelight.set_mode\n data:\n entity_id: light.round_led_k\n mode: normal\n - action: light.turn_on\n entity_id: light.round_led_k\n data:\n brightness: 230\n color_temp_kelvin: 5000\n - conditions:\n - condition: state\n entity_id: binary_sensor.round_led_k_nightlight\n state: 'off'\n - condition: state\n entity_id: light.round_led_k\n state: 'on'\n sequence:\n - action: light.turn_off\n entity_id: light.round_led_k\n - delay: 00:00:01\n - condition: state\n entity_id: light.round_led_k\n state: 'on'\n - action: light.turn_off\n entity_id: light.round_led_k\n - conditions:\n - condition: state\n entity_id: light.round_led_k\n state: 'off'\n - condition: state\n entity_id: binary_sensor.round_led_k_nightlight\n state: 'off'\n sequence:\n - action: light.turn_on\n entity_id: light.round_led_k\n data:\n brightness: 230\n color_temp_kelvin: 5000", "config": [ { "name": "round led k", "room": "kitchen", "type": "light", "id": { "entity_id": "light.round_led_k", "device_id": null } }, { "name": "round led k channel 2", "room": "kitchen", "type": "switch", "id": { "entity_id": "switch.0x00158d0002a36f7f_channel_2", "device_id": null } }, { "name": "round led k nightlight", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.round_led_k_nightlight", "device_id": null } }, { "name": "action sensor round led k", "room": "kitchen", "type": "sensor", "id": { "entity_id": "sensor.0x00158d0002a36f7f_action", "device_id": null } } ] }, { "id": "kitchen_main_lamp_on_full", "automation": "- alias: kitchen_main_lamp_on_full\n id: kitchen_main_lamp_on_full\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0002a36f7f_action\n click_type: button_2_double\n conditions:\n - condition: template\n value_template: '{{ states(''light.round_led_k'') in [''on'',''off''] }}'\n - condition: state\n entity_id: switch.0x00158d0002a36f7f_channel_2\n state: 'on'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - if:\n - condition: state\n entity_id: binary_sensor.round_led_k_nightlight\n state: 'on'\n - condition: state\n entity_id: light.round_led_k\n state: 'off'\n then:\n - action: yeelight.set_mode\n data:\n entity_id: light.round_led_k\n mode: normal\n - action: light.turn_on\n entity_id: light.round_led_k\n data:\n brightness: 230\n color_temp_kelvin: 5000", "config": [ { "name": "round led k", "room": "kitchen", "type": "light", "id": { "entity_id": "light.round_led_k", "device_id": null } }, { "name": "round led k channel 2", "room": "kitchen", "type": "switch", "id": { "entity_id": "switch.0x00158d0002a36f7f_channel_2", "device_id": null } }, { "name": "round led k nightlight", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.round_led_k_nightlight", "device_id": null } }, { "name": "action sensor round led k", "room": "kitchen", "type": "sensor", "id": { "entity_id": "sensor.0x00158d0002a36f7f_action", "device_id": null } } ] }, { "id": "kitchen_led_strips_timer", "automation": "- alias: kitchen_led_strips_timer\n id: kitchen_led_strips_timer\n initial_state: true\n triggers:\n - trigger: state\n entity_id: light.esp32_node_k_light\n to: 'on'\n actions:\n - action: timer.cancel\n entity_id: timer.led_strip_night_k\n - action: timer.start\n entity_id: timer.led_strip_night_k", "config": [ { "name": "esp32 node k light", "room": "kitchen", "type": "light", "id": { "entity_id": "light.esp32_node_k_light", "device_id": null } }, { "name": "timer led strip night k", "room": "kitchen", "type": "timer", "id": { "entity_id": "timer.led_strip_night_k", "device_id": null } } ] }, { "id": "kitchen_led_strip_auto_led_off", "automation": "- alias: kitchen_led_strip_auto_led_off\n id: kitchen_led_strip_auto_led_off\n initial_state: true\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.led_strip_night_k\n actions:\n - action: light.turn_off\n entity_id: light.esp32_node_k_light\n data:\n transition: 5", "config": [ { "name": "esp32 node k light", "room": "kitchen", "type": "light", "id": { "entity_id": "light.esp32_node_k_light", "device_id": null } }, { "name": "timer led strip night k", "room": "kitchen", "type": "timer", "id": { "entity_id": "timer.led_strip_night_k", "device_id": null } } ] }, { "id": "kitchen_led_strip_timer_restart", "automation": "- alias: kitchen_led_strip_timer_restart\n id: kitchen_led_strip_timer_restart\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0002b4729d_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0002b48381_motion\n - trigger: state\n entity_id: light.esp32_node_k_light\n to: 'on'\n conditions:\n - condition: state\n entity_id: light.esp32_node_k_light\n state: 'on'\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'off'\n - condition: template\n value_template: '{{(as_timestamp(now())-as_timestamp(state_attr(''automation.kitchen_led_strip_timer_restart'',\n ''last_triggered''),0)|int(0)) > 5 }}'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n actions:\n - action: timer.cancel\n entity_id: timer.led_strip_night_k\n - action: timer.start\n entity_id: timer.led_strip_night_k", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "motion sensor kitchen 1", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b4729d_motion", "device_id": null } }, { "name": "motion sensor kitchen 2", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b48381_motion", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "esp32 node k light", "room": "kitchen", "type": "light", "id": { "entity_id": "light.esp32_node_k_light", "device_id": null } }, { "name": "timer led strip night k", "room": "kitchen", "type": "timer", "id": { "entity_id": "timer.led_strip_night_k", "device_id": null } } ] }, { "id": "kitchen_night_aux_light", "automation": "- alias: kitchen_night_aux_light\n id: kitchen_night_aux_light\n initial_state: true\n triggers:\n - trigger: state\n entity_id: light.round_led_k\n to: 'off'\n from: 'on'\n conditions:\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: state\n entity_id:\n - light.d1mini_light_l_led\n - light.sonoff_mini_4_led\n - light.esp8266_hood_k_main\n - light.esp32_node_k_light\n - light.mono_strip_1_light\n - light.round_led_hs\n state: 'off'\n - condition: state\n entity_id: binary_sensor.light_outside_mi\n state: 'off'\n actions:\n - action: light.turn_on\n entity_id: light.esp32_node_k_light\n data:\n brightness: 255\n - action: light.turn_on\n entity_id: light.mono_strip_1_light\n data:\n brightness: 128", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "round led k", "room": "kitchen", "type": "light", "id": { "entity_id": "light.round_led_k", "device_id": null } }, { "name": "light outside mi", "room": "outside", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.light_outside_mi", "device_id": null } }, { "name": "mono strip 1 light", "room": "hall_small", "type": "light", "id": { "entity_id": "light.mono_strip_1_light", "device_id": null } }, { "name": "round led hs", "room": "hall_small", "type": "light", "id": { "entity_id": "light.round_led_hs", "device_id": null } }, { "name": "esp32 node k light", "room": "kitchen", "type": "light", "id": { "entity_id": "light.esp32_node_k_light", "device_id": null } }, { "name": "d1mini light l led", "room": "kitchen", "type": "light", "id": { "entity_id": "light.d1mini_light_l_led", "device_id": null } }, { "name": "sonoff mini 4 led", "room": "kitchen", "type": "light", "id": { "entity_id": "light.sonoff_mini_4_led", "device_id": null } }, { "name": "esp8266 hood main light", "room": "kitchen", "type": "light", "id": { "entity_id": "light.esp8266_hood_k_main", "device_id": null } } ] }, { "id": "kitchen_main_light_off_with_occupancy", "automation": "- alias: kitchen_main_light_off_with_occupancy\n id: kitchen_main_light_off_with_occupancy\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.presence_k\n to: 'off'\n for:\n minutes: 15\n conditions:\n - condition: state\n entity_id: group.lights_main_k\n state: 'on'\n actions:\n - action: light.turn_off\n entity_id: light.d1mini_light_l_led, light.sonoff_mini_4_led, light.esp8266_hood_k_main\n - action: light.turn_off\n entity_id: light.round_led_k\n data:\n transition: 15", "config": [ { "name": "presence kitchen", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.presence_k", "device_id": null } }, { "name": "round led k", "room": "kitchen", "type": "light", "id": { "entity_id": "light.round_led_k", "device_id": null } }, { "name": "d1mini light l led", "room": "kitchen", "type": "light", "id": { "entity_id": "light.d1mini_light_l_led", "device_id": null } }, { "name": "sonoff mini 4 led", "room": "kitchen", "type": "light", "id": { "entity_id": "light.sonoff_mini_4_led", "device_id": null } }, { "name": "esp8266 hood main light", "room": "kitchen", "type": "light", "id": { "entity_id": "light.esp8266_hood_k_main", "device_id": null } }, { "name": "Lights Main K Group", "room": "Kitchen", "type": "group", "id": { "entity_id": "group.lights_main_k", "device_id": null } } ] }, { "id": "master_bedroom_table_lamp", "automation": "- alias: master_bedroom_table_lamp\n id: master_bedroom_table_lamp\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x04cf8cdf3c77cc5f_action\n conditions:\n - condition: template\n value_template: '{{ states(''light.0x54ef441000c88fa8_light'') in [''on'',''off'']\n }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - choose:\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''single'' or trigger.event.data.click_type\n == ''button_1_single'' }}'\n sequence:\n - action: light.toggle\n entity_id: light.0x54ef441000c88fa8_light\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''double'' or trigger.event.data.click_type\n == ''button_1_double'' }}'\n sequence:\n - action: light.turn_on\n entity_id: light.0x54ef441000c88fa8_light\n data:\n brightness: 255\n color_temp_kelvin: 5000\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''hold'' or trigger.event.data.click_type\n == ''button_1_hold'' }}'\n sequence:\n - action: light.turn_on\n entity_id: light.0x54ef441000c88fa8_light\n data:\n brightness: 14\n color_temp_kelvin: 3000", "config": [ { "name": "table lamp master bedroom", "room": "master_bedroom", "type": "light", "id": { "entity_id": "light.0x54ef441000c88fa8_light", "device_id": null } }, { "name": "action sensor table lamp", "room": "master_bedroom", "type": "sensor", "id": { "entity_id": "sensor.0x04cf8cdf3c77cc5f_action", "device_id": null } } ] }, { "id": "master_bedroom_main_lamp_right_button", "automation": "- alias: master_bedroom_main_lamp_right_button\n id: master_bedroom_main_lamp_right_button\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d00013e6aa5_action\n click_type: button_2_single\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x04cf8cdf3c77cc5f_action\n click_type: button_3_single\n conditions:\n - condition: template\n value_template: '{{ states(''light.round_led_mb'') in [''on'',''off''] }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: binary_sensor.round_led_mb_nightlight\n state: 'on'\n - condition: state\n entity_id: light.round_led_mb\n state: 'off'\n sequence:\n - action: yeelight.set_mode\n data:\n entity_id: light.round_led_mb\n mode: normal\n - action: light.turn_on\n entity_id: light.round_led_mb\n data:\n brightness: 230\n color_temp_kelvin: 5000\n - conditions:\n - condition: state\n entity_id: light.round_led_mb\n state: 'off'\n - condition: state\n entity_id: binary_sensor.round_led_mb_nightlight\n state: 'off'\n sequence:\n - action: light.turn_on\n entity_id: light.round_led_mb\n data:\n brightness: 230\n color_temp_kelvin: 5000\n - conditions:\n - condition: state\n entity_id: light.round_led_mb\n state: 'on'\n sequence:\n - action: light.turn_off\n entity_id: light.round_led_mb", "config": [ { "name": "action sensor table lamp", "room": "master_bedroom", "type": "sensor", "id": { "entity_id": "sensor.0x04cf8cdf3c77cc5f_action", "device_id": null } }, { "name": "action sensor main lamp mb", "room": "master_bedroom", "type": "sensor", "id": { "entity_id": "sensor.0x00158d00013e6aa5_action", "device_id": null } }, { "name": "round led mb", "room": "master_bedroom", "type": "light", "id": { "entity_id": "light.round_led_mb", "device_id": null } }, { "name": "round led mb nightlight", "room": "master_bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.round_led_mb_nightlight", "device_id": null } } ] }, { "id": "master_bedroom_main_lamp_right_button_full", "automation": "- alias: master_bedroom_main_lamp_right_button_full\n id: master_bedroom_main_lamp_right_button_full\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d00013e6aa5_action\n click_type: button_2_double\n conditions:\n - condition: template\n value_template: '{{ states(''light.round_led_mb'') in [''on'',''off''] }}'\n actions:\n - action: light.turn_on\n entity_id: light.round_led_mb\n data:\n brightness: 230\n color_temp_kelvin: 5000", "config": [ { "name": "action sensor main lamp mb", "room": "master_bedroom", "type": "sensor", "id": { "entity_id": "sensor.0x00158d00013e6aa5_action", "device_id": null } }, { "name": "round led mb", "room": "master_bedroom", "type": "light", "id": { "entity_id": "light.round_led_mb", "device_id": null } } ] }, { "id": "master_bedroom_main_lamp_left_button", "automation": "- alias: master_bedroom_main_lamp_left_button\n id: master_bedroom_main_lamp_left_button\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d00013e6aa5_action\n click_type: button_1_single\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x04cf8cdf3c77cc5f_action\n click_type: button_3_double\n conditions:\n - condition: template\n value_template: '{{ states(''light.round_led_mb'') in [''on'',''off''] }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: binary_sensor.round_led_mb_nightlight\n state: 'on'\n - condition: state\n entity_id: light.round_led_mb\n state: 'off'\n sequence:\n - action: yeelight.set_mode\n data:\n entity_id: light.round_led_mb\n mode: normal\n - action: light.turn_on\n entity_id: light.round_led_mb\n data:\n brightness: 77\n color_temp_kelvin: 3000\n - conditions:\n - condition: state\n entity_id: light.round_led_mb\n state: 'off'\n - condition: state\n entity_id: binary_sensor.round_led_mb_nightlight\n state: 'off'\n sequence:\n - action: light.turn_on\n entity_id: light.round_led_mb\n data:\n brightness: 77\n color_temp_kelvin: 3000\n - conditions:\n - condition: state\n entity_id: light.round_led_mb\n state: 'on'\n sequence:\n - action: light.turn_off\n entity_id: light.round_led_mb", "config": [ { "name": "action sensor table lamp", "room": "master_bedroom", "type": "sensor", "id": { "entity_id": "sensor.0x04cf8cdf3c77cc5f_action", "device_id": null } }, { "name": "action sensor main lamp mb", "room": "master_bedroom", "type": "sensor", "id": { "entity_id": "sensor.0x00158d00013e6aa5_action", "device_id": null } }, { "name": "round led mb", "room": "master_bedroom", "type": "light", "id": { "entity_id": "light.round_led_mb", "device_id": null } }, { "name": "round led mb nightlight", "room": "master_bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.round_led_mb_nightlight", "device_id": null } } ] }, { "id": "master_bedroom_round_led_restart", "automation": "- alias: master_bedroom_round_led_restart\n id: master_bedroom_round_led_restart\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /1\n conditions:\n - condition: state\n entity_id: light.round_led_mb\n state: unavailable\n for:\n minutes: 2\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: state\n entity_id: switch.system_round_led_mb_restart_key\n state: 'on'\n - condition: template\n value_template: \"{% set ignore = ['unknown', 'unavailable', 'none'] %} {{ states('switch.shelly_1_led_mb')\\\n \\ not in ignore }} \\n\"\n actions:\n - repeat:\n while:\n - condition: state\n entity_id: light.round_led_mb\n state: unavailable\n - condition: template\n value_template: '{{ repeat.index <= 5 }}'\n sequence:\n - action: switch.turn_off\n entity_id: switch.shelly_1_led_mb\n - delay:\n seconds: 15\n - action: switch.turn_on\n entity_id: switch.shelly_1_led_mb\n - action: notify.telegram\n data:\n message: 🚨 Round LED MB restart done({{repeat.index}})!\n - delay:\n seconds: 30\n - condition: state\n entity_id: light.round_led_mb\n state: unavailable\n - action: notify.telegram\n data:\n message: 🚨 Round LED MB restart unsuccessful!\n - action: switch.turn_off\n entity_id: switch.system_round_led_mb_restart_key", "config": [ { "name": "round led mb", "room": "master_bedroom", "type": "light", "id": { "entity_id": "light.round_led_mb", "device_id": null } }, { "name": "system round led mb restart key", "room": "master_bedroom", "type": "switch", "id": { "entity_id": "switch.system_round_led_mb_restart_key", "device_id": null } }, { "name": "shelly 1 led mb", "room": "master_bedroom", "type": "switch", "id": { "entity_id": "switch.shelly_1_led_mb", "device_id": null } } ] }, { "id": "master_bedroom_lamp_restart_key_toggle", "automation": "- alias: master_bedroom_main_lamp_restart_key_toggle\n id: master_bedroom_lamp_restart_key_toggle\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: light.round_led_mb\n from: unavailable\n actions:\n - action: switch.turn_on\n entity_id: switch.system_round_led_mb_restart_key", "config": [ { "name": "round led mb", "room": "master_bedroom", "type": "light", "id": { "entity_id": "light.round_led_mb", "device_id": null } }, { "name": "system round led mb restart key", "room": "master_bedroom", "type": "switch", "id": { "entity_id": "switch.system_round_led_mb_restart_key", "device_id": null } } ] }, { "id": "master_bedroom_main_lamp_switch_on_if_off", "automation": "- alias: master_bedroom_main_lamp_switch_on_if_off\n id: master_bedroom_main_lamp_switch_on_if_off\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d00013e6aa5_action\n click_type: button_2_single\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x04cf8cdf3c77cc5f_action\n click_type: button_3_single\n conditions:\n - condition: state\n entity_id: switch.shelly_1_led_mb\n state: 'off'\n actions:\n - action: switch.turn_on\n entity_id: switch.shelly_1_led_mb", "config": [ { "name": "action sensor table lamp", "room": "master_bedroom", "type": "sensor", "id": { "entity_id": "sensor.0x04cf8cdf3c77cc5f_action", "device_id": null } }, { "name": "action sensor main lamp mb", "room": "master_bedroom", "type": "sensor", "id": { "entity_id": "sensor.0x00158d00013e6aa5_action", "device_id": null } }, { "name": "shelly 1 led mb", "room": "master_bedroom", "type": "switch", "id": { "entity_id": "switch.shelly_1_led_mb", "device_id": null } } ] }, { "id": "master_bedroom_timer_restart", "automation": "- alias: master_bedroom_timer_restart\n id: master_bedroom_timer_restart\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0001e53cda_motion\n conditions:\n - condition: state\n entity_id: light.round_led_mb\n state: 'on'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_mb\n - action: timer.start\n entity_id: timer.main_light_mb", "config": [ { "name": "round led mb", "room": "master_bedroom", "type": "light", "id": { "entity_id": "light.round_led_mb", "device_id": null } }, { "name": "motion sensor master bedroom", "room": "master_bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001e53cda_motion", "device_id": null } }, { "name": "timer main light mb", "room": "master_bedroom", "type": "timer", "id": { "entity_id": "timer.main_light_mb", "device_id": null } } ] }, { "id": "master_bedroom_timer_off", "automation": "- alias: master_bedroom_timer_off\n id: master_bedroom_timer_off\n initial_state: true\n triggers:\n - trigger: state\n entity_id: light.round_led_mb\n to: 'off'\n from: 'on'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_mb", "config": [ { "name": "round led mb", "room": "master_bedroom", "type": "light", "id": { "entity_id": "light.round_led_mb", "device_id": null } }, { "name": "timer main light mb", "room": "master_bedroom", "type": "timer", "id": { "entity_id": "timer.main_light_mb", "device_id": null } } ] }, { "id": "master_bedroom_timer_on", "automation": "- alias: master_bedroom_timer_on\n id: master_bedroom_timer_on\n initial_state: true\n triggers:\n - trigger: state\n entity_id: light.round_led_mb\n to: 'on'\n from: 'off'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_mb\n - action: timer.start\n entity_id: timer.main_light_mb", "config": [ { "name": "round led mb", "room": "master_bedroom", "type": "light", "id": { "entity_id": "light.round_led_mb", "device_id": null } }, { "name": "timer main light mb", "room": "master_bedroom", "type": "timer", "id": { "entity_id": "timer.main_light_mb", "device_id": null } } ] }, { "id": "master_bedroom_led_strip_bookshelf_control", "automation": "- alias: master_bedroom_led_strip_bookshelf_control\n id: master_bedroom_led_strip_bookshelf_control\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x04cf8cdf3c77cc5f_action\n conditions:\n - condition: template\n value_template: '{{ states(''light.esp32_strip_1s_bookshelf_mb_rgb'') in [''on'',''off'']\n }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: numeric_state\n entity_id: sensor.ha_uptime\n above: 0\n actions:\n - choose:\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''single'' or trigger.event.data.click_type\n == ''button_4_single'' }}'\n sequence:\n - action: light.toggle\n entity_id: light.esp32_strip_1s_bookshelf_mb_rgb\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''double'' or trigger.event.data.click_type\n == ''button_4_double'' }}'\n sequence:\n - action: light.turn_on\n data:\n entity_id: light.esp32_strip_1s_bookshelf_mb_rgb\n brightness: 255\n rgb_color:\n - 255\n - 159\n - 70\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''hold'' or trigger.event.data.click_type\n == ''button_4_hold'' }}'\n sequence:\n - action: light.turn_on\n data:\n entity_id: light.esp32_strip_1s_bookshelf_mb_rgb\n brightness: 15\n rgb_color:\n - 250\n - 95\n - 85", "config": [ { "name": "ha uptime", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.ha_uptime", "device_id": null } }, { "name": "action sensor table lamp", "room": "master_bedroom", "type": "sensor", "id": { "entity_id": "sensor.0x04cf8cdf3c77cc5f_action", "device_id": null } }, { "name": "esp32 strip 1s bookshelf mb rgb", "room": "master_bedroom", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_bookshelf_mb_rgb", "device_id": null } } ] }, { "id": "master_bedroom_led_strip_wadrobe_control", "automation": "- alias: master_bedroom_led_strip_wadrobe_control\n id: master_bedroom_led_strip_wadrobe_control\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x04cf8cdf3c77cc5f_action\n conditions:\n - condition: template\n value_template: '{{ states(''light.esp32_strip_1s_wadrobe_mb_rgb'') in [''on'',''off'']\n }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: numeric_state\n entity_id: sensor.ha_uptime\n above: 0\n actions:\n - choose:\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''single'' or trigger.event.data.click_type\n == ''button_2_single'' }}'\n sequence:\n - action: light.toggle\n entity_id: light.esp32_strip_1s_wadrobe_mb_rgb\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''double'' or trigger.event.data.click_type\n == ''button_2_double'' }}'\n sequence:\n - action: light.turn_on\n data:\n entity_id: light.esp32_strip_1s_wadrobe_mb_rgb\n brightness: 255\n rgb_color:\n - 255\n - 159\n - 70\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''hold'' or trigger.event.data.click_type\n == ''button_2_hold'' }}'\n sequence:\n - action: light.turn_on\n data:\n entity_id: light.esp32_strip_1s_wadrobe_mb_rgb\n brightness: 15\n rgb_color:\n - 250\n - 95\n - 85", "config": [ { "name": "ha uptime", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.ha_uptime", "device_id": null } }, { "name": "action sensor table lamp", "room": "master_bedroom", "type": "sensor", "id": { "entity_id": "sensor.0x04cf8cdf3c77cc5f_action", "device_id": null } }, { "name": "esp32 strip 1s wadrobe mb rgb", "room": "master_bedroom", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_wadrobe_mb_rgb", "device_id": null } } ] }, { "id": "master_bedroom_main_light_off_with_occupancy", "automation": "- alias: master_bedroom_main_light_off_with_occupancy\n id: master_bedroom_main_light_off_with_occupancy\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.presence_mb\n to: 'off'\n for:\n minutes: 15\n conditions:\n - condition: state\n entity_id: group.lights_mb\n state: 'on'\n actions:\n - action: light.turn_off\n entity_id: light.round_led_mb_ambilight, light.0x54ef441000c88fa8_light, light.esp32_strip_1s_wadrobe_mb_rgb,\n light.esp32_strip_1s_bookshelf_mb_rgb\n data:\n transition: 15\n - action: light.turn_off\n entity_id: light.round_led_mb\n data:\n transition: 15", "config": [ { "name": "table lamp master bedroom", "room": "master_bedroom", "type": "light", "id": { "entity_id": "light.0x54ef441000c88fa8_light", "device_id": null } }, { "name": "round led mb", "room": "master_bedroom", "type": "light", "id": { "entity_id": "light.round_led_mb", "device_id": null } }, { "name": "esp32 strip 1s bookshelf mb rgb", "room": "master_bedroom", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_bookshelf_mb_rgb", "device_id": null } }, { "name": "esp32 strip 1s wadrobe mb rgb", "room": "master_bedroom", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_wadrobe_mb_rgb", "device_id": null } }, { "name": "round led mb ambilight", "room": "master_bedroom", "type": "light", "id": { "entity_id": "light.round_led_mb_ambilight", "device_id": null } }, { "name": "presence master bedroom", "room": "master_bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.presence_mb", "device_id": null } }, { "name": "Lights MB Group", "room": "Master Bedroom", "type": "group", "id": { "entity_id": "group.lights_mb", "device_id": null } } ] }, { "id": "master_bedroom_main_power_turned_off", "automation": "- alias: master_bedroom_main_power_turned_off\n id: master_bedroom_main_power_turned_off\n initial_state: true\n triggers:\n - trigger: state\n entity_id: switch.0x00158d0002467773_outlet\n to: 'off'\n from: 'on'\n actions:\n - action: notify.telegram\n data:\n message: 🔌 Внимание! Вторая розетка отключена! Запущен UPS (1050)", "config": [ { "name": "master bedroom outlet", "room": "master_bedroom", "type": "switch", "id": { "entity_id": "switch.0x00158d0002467773_outlet", "device_id": null } } ] }, { "id": "master_bedroom_main_plug_pulled_out", "automation": "- alias: master_bedroom_main_plug_pulled_out\n id: master_bedroom_main_plug_pulled_out\n initial_state: true\n triggers:\n - trigger: numeric_state\n entity_id: sensor.0x00158d0002467773_power\n below: 10\n actions:\n - action: notify.telegram\n data:\n message: 🔌 Внимание! Нагрузка во второй розетке упала! Проверь кабель!", "config": [ { "name": "master bedroom power", "room": "master_bedroom", "type": "sensor", "id": { "entity_id": "sensor.0x00158d0002467773_power", "device_id": null } } ] }, { "id": "master_bedroom_main_power_overpower", "automation": "- alias: master_bedroom_main_power_overpower\n id: master_bedroom_main_power_overpower\n initial_state: true\n triggers:\n - trigger: numeric_state\n entity_id: sensor.0x00158d0002467773_power\n above: 1700\n actions:\n - action: notify.telegram\n data:\n message: 🔌 Внимание! Перегрузка второй розетки! Отключите лишние потребители!", "config": [ { "name": "master bedroom power", "room": "master_bedroom", "type": "sensor", "id": { "entity_id": "sensor.0x00158d0002467773_power", "device_id": null } } ] }, { "id": "master_bedroom_ups_ob", "automation": "- alias: master_bedroom_ups_ob\n id: master_bedroom_ups_ob\n initial_state: true\n triggers:\n - trigger: state\n entity_id: sensor.ippon_1050_status_data\n to: OB\n actions:\n - parallel:\n - action: notify.telegram\n data:\n message: 🔋 Внимание! Запущен UPS (1050)!\n - action: notify.mobile_app_iphone_16_pro_dima\n data:\n title: Внимание!\n message: Запущен UPS (1050)", "config": [ { "name": "ippon 1050 status", "room": "master_bedroom", "type": "sensor", "id": { "entity_id": "sensor.ippon_1050_status_data", "device_id": null } } ] }, { "id": "master_bedroom_ups_lb", "automation": "- alias: master_bedroom_ups_lb\n id: master_bedroom_ups_lb\n initial_state: true\n triggers:\n - trigger: state\n entity_id: sensor.ippon_1050_status_data\n to: LB\n actions:\n - parallel:\n - action: notify.telegram\n data:\n message: 🚨 Внимание! Заряд батареи (1050) критический! Завершение работы NUC!\n - action: notify.mobile_app_iphone_16_pro_dima\n data:\n title: Внимание!\n message: UPS полностью разряжен! Завершаем работу NUC!\n data:\n push:\n sound:\n name: default\n critical: 1\n volume: 1.0", "config": [ { "name": "ippon 1050 status", "room": "master_bedroom", "type": "sensor", "id": { "entity_id": "sensor.ippon_1050_status_data", "device_id": null } } ] }, { "id": "master_bedroom_ups_ol", "automation": "- alias: master_bedroom_ups_ol\n id: master_bedroom_ups_ol\n initial_state: true\n triggers:\n - trigger: state\n entity_id: sensor.ippon_1050_status_data\n to: OL\n conditions:\n - condition: template\n value_template: '{{ trigger.from_state.state not in [''unknown'',''unavailable'',''none'']\n }}'\n actions:\n - action: notify.telegram\n data:\n message: 🔋 Питание восстановлено! Начинаем заряд батареи(1050)!", "config": [ { "name": "ippon 1050 status", "room": "master_bedroom", "type": "sensor", "id": { "entity_id": "sensor.ippon_1050_status_data", "device_id": null } } ] }, { "id": "master_bedroom_ups_unknown", "automation": "- alias: master_bedroom_ups_unknown\n id: master_bedroom_ups_unknown\n initial_state: true\n triggers:\n - trigger: state\n entity_id: sensor.ippon_1050_status_data\n to: unknown\n for:\n minutes: 5\n conditions:\n - condition: template\n value_template: '{{ trigger.from_state.state not in [''unknown'',''unavailable'',''none'']\n }}'\n actions:\n - action: notify.telegram\n data:\n message: 🚨 Внимание! Связь с UPS(1050) потеряна!", "config": [ { "name": "ippon 1050 status", "room": "master_bedroom", "type": "sensor", "id": { "entity_id": "sensor.ippon_1050_status_data", "device_id": null } } ] }, { "id": "master_bedroom_main_power_turned_on", "automation": "- alias: master_bedroom_main_power_turned_on\n id: master_bedroom_main_power_turned_on\n initial_state: true\n triggers:\n - trigger: state\n entity_id: switch.0x00158d0002467773_outlet\n to: 'on'\n from: 'off'\n actions:\n - action: notify.telegram\n data:\n message: 🔌 Электроснабжение восстановлено! Начинаем зарядку UPS(1050)!", "config": [ { "name": "master bedroom outlet", "room": "master_bedroom", "type": "switch", "id": { "entity_id": "switch.0x00158d0002467773_outlet", "device_id": null } } ] }, { "id": "sasha_breather_auto_co2", "automation": "- alias: sasha_breather_auto_co2\n id: sasha_breather_auto_co2\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /3\n conditions:\n - condition: state\n entity_id: switch.system_breather_auto_s\n state: 'on'\n - condition: not\n conditions:\n - condition: state\n entity_id: switch.system_breather_manual_s\n state: 'on'\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: binary_sensor.0x00158d00025370d1_contact\n state: 'off'\n - condition: numeric_state\n entity_id: sensor.esp32_node_s_co2\n above: input_number.co2_high_limit\n - condition: state\n entity_id: binary_sensor.breather_s\n state: 'off'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: numeric_state\n entity_id: sensor.0x00158d0001e6d85a_temperature\n above: 20\n sequence:\n - action: fan.turn_on\n entity_id: fan.breather_s\n - condition: numeric_state\n entity_id: sensor.esp32_node_s_co2\n above: input_number.co2_high_limit\n - condition: state\n entity_id: switch.system_breather_auto_speed_s\n state: 'on'\n - action: fan.set_percentage\n entity_id: fan.breather_s\n data:\n percentage: '{{states(''sensor.breather_set_speed_s'')|int(0) }}'\n - conditions:\n - condition: state\n entity_id: binary_sensor.0x00158d00025370d1_contact\n state: 'off'\n - condition: numeric_state\n entity_id: sensor.esp32_node_s_co2\n above: input_number.co2_high_limit\n - condition: state\n entity_id: binary_sensor.breather_s\n state: 'on'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: state\n entity_id: switch.system_breather_auto_speed_s\n state: 'on'\n - condition: numeric_state\n entity_id: sensor.breather_set_speed_s\n above: 0\n sequence:\n - action: fan.set_percentage\n entity_id: fan.breather_s\n data:\n percentage: '{{states(''sensor.breather_set_speed_s'')|int(0) }}'\n - conditions:\n - or:\n - and:\n - condition: state\n entity_id: binary_sensor.0x00158d00025370d1_contact\n state: 'off'\n - condition: numeric_state\n entity_id: sensor.esp32_node_s_co2\n below: input_number.co2_low_limit\n - condition: state\n entity_id: binary_sensor.breather_s\n state: 'on'\n - and:\n - or:\n - condition: numeric_state\n entity_id: sensor.0x00158d0001e6d85a_temperature\n below: 20\n - condition: state\n entity_id: binary_sensor.0x00158d00025370d1_contact\n state: 'on'\n - condition: state\n entity_id: binary_sensor.breather_s\n state: 'on'\n sequence:\n - action: fan.turn_off\n entity_id: fan.breather_s", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "co2 high limit", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.co2_high_limit", "device_id": null } }, { "name": "co2 low limit", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.co2_low_limit", "device_id": null } }, { "name": "system breather auto s", "room": "sasha_room", "type": "switch", "id": { "entity_id": "switch.system_breather_auto_s", "device_id": null } }, { "name": "system breather manual s", "room": "sasha_room", "type": "switch", "id": { "entity_id": "switch.system_breather_manual_s", "device_id": null } }, { "name": "contact sensor sasha", "room": "sasha_room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d00025370d1_contact", "device_id": null } }, { "name": "co2 sensor sasha", "room": "sasha_room", "type": "sensor", "id": { "entity_id": "sensor.esp32_node_s_co2", "device_id": null } }, { "name": "breather s binary", "room": "sasha_room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.breather_s", "device_id": null } }, { "name": "temperature sensor sasha", "room": "sasha_room", "type": "sensor", "id": { "entity_id": "sensor.0x00158d0001e6d85a_temperature", "device_id": null } }, { "name": "breather s fan", "room": "sasha_room", "type": "fan", "id": { "entity_id": "fan.breather_s", "device_id": null } }, { "name": "breather set speed s", "room": "sasha_room", "type": "sensor", "id": { "entity_id": "sensor.breather_set_speed_s", "device_id": null } }, { "name": "System Breather Auto Speed S", "room": null, "type": "switch", "id": { "entity_id": "switch.system_breather_auto_speed_s", "device_id": null } } ] }, { "id": "sasha_breather_auto_timer", "automation": "- alias: sasha_breather_auto_timer\n id: sasha_breather_auto_timer\n initial_state: true\n triggers:\n - trigger: event\n event_type: yandex_intent\n event_data:\n text: Выключи вентиляцию\n id: to_off_alice\n - trigger: event\n event_type: yandex_intent\n event_data:\n text: Включи вентиляцию\n id: to_on_alice\n - trigger: time\n at: '21:00:00'\n id: time_trigger_night\n - trigger: time\n at: 09:00:00\n id: time_trigger_day\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: to_off_alice\n sequence:\n - condition: template\n value_template: '{{ trigger.event.data.entity_id == ''media_player.yandex_s''\n }}'\n - if:\n - condition: state\n entity_id: binary_sensor.breather_s\n state: 'on'\n then:\n - action: fan.turn_off\n entity_id: fan.breather_s\n - action: switch.turn_on\n entity_id: switch.system_breather_auto_s\n - conditions:\n - condition: trigger\n id: to_on_alice\n sequence:\n - condition: template\n value_template: '{{ trigger.event.data.entity_id == ''media_player.yandex_s''\n }}'\n - if:\n - condition: state\n entity_id: binary_sensor.breather_s\n state: 'off'\n then:\n - action: switch.turn_on\n entity_id: switch.system_breather_manual_s\n - action: fan.turn_on\n entity_id: fan.breather_s\n - conditions:\n - condition: trigger\n id: time_trigger_night\n sequence:\n - action: switch.turn_on\n entity_id: switch.system_breather_manual_s\n - action: fan.set_percentage\n entity_id: fan.breather_s\n data:\n percentage: 25\n - conditions:\n - condition: trigger\n id: time_trigger_day\n sequence:\n - action: fan.turn_off\n entity_id: fan.breather_s", "config": [ { "name": "yandex sasha room", "room": "sasha_room", "type": "media_player", "id": { "entity_id": "media_player.yandex_s", "device_id": null } }, { "name": "system breather auto s", "room": "sasha_room", "type": "switch", "id": { "entity_id": "switch.system_breather_auto_s", "device_id": null } }, { "name": "system breather manual s", "room": "sasha_room", "type": "switch", "id": { "entity_id": "switch.system_breather_manual_s", "device_id": null } }, { "name": "breather s binary", "room": "sasha_room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.breather_s", "device_id": null } }, { "name": "breather s fan", "room": "sasha_room", "type": "fan", "id": { "entity_id": "fan.breather_s", "device_id": null } } ] }, { "id": "sasha_breather_switches_interlock", "automation": "- alias: sasha_breather_switches_interlock\n id: sasha_breather_switches_interlock\n triggers:\n - trigger: state\n entity_id:\n - switch.system_breather_auto_s\n - switch.system_breather_manual_s\n conditions:\n - condition: template\n value_template: '{{ trigger.to_state.state == ''on'' }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: homeassistant.turn_off\n target:\n entity_id: '{% if trigger.from_state.entity_id == ''switch.system_breather_auto_s''\n %} {{ ''switch.system_breather_manual_s'' }} {% else %} {{ ''switch.system_breather_auto_s''\n }} {% endif %}'", "config": [ { "name": "system breather auto s", "room": "sasha_room", "type": "switch", "id": { "entity_id": "switch.system_breather_auto_s", "device_id": null } }, { "name": "system breather manual s", "room": "sasha_room", "type": "switch", "id": { "entity_id": "switch.system_breather_manual_s", "device_id": null } } ] }, { "id": "sasha_breather_switches_default", "automation": "- alias: sasha_breather_switches_default\n id: sasha_breather_switches_default\n triggers:\n - trigger: template\n value_template: '{{ is_state(''switch.system_breather_auto_s'',''off'') and is_state(''switch.system_breather_manual_s'',''off'')\n }}'\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: switch.turn_on\n entity_id: switch.system_breather_auto_s", "config": [ { "name": "system breather auto s", "room": "sasha_room", "type": "switch", "id": { "entity_id": "switch.system_breather_auto_s", "device_id": null } }, { "name": "system breather manual s", "room": "sasha_room", "type": "switch", "id": { "entity_id": "switch.system_breather_manual_s", "device_id": null } } ] }, { "id": "sasha_led_white_control", "automation": "- alias: sasha_led_white_control\n id: sasha_led_white_control\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x04cf8cdf3c77d831_action\n conditions:\n - condition: template\n value_template: '{{ states(''light.0x54ef441000d54c6c_light'') in [''on'',''off'']\n }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - choose:\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''single'' or trigger.event.data.click_type\n == ''button_1_single''}}'\n sequence:\n - action: light.toggle\n entity_id: light.0x54ef441000d54c6c_light\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''double'' or trigger.event.data.click_type\n == ''button_1_double'' }}'\n sequence:\n - action: light.turn_on\n entity_id: light.0x54ef441000d54c6c_light\n data:\n brightness: 255\n color_temp_kelvin: 5000\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''hold'' or trigger.event.data.click_type\n == ''button_1_hold'' }}'\n sequence:\n - action: light.turn_on\n entity_id: light.0x54ef441000d54c6c_light\n data:\n brightness: 14\n color_temp_kelvin: 3000", "config": [ { "name": "led white s", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.0x54ef441000d54c6c_light", "device_id": null } }, { "name": "action sensor led white s", "room": "sasha_room", "type": "sensor", "id": { "entity_id": "sensor.0x04cf8cdf3c77d831_action", "device_id": null } } ] }, { "id": "sasha_main_lamp_left_button", "automation": "- alias: sasha_main_lamp_left_button\n id: sasha_main_lamp_left_button\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d00026eb820_action\n click_type: button_1_single\n conditions:\n - condition: template\n value_template: '{{ states(''light.square_led_s'') in [''on'',''off''] }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - if:\n - condition: state\n entity_id: binary_sensor.square_led_s_nightlight\n state: 'on'\n - condition: state\n entity_id: light.square_led_s\n state: 'off'\n then:\n - action: yeelight.set_mode\n data:\n entity_id: light.square_led_s\n mode: normal\n - choose:\n - conditions:\n - condition: state\n entity_id: light.square_led_s\n state: 'on'\n sequence:\n - action: light.turn_off\n entity_id: light.square_led_s\n - conditions:\n - condition: state\n entity_id: light.square_led_s\n state: 'off'\n sequence:\n - action: light.turn_on\n entity_id: light.square_led_s\n data:\n brightness: 230\n color_temp_kelvin: 5000", "config": [ { "name": "action sensor main lamp s", "room": "sasha_room", "type": "sensor", "id": { "entity_id": "sensor.0x00158d00026eb820_action", "device_id": null } }, { "name": "square led s", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.square_led_s", "device_id": null } }, { "name": "square led s nightlight", "room": "sasha_room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.square_led_s_nightlight", "device_id": null } } ] }, { "id": "sasha_main_lamp_right_button", "automation": "- alias: sasha_main_lamp_right_button\n id: sasha_main_lamp_right_button\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d00026eb820_action\n click_type: button_2_single\n conditions:\n - condition: template\n value_template: '{{ states(''light.square_led_s'') in [''on'',''off''] }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - if:\n - condition: state\n entity_id: binary_sensor.square_led_s_nightlight\n state: 'on'\n - condition: state\n entity_id: light.square_led_s\n state: 'off'\n then:\n - action: yeelight.set_mode\n data:\n entity_id: light.square_led_s\n mode: normal\n - choose:\n - conditions:\n - condition: state\n entity_id: light.square_led_s\n state: 'on'\n sequence:\n - action: light.turn_off\n entity_id: light.square_led_s\n - conditions:\n - condition: state\n entity_id: light.square_led_s\n state: 'off'\n sequence:\n - action: light.turn_on\n entity_id: light.square_led_s\n data:\n brightness: 14\n color_temp_kelvin: 3000", "config": [ { "name": "action sensor main lamp s", "room": "sasha_room", "type": "sensor", "id": { "entity_id": "sensor.0x00158d00026eb820_action", "device_id": null } }, { "name": "square led s", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.square_led_s", "device_id": null } }, { "name": "square led s nightlight", "room": "sasha_room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.square_led_s_nightlight", "device_id": null } } ] }, { "id": "sasha_table_lamp_off_night_mode_main_on", "automation": "- alias: sasha_table_lamp_off_night_mode_main_on\n id: sasha_table_lamp_off_night_mode_main_on\n initial_state: true\n triggers:\n - trigger: state\n entity_id: light.0x54ef441000d54c6c_light\n to: null\n - trigger: homeassistant\n event: start\n - trigger: event\n event_type: automation_reloaded\n conditions:\n - condition: template\n value_template: '{{state_attr(''light.0x54ef441000d54c6c_light'',''brightness'')|int(0)\n < 10}}'\n - condition: state\n entity_id: light.square_led_s\n state: 'on'\n - condition: state\n entity_id: light.0x54ef441000d54c6c_light\n state: 'on'\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'on'\n actions:\n - action: light.turn_off\n entity_id: light.0x54ef441000d54c6c_light", "config": [ { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "led white s", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.0x54ef441000d54c6c_light", "device_id": null } }, { "name": "square led s", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.square_led_s", "device_id": null } } ] }, { "id": "sasha_night_auto_off_30m", "automation": "- alias: sasha_night_auto_off_30m\n id: sasha_night_auto_off_30m\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.motion_s\n from: 'on'\n to: 'off'\n for:\n minutes: 30\n conditions:\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'off'\n actions:\n - action: light.turn_off\n entity_id: light.0x54ef441000d54c6c_light\n data:\n transition: 5", "config": [ { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "led white s", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.0x54ef441000d54c6c_light", "device_id": null } }, { "name": "motion sasha", "room": "sasha_room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.motion_s", "device_id": null } } ] }, { "id": "sasha_square_led_restart", "automation": "- alias: sasha_square_led_restart\n id: sasha_square_led_restart\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /1\n conditions:\n - condition: state\n entity_id: light.square_led_s\n state: unavailable\n for:\n minutes: 2\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: state\n entity_id: switch.system_square_led_s_restart_key\n state: 'on'\n - condition: template\n value_template: '{% set ignore = [''unknown'', ''unavailable'', ''none''] %} {{\n states(''switch.shelly_1_led_s'') not in ignore }}\n\n '\n actions:\n - repeat:\n while:\n - condition: state\n entity_id: light.square_led_s\n state: unavailable\n - condition: template\n value_template: '{{ repeat.index <= 5 }}'\n sequence:\n - action: switch.turn_off\n entity_id: switch.shelly_1_led_s\n - delay:\n seconds: 15\n - action: switch.turn_on\n entity_id: switch.shelly_1_led_s\n - action: notify.telegram\n data:\n message: 🚨 Square LED S restart done({{repeat.index}})!\n - delay:\n seconds: 30\n - condition: state\n entity_id: light.square_led_s\n state: unavailable\n - action: notify.telegram\n data:\n message: 🚨 Square LED S restart unsuccessful!\n - action: switch.turn_off\n entity_id: switch.system_square_led_s_restart_key", "config": [ { "name": "square led s", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.square_led_s", "device_id": null } }, { "name": "system square led s restart key", "room": "sasha_room", "type": "switch", "id": { "entity_id": "switch.system_square_led_s_restart_key", "device_id": null } }, { "name": "shelly 1 led s", "room": "sasha_room", "type": "switch", "id": { "entity_id": "switch.shelly_1_led_s", "device_id": null } } ] }, { "id": "sasha_square_led_restart_key_toggle", "automation": "- alias: sasha_square_led_restart_key_toggle\n id: sasha_square_led_restart_key_toggle\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: light.square_led_s\n from: unavailable\n actions:\n - action: switch.turn_on\n entity_id: switch.system_square_led_s_restart_key", "config": [ { "name": "square led s", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.square_led_s", "device_id": null } }, { "name": "system square led s restart key", "room": "sasha_room", "type": "switch", "id": { "entity_id": "switch.system_square_led_s_restart_key", "device_id": null } } ] }, { "id": "sasha_main_lamp_switch_on_if_off", "automation": "- alias: sasha_main_lamp_switch_on_if_off\n id: sasha_main_lamp_switch_on_if_off\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d00026eb820_action\n conditions:\n - condition: state\n entity_id: switch.shelly_1_led_s\n state: 'off'\n actions:\n - action: switch.turn_on\n entity_id: switch.shelly_1_led_s", "config": [ { "name": "action sensor main lamp s", "room": "sasha_room", "type": "sensor", "id": { "entity_id": "sensor.0x00158d00026eb820_action", "device_id": null } }, { "name": "shelly 1 led s", "room": "sasha_room", "type": "switch", "id": { "entity_id": "switch.shelly_1_led_s", "device_id": null } } ] }, { "id": "sasha_timer_restart", "automation": "- alias: sasha_timer_restart\n id: sasha_timer_restart\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d000224f89f_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0003140824_motion\n conditions:\n - condition: state\n entity_id: light.square_led_s\n state: 'on'\n - condition: template\n value_template: '{{(as_timestamp(now())-as_timestamp(state_attr(''automation.sasha_timer_restart'',\n ''last_triggered''),0)|int(0)) > 15 }}'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_s\n - action: timer.start\n entity_id: timer.main_light_s", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "square led s", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.square_led_s", "device_id": null } }, { "name": "motion sensor sasha 1", "room": "sasha_room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d000224f89f_motion", "device_id": null } }, { "name": "motion sensor sasha 2", "room": "sasha_room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0003140824_motion", "device_id": null } }, { "name": "timer main light s", "room": "sasha_room", "type": "timer", "id": { "entity_id": "timer.main_light_s", "device_id": null } } ] }, { "id": "sasha_timer_off", "automation": "- alias: sasha_timer_off\n id: sasha_timer_off\n initial_state: true\n triggers:\n - trigger: state\n entity_id: light.square_led_s\n to: 'off'\n from: 'on'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_s", "config": [ { "name": "square led s", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.square_led_s", "device_id": null } }, { "name": "timer main light s", "room": "sasha_room", "type": "timer", "id": { "entity_id": "timer.main_light_s", "device_id": null } } ] }, { "id": "sasha_timer_on", "automation": "- alias: sasha_timer_on\n id: sasha_timer_on\n initial_state: true\n triggers:\n - trigger: state\n entity_id: light.square_led_s\n to: 'on'\n from: 'off'\n conditions:\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_s\n - action: timer.start\n entity_id: timer.main_light_s", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "square led s", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.square_led_s", "device_id": null } }, { "name": "timer main light s", "room": "sasha_room", "type": "timer", "id": { "entity_id": "timer.main_light_s", "device_id": null } } ] }, { "id": "sasha_auto_light_off", "automation": "- alias: sasha_auto_light_off\n id: sasha_auto_light_off\n initial_state: true\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.main_light_s\n conditions:\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'on'\n actions:\n - action: light.turn_off\n entity_id: light.square_led_s\n data:\n transition: 5", "config": [ { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "square led s", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.square_led_s", "device_id": null } }, { "name": "timer main light s", "room": "sasha_room", "type": "timer", "id": { "entity_id": "timer.main_light_s", "device_id": null } } ] }, { "id": "sasha_led_strip_control", "automation": "- alias: sasha_led_strip_control\n id: sasha_led_strip_control\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x04cf8cdf3c77d831_action\n conditions:\n - condition: template\n value_template: '{{ states(''light.esp32_node_s_led'') in [''on'',''off''] }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - choose:\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''single'' or trigger.event.data.click_type\n == ''button_2_single'' }}'\n sequence:\n - action: light.turn_on\n data:\n entity_id: light.esp32_node_s_led\n effect: '{{ ([\"Random\", \"Rainbow\", \"Color Wipe\", \"Scan\", \"Twinkle\", \"Random\n Twinkle\"] | random) }}'\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''double'' or trigger.event.data.click_type\n == ''button_2_double'' }}'\n sequence:\n - action: light.turn_on\n data:\n entity_id: light.esp32_node_s_led\n effect: Color Wipe\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''hold'' or trigger.event.data.click_type\n == ''button_2_hold'' }}'\n sequence:\n - action: light.turn_off\n entity_id: light.esp32_node_s_led\n data:\n transition: 5", "config": [ { "name": "action sensor led white s", "room": "sasha_room", "type": "sensor", "id": { "entity_id": "sensor.0x04cf8cdf3c77d831_action", "device_id": null } }, { "name": "esp32 node s led", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.esp32_node_s_led", "device_id": null } } ] }, { "id": "sasha_light_off_with_occupancy", "automation": "- alias: sasha_light_off_with_occupancy\n id: sasha_light_off_with_occupancy\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.presence_s\n to: 'off'\n for:\n minutes: 15\n conditions:\n - condition: state\n entity_id: group.lights_s\n state: 'on'\n actions:\n - action: light.turn_off\n entity_id: light.square_led_s, light.esp32_node_s_led, light.0x54ef441000d54c6c_light,\n light.0x54ef4410000ea59b_light, light.light_bar_s, light.light_bar_s_ambilight\n data:\n transition: 15", "config": [ { "name": "light bar s ambilight", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.light_bar_s_ambilight", "device_id": null } }, { "name": "led white s", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.0x54ef441000d54c6c_light", "device_id": null } }, { "name": "square led s", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.square_led_s", "device_id": null } }, { "name": "esp32 node s led", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.esp32_node_s_led", "device_id": null } }, { "name": "Presence S", "room": "Sasha Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.presence_s", "device_id": null } }, { "name": "Lights S Group", "room": "Sasha Room", "type": "group", "id": { "entity_id": "group.lights_s", "device_id": null } }, { "name": "Light Bar S", "room": "Sasha Room", "type": "light", "id": { "entity_id": "light.light_bar_s", "device_id": null } } ] }, { "id": "sasha_main_light_control_with_alice", "automation": "- alias: sasha_main_light_control_with_alice\n id: sasha_main_light_control_with_alice\n initial_state: true\n triggers:\n - trigger: event\n event_type: yandex_intent\n event_data:\n text: Выключи свет в Сашиной комнате\n id: to_off_alice\n - trigger: event\n event_type: yandex_intent\n event_data:\n text: Включи свет в Сашиной комнате\n id: to_on_alice\n conditions:\n - condition: template\n value_template: '{{ states(''light.square_led_s'') in [''on'',''off''] }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: to_off_alice\n sequence:\n - action: light.turn_off\n entity_id: light.square_led_s\n - conditions:\n - condition: trigger\n id: to_on_alice\n sequence:\n - action: light.turn_on\n entity_id: light.square_led_s\n data:\n brightness: 230\n color_temp_kelvin: 5000", "config": [ { "name": "square led s", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.square_led_s", "device_id": null } } ] }, { "id": "sasha_light_bar_restart", "automation": "- alias: sasha_light_bar_restart\n id: sasha_light_bar_restart\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /1\n conditions:\n - condition: state\n entity_id: light.light_bar_s\n state: unavailable\n for:\n minutes: 2\n - condition: state\n entity_id: switch.system_light_bar_s_restart_key\n state: 'on'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: template\n value_template: '{% set ignore = [''unknown'', ''unavailable'', ''none''] %} {{\n states(''switch.sp111_socket_1_relay'') not in ignore }}\n\n '\n actions:\n - repeat:\n while:\n - condition: state\n entity_id: light.light_bar_s\n state: unavailable\n - condition: template\n value_template: '{{ repeat.index <= 5 }}'\n sequence:\n - action: switch.turn_off\n entity_id: switch.sp111_socket_1_relay\n - delay:\n seconds: 15\n - action: switch.turn_on\n entity_id: switch.sp111_socket_1_relay\n - action: notify.telegram\n data:\n message: 🚨 Light Bar S restart done({{repeat.index}})!\n - delay:\n seconds: 30\n - condition: state\n entity_id: light.light_bar_s\n state: unavailable\n - action: notify.telegram\n data:\n message: 🚨 Light Bar S restart unsuccessful!\n - action: switch.turn_off\n entity_id: switch.system_light_bar_s_restart_key", "config": [ { "name": "Light Bar S", "room": "Sasha Room", "type": "light", "id": { "entity_id": "light.light_bar_s", "device_id": null } }, { "name": "SP111 Socket 1 Relay", "room": null, "type": "switch", "id": { "entity_id": "switch.sp111_socket_1_relay", "device_id": null } }, { "name": "System Light Bar S Restart Key", "room": null, "type": "switch", "id": { "entity_id": "switch.system_light_bar_s_restart_key", "device_id": null } } ] }, { "id": "sasha_light_bar_s_restart_key_toggle", "automation": "- alias: sasha_light_bar_s_restart_key_toggle\n id: sasha_light_bar_s_restart_key_toggle\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: light.light_bar_s\n from: unavailable\n actions:\n - action: switch.turn_on\n entity_id: switch.system_light_bar_s_restart_key", "config": [ { "name": "Light Bar S", "room": "Sasha Room", "type": "light", "id": { "entity_id": "light.light_bar_s", "device_id": null } }, { "name": "System Light Bar S Restart Key", "room": null, "type": "switch", "id": { "entity_id": "switch.system_light_bar_s_restart_key", "device_id": null } } ] }, { "id": "storage_auto_light_on", "automation": "- alias: storage_auto_light_on\n id: storage_auto_light_on\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0001aea602_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0003f27ce2_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.582d34609552_motion\n conditions:\n - condition: state\n entity_id: timer.main_light_delay_st\n state: idle\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: state\n entity_id: group.lights_st\n state: 'off'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: light.turn_on\n data:\n entity_id: '{%if is_state(''binary_sensor.tod_day'',''on'') and is_state(''switch.system_dark_mode'',''off'')\n %}light.0x54ef441000680083_channel_2,light.round_led_st {%elif is_state(''binary_sensor.tod_day'',''off'')\n or is_state(''switch.system_dark_mode'',''on'') %}light.round_led_st {%endif%}'", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "system dark mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_dark_mode", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "Motion Sensor 1aea602", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001aea602_motion", "device_id": null } }, { "name": "Motion Sensor 3f27ce2", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0003f27ce2_motion", "device_id": null } }, { "name": "Motion Sensor 582d34609552", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.582d34609552_motion", "device_id": null } }, { "name": "Lights S Group", "room": "Sasha Room", "type": "group", "id": { "entity_id": "group.lights_s", "device_id": null } }, { "name": "Lights St Group", "room": null, "type": "group", "id": { "entity_id": "group.lights_st", "device_id": null } }, { "name": "Light Channel 2 680083", "room": null, "type": "light", "id": { "entity_id": "light.0x54ef441000680083_channel_2", "device_id": null } }, { "name": "Round LED St", "room": null, "type": "light", "id": { "entity_id": "light.round_led_st", "device_id": null } }, { "name": "Main Light Delay St Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.main_light_delay_st", "device_id": null } } ] }, { "id": "storage_light_on", "automation": "- alias: storage_light_on\n id: storage_light_on\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x00158d0002a1b0c8_contact\n from: 'off'\n to: 'on'\n for:\n seconds: 1\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x04cf8cdf3c79546c_action\n click_type: button_2_single\n conditions:\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: state\n entity_id: group.lights_st\n state: 'off'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: light.turn_on\n data:\n entity_id: '{%if is_state(''binary_sensor.tod_day'',''on'') and is_state(''switch.system_dark_mode'',''off'')\n %}light.0x54ef441000680083_channel_2,light.round_led_st {%elif is_state(''binary_sensor.tod_day'',''off'')\n or is_state(''switch.system_dark_mode'',''on'') %}light.round_led_st {%endif%}'", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "system dark mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_dark_mode", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "Contact Sensor 2a1b0c8", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002a1b0c8_contact", "device_id": null } }, { "name": "Lights S Group", "room": "Sasha Room", "type": "group", "id": { "entity_id": "group.lights_s", "device_id": null } }, { "name": "Lights St Group", "room": null, "type": "group", "id": { "entity_id": "group.lights_st", "device_id": null } }, { "name": "Light Channel 2 680083", "room": null, "type": "light", "id": { "entity_id": "light.0x54ef441000680083_channel_2", "device_id": null } }, { "name": "Round LED St", "room": null, "type": "light", "id": { "entity_id": "light.round_led_st", "device_id": null } }, { "name": "Action Sensor 04cf8cdf3c79546c", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x04cf8cdf3c79546c_action", "device_id": null } } ] }, { "id": "storage_main_light_full_on", "automation": "- alias: storage_main_light_full_on\n id: storage_main_light_full_on\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x04cf8cdf3c79546c_action\n click_type: button_2_double\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: light.turn_on\n entity_id: light.0x54ef441000680083_channel_2, light.round_led_st", "config": [ { "name": "Light Channel 2 680083", "room": null, "type": "light", "id": { "entity_id": "light.0x54ef441000680083_channel_2", "device_id": null } }, { "name": "Round LED St", "room": null, "type": "light", "id": { "entity_id": "light.round_led_st", "device_id": null } }, { "name": "Action Sensor 04cf8cdf3c79546c", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x04cf8cdf3c79546c_action", "device_id": null } } ] }, { "id": "storage_light_off", "automation": "- alias: storage_light_off\n id: storage_light_off\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.main_light_st\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x04cf8cdf3c79546c_action\n click_type: button_2_single\n - trigger: state\n entity_id: binary_sensor.0x00158d0002a1b0c8_contact\n from: 'on'\n to: 'off'\n for:\n seconds: 1\n - trigger: state\n entity_id: binary_sensor.dced838ea54e_occupancy\n from: 'on'\n to: 'off'\n conditions:\n - condition: state\n entity_id: group.lights_st\n state: 'on'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: light.turn_off\n entity_id: light.0x54ef441000680083_channel_2,light.round_led_st\n - action: timer.cancel\n entity_id: timer.main_light_st", "config": [ { "name": "timer main light s", "room": "sasha_room", "type": "timer", "id": { "entity_id": "timer.main_light_s", "device_id": null } }, { "name": "Contact Sensor 2a1b0c8", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002a1b0c8_contact", "device_id": null } }, { "name": "Occupancy dced838ea54e", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.dced838ea54e_occupancy", "device_id": null } }, { "name": "Lights S Group", "room": "Sasha Room", "type": "group", "id": { "entity_id": "group.lights_s", "device_id": null } }, { "name": "Lights St Group", "room": null, "type": "group", "id": { "entity_id": "group.lights_st", "device_id": null } }, { "name": "Light Channel 2 680083", "room": null, "type": "light", "id": { "entity_id": "light.0x54ef441000680083_channel_2", "device_id": null } }, { "name": "Round LED St", "room": null, "type": "light", "id": { "entity_id": "light.round_led_st", "device_id": null } }, { "name": "Action Sensor 04cf8cdf3c79546c", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x04cf8cdf3c79546c_action", "device_id": null } }, { "name": "Main Light St Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.main_light_st", "device_id": null } } ] }, { "id": "storage_timer_start", "automation": "- alias: storage_timer_start\n id: storage_timer_start\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: template\n value_template: '{{ is_state(''light.0x54ef441000680083_channel_2'',''on'') or\n is_state(''light.round_led_st'',''on'')}}'\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_st\n - action: timer.start\n entity_id: timer.main_light_st", "config": [ { "name": "timer main light s", "room": "sasha_room", "type": "timer", "id": { "entity_id": "timer.main_light_s", "device_id": null } }, { "name": "Light Channel 2 680083", "room": null, "type": "light", "id": { "entity_id": "light.0x54ef441000680083_channel_2", "device_id": null } }, { "name": "Round LED St", "room": null, "type": "light", "id": { "entity_id": "light.round_led_st", "device_id": null } }, { "name": "Main Light St Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.main_light_st", "device_id": null } } ] }, { "id": "storage_timer_restart", "automation": "- alias: storage_timer_restart\n id: storage_timer_restart\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0001aea602_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0003f27ce2_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.54ef44c65722_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.582d34609552_motion\n conditions:\n - condition: state\n entity_id: group.lights_st\n state: 'on'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_st\n - action: timer.start\n entity_id: timer.main_light_st", "config": [ { "name": "timer main light s", "room": "sasha_room", "type": "timer", "id": { "entity_id": "timer.main_light_s", "device_id": null } }, { "name": "Motion Sensor 1aea602", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001aea602_motion", "device_id": null } }, { "name": "Motion Sensor 3f27ce2", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0003f27ce2_motion", "device_id": null } }, { "name": "Motion Sensor 54ef44c65722", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.54ef44c65722_motion", "device_id": null } }, { "name": "Motion Sensor 582d34609552", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.582d34609552_motion", "device_id": null } }, { "name": "Lights S Group", "room": "Sasha Room", "type": "group", "id": { "entity_id": "group.lights_s", "device_id": null } }, { "name": "Lights St Group", "room": null, "type": "group", "id": { "entity_id": "group.lights_st", "device_id": null } }, { "name": "Main Light St Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.main_light_st", "device_id": null } } ] }, { "id": "storage_timer_off", "automation": "- alias: storage_timer_off\n id: storage_timer_off\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: light.0x54ef441000680083_channel_2, light.round_led_st\n to: 'off'\n from: 'on'\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_st\n - action: timer.cancel\n entity_id: timer.main_light_delay_st\n - action: timer.start\n entity_id: timer.main_light_delay_st\n - action: light.turn_off\n entity_id: light.round_led_st", "config": [ { "name": "timer main light s", "room": "sasha_room", "type": "timer", "id": { "entity_id": "timer.main_light_s", "device_id": null } }, { "name": "Light Channel 2 680083", "room": null, "type": "light", "id": { "entity_id": "light.0x54ef441000680083_channel_2", "device_id": null } }, { "name": "Round LED St", "room": null, "type": "light", "id": { "entity_id": "light.round_led_st", "device_id": null } }, { "name": "Main Light Delay St Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.main_light_delay_st", "device_id": null } }, { "name": "Main Light St Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.main_light_st", "device_id": null } } ] }, { "id": "storage_night_off", "automation": "- alias: storage_night_off\n id: storage_night_off\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x04cf8cdf3c79546c_action\n click_type: button_1_single\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: light.turn_off\n target:\n entity_id:\n - light.esp32_node_k_light\n - light.mono_strip_1_light\n - light.0x54ef441000680083_channel_2\n - light.round_led_st\n - light.esp32_strip_1s_wadrobe_hb_rgb\n - light.esp32_strip_1s_entrance_hb_rgb\n - light.mirror_light_b", "config": [ { "name": "mirror light b", "room": "bathroom", "type": "light", "id": { "entity_id": "light.mirror_light_b", "device_id": null } }, { "name": "esp32 strip 1s entrance hb rgb", "room": "hall_big", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_entrance_hb_rgb", "device_id": null } }, { "name": "esp32 strip 1s wadrobe hb rgb", "room": "hall_big", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_wadrobe_hb_rgb", "device_id": null } }, { "name": "mono strip 1 light", "room": "hall_small", "type": "light", "id": { "entity_id": "light.mono_strip_1_light", "device_id": null } }, { "name": "esp32 node k light", "room": "kitchen", "type": "light", "id": { "entity_id": "light.esp32_node_k_light", "device_id": null } }, { "name": "Light Channel 2 680083", "room": null, "type": "light", "id": { "entity_id": "light.0x54ef441000680083_channel_2", "device_id": null } }, { "name": "Round LED St", "room": null, "type": "light", "id": { "entity_id": "light.round_led_st", "device_id": null } }, { "name": "Action Sensor 04cf8cdf3c79546c", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x04cf8cdf3c79546c_action", "device_id": null } } ] }, { "id": "storage_light_dark_mode_on", "automation": "- alias: storage_light_dark_mode_on\n id: storage_light_dark_mode_on\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x04cf8cdf3c79546c_action\n click_type: button_1_double\n - trigger: state\n entity_id: binary_sensor.lullaby\n to: 'on'\n conditions:\n - condition: state\n entity_id: switch.system_dark_mode\n state: 'off'\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'on'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: switch.turn_on\n entity_id: switch.system_dark_mode", "config": [ { "name": "system dark mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_dark_mode", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "Lullaby", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.lullaby", "device_id": null } }, { "name": "Action Sensor 04cf8cdf3c79546c", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x04cf8cdf3c79546c_action", "device_id": null } } ] }, { "id": "storage_light_dark_mode_off", "automation": "- alias: storage_light_dark_mode_off\n id: storage_light_dark_mode_off\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x04cf8cdf3c79546c_action\n click_type: button_1_double\n - trigger: state\n entity_id: light.0x00158d000223921b_channel_1, light.0x00158d000253f04a_channel_2\n from: 'off'\n to: 'on'\n for:\n seconds: 10\n conditions:\n - condition: state\n entity_id: switch.system_dark_mode\n state: 'on'\n actions:\n - action: switch.turn_off\n entity_id: switch.system_dark_mode", "config": [ { "name": "system dark mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_dark_mode", "device_id": null } }, { "name": "channel 1 light", "room": "hall_big", "type": "light", "id": { "entity_id": "light.0x00158d000223921b_channel_1", "device_id": null } }, { "name": "channel 2 light fridge", "room": "hall_big", "type": "light", "id": { "entity_id": "light.0x00158d000253f04a_channel_2", "device_id": null } }, { "name": "Action Sensor 04cf8cdf3c79546c", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x04cf8cdf3c79546c_action", "device_id": null } } ] }, { "id": "storage_light_off_with_occupancy", "automation": "- alias: storage_light_off_with_occupancy\n id: storage_light_off_with_occupancy\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.presence_st\n to: 'off'\n for:\n minutes: 15\n conditions:\n - condition: state\n entity_id: group.lights_st\n state: 'on'\n actions:\n - action: light.turn_off\n entity_id: light.0x54ef441000680083_channel_2,light.round_led_st", "config": [ { "name": "Presence S", "room": "Sasha Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.presence_s", "device_id": null } }, { "name": "Presence St", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.presence_st", "device_id": null } }, { "name": "Lights S Group", "room": "Sasha Room", "type": "group", "id": { "entity_id": "group.lights_s", "device_id": null } }, { "name": "Lights St Group", "room": null, "type": "group", "id": { "entity_id": "group.lights_st", "device_id": null } }, { "name": "Light Channel 2 680083", "room": null, "type": "light", "id": { "entity_id": "light.0x54ef441000680083_channel_2", "device_id": null } }, { "name": "Round LED St", "room": null, "type": "light", "id": { "entity_id": "light.round_led_st", "device_id": null } } ] }, { "id": "storage_night_light_toggle", "automation": "- alias: storage_night_light_toggle\n id: storage_night_light_toggle\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x54ef441000680083_action\n click_type: button_1_single\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: light.toggle\n entity_id: light.round_led_st", "config": [ { "name": "Round LED St", "room": null, "type": "light", "id": { "entity_id": "light.round_led_st", "device_id": null } }, { "name": "Action Sensor 680083", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x54ef441000680083_action", "device_id": null } } ] }, { "id": "storage_round_led_restart", "automation": "- alias: storage_round_led_restart\n id: storage_round_led_restart\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /1\n conditions:\n - condition: state\n entity_id: light.round_led_st\n state: unavailable\n for:\n minutes: 2\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: state\n entity_id: switch.system_round_led_st_restart_key\n state: 'on'\n - condition: template\n value_template: '{% set ignore = [''unknown'', ''unavailable'', ''none''] %} {{\n states(''switch.sonoff_basic_2_relay'') not in ignore }}\n\n '\n actions:\n - repeat:\n while:\n - condition: state\n entity_id: light.round_led_st\n state: unavailable\n - condition: template\n value_template: '{{ repeat.index <= 5 }}'\n sequence:\n - action: switch.turn_off\n entity_id: switch.sonoff_basic_2_relay\n - delay:\n seconds: 15\n - action: switch.turn_on\n entity_id: switch.sonoff_basic_2_relay\n - action: notify.telegram\n data:\n message: 🚨 Round LED St restart done({{repeat.index}})!\n - delay:\n seconds: 30\n - condition: state\n entity_id: light.round_led_st\n state: unavailable\n - action: notify.telegram\n data:\n message: 🚨 Round LED St restart unsuccessful!\n - action: switch.turn_off\n entity_id: switch.system_round_led_st_restart_key", "config": [ { "name": "Round LED St", "room": null, "type": "light", "id": { "entity_id": "light.round_led_st", "device_id": null } }, { "name": "Sonoff Basic 2 Relay", "room": null, "type": "switch", "id": { "entity_id": "switch.sonoff_basic_2_relay", "device_id": null } }, { "name": "System Round LED St Restart Key", "room": null, "type": "switch", "id": { "entity_id": "switch.system_round_led_st_restart_key", "device_id": null } } ] }, { "id": "storage_round_led_restart_key_toggle", "automation": "- alias: storage_round_led_restart_key_toggle\n id: storage_round_led_restart_key_toggle\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: light.round_led_st\n from: unavailable\n actions:\n - action: switch.turn_on\n entity_id: switch.system_round_led_st_restart_key", "config": [ { "name": "Round LED St", "room": null, "type": "light", "id": { "entity_id": "light.round_led_st", "device_id": null } }, { "name": "System Round LED St Restart Key", "room": null, "type": "switch", "id": { "entity_id": "switch.system_round_led_st_restart_key", "device_id": null } } ] }, { "id": "system_breather_control_user", "automation": "- alias: system_breather_control_user\n id: system_breather_control_user\n initial_state: true\n mode: parallel\n triggers:\n - trigger: state\n entity_id: fan.breather_mb\n to: 'off'\n id: id_state_mb\n - trigger: state\n entity_id: fan.breather_s\n to: 'off'\n id: id_state_s\n conditions:\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: id_state_mb\n sequence:\n - action: switch.turn_off\n entity_id: switch.system_breather_manual_mb\n - conditions:\n - condition: trigger\n id: id_state_s\n sequence:\n - action: switch.turn_off\n entity_id: switch.system_breather_manual_s", "config": [ { "name": "system breather manual mb", "room": "master_bedroom", "type": "switch", "id": { "entity_id": "switch.system_breather_manual_mb", "device_id": null } }, { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "breather mb fan", "room": "master_bedroom", "type": "fan", "id": { "entity_id": "fan.breather_mb", "device_id": null } }, { "name": "system breather manual s", "room": "sasha_room", "type": "switch", "id": { "entity_id": "switch.system_breather_manual_s", "device_id": null } }, { "name": "breather s fan", "room": "sasha_room", "type": "fan", "id": { "entity_id": "fan.breather_s", "device_id": null } } ] }, { "id": "system_light_control", "automation": "- alias: system_light_control\n id: system_light_control\n initial_state: true\n triggers:\n - trigger: event\n event_type: yandex_intent\n event_data:\n text: Включи свет\n id: to_on_alice\n conditions:\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n actions:\n - choose:\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.entity_id == ''media_player.yandex_mb''\n }}'\n - condition: trigger\n id: to_on_alice\n sequence:\n - action: light.turn_on\n entity_id: light.round_led_mb\n data:\n brightness: 230\n color_temp_kelvin: 5000\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.entity_id == ''media_player.yandex_s''\n }}'\n sequence:\n - action: light.turn_on\n entity_id: light.square_led_s\n data:\n brightness: 230\n color_temp_kelvin: 5000\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.entity_id == ''media_player.yandex_v''\n }}'\n sequence:\n - action: light.turn_on\n entity_id: light.square_led_v\n data:\n brightness: 230\n color_temp_kelvin: 5000\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.entity_id == ''media_player.yandex_k''\n }}'\n - condition: trigger\n id: to_on_alice\n sequence:\n - action: light.turn_on\n entity_id: light.round_led_k\n data:\n brightness: 230\n color_temp_kelvin: 5000\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.entity_id == ''media_player.yandex_hb''\n }}'\n sequence:\n - action: light.turn_on\n entity_id: light.0x00158d000223921b_channel_1\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.entity_id == ''media_player.yandex_b''\n }}'\n sequence:\n - action: light.turn_on\n entity_id: light.0x00158d0002a36433_channel_2\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.entity_id == ''media_player.yandex_k''\n }}'\n - condition: trigger\n id: to_off_alice\n sequence:\n - action: light.turn_off\n entity_id: group.lights_k", "config": [ { "name": "yandex kitchen", "room": "kitchen", "type": "media_player", "id": { "entity_id": "media_player.yandex_k", "device_id": null } }, { "name": "yandex vova room", "room": "vova_room", "type": "media_player", "id": { "entity_id": "media_player.yandex_v", "device_id": null } }, { "name": "yandex sasha room", "room": "sasha_room", "type": "media_player", "id": { "entity_id": "media_player.yandex_s", "device_id": null } }, { "name": "yandex master bedroom", "room": "master_bedroom", "type": "media_player", "id": { "entity_id": "media_player.yandex_mb", "device_id": null } }, { "name": "yandex hall big", "room": "hall_big", "type": "media_player", "id": { "entity_id": "media_player.yandex_hb", "device_id": null } }, { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "bathroom channel 2 light", "room": "bathroom", "type": "light", "id": { "entity_id": "light.0x00158d0002a36433_channel_2", "device_id": null } }, { "name": "channel 1 light", "room": "hall_big", "type": "light", "id": { "entity_id": "light.0x00158d000223921b_channel_1", "device_id": null } }, { "name": "round led k", "room": "kitchen", "type": "light", "id": { "entity_id": "light.round_led_k", "device_id": null } }, { "name": "round led mb", "room": "master_bedroom", "type": "light", "id": { "entity_id": "light.round_led_mb", "device_id": null } }, { "name": "square led s", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.square_led_s", "device_id": null } }, { "name": "Lights K Group", "room": "Kitchen", "type": "group", "id": { "entity_id": "group.lights_k", "device_id": null } }, { "name": "Square LED V", "room": "Vova Room", "type": "light", "id": { "entity_id": "light.square_led_v", "device_id": null } } ] }, { "id": "system_presence_dima", "automation": "- alias: system_presence_dima\n id: system_presence_dima\n triggers:\n - trigger: state\n entity_id: person.dima\n not_from: home\n to: home\n for:\n seconds: 5\n id: to_just_arrived\n - trigger: state\n entity_id: input_select.dima_status_dropdown\n to: Just Arrived\n for:\n minutes: 3\n id: to_home\n - trigger: state\n entity_id: person.dima\n from: home\n for:\n seconds: 5\n id: to_just_left\n - trigger: state\n entity_id: input_select.dima_status_dropdown\n to: Just Left\n for:\n minutes: 3\n id: to_away\n - trigger: state\n entity_id: input_select.dima_status_dropdown\n to: Away\n for:\n hours: 6\n id: to_extended_away\n actions:\n - action: input_select.select_option\n data:\n entity_id: input_select.dima_status_dropdown\n option: '{{ trigger.id | replace(''to_'', '''', 1) | replace(''_'', '' '') |\n title }}'", "config": [ { "name": "person dima", "room": "system", "type": "person", "id": { "entity_id": "person.dima", "device_id": null } }, { "name": "Dima Status Dropdown", "room": null, "type": "input_select", "id": { "entity_id": "input_select.dima_status_dropdown", "device_id": null } } ] }, { "id": "system_presence_sandra", "automation": "- alias: system_presence_sandra\n id: system_presence_sandra\n triggers:\n - trigger: state\n entity_id: person.sandra\n not_from: home\n to: home\n for:\n seconds: 5\n id: to_just_arrived\n - trigger: state\n entity_id: input_select.sandra_status_dropdown\n to: Just Arrived\n for:\n minutes: 3\n id: to_home\n - trigger: state\n entity_id: person.sandra\n from: home\n for:\n seconds: 5\n id: to_just_left\n - trigger: state\n entity_id: input_select.sandra_status_dropdown\n to: Just Left\n for:\n minutes: 3\n id: to_away\n - trigger: state\n entity_id: input_select.sandra_status_dropdown\n to: Away\n for:\n hours: 6\n id: to_extended_away\n actions:\n - action: input_select.select_option\n data:\n entity_id: input_select.sandra_status_dropdown\n option: '{{ trigger.id | replace(''to_'', '''', 1) | replace(''_'', '' '') |\n title }}'", "config": [ { "name": "person sandra", "room": "system", "type": "person", "id": { "entity_id": "person.sandra", "device_id": null } }, { "name": "Sandra Status Dropdown", "room": null, "type": "input_select", "id": { "entity_id": "input_select.sandra_status_dropdown", "device_id": null } } ] }, { "id": "system_presence_vova", "automation": "- alias: system_presence_vova\n id: system_presence_vova\n triggers:\n - trigger: state\n entity_id: person.vova\n not_from: home\n to: home\n for:\n seconds: 5\n id: to_just_arrived\n - trigger: state\n entity_id: input_select.vova_status_dropdown\n to: Just Arrived\n for:\n minutes: 3\n id: to_home\n - trigger: state\n entity_id: person.vova\n from: home\n for:\n seconds: 5\n id: to_just_left\n - trigger: state\n entity_id: input_select.vova_status_dropdown\n to: Just Left\n for:\n minutes: 3\n id: to_away\n - trigger: state\n entity_id: input_select.vova_status_dropdown\n to: Away\n for:\n hours: 6\n id: to_extended_away\n actions:\n - action: input_select.select_option\n data:\n entity_id: input_select.vova_status_dropdown\n option: '{{ trigger.id | replace(''to_'', '''', 1) | replace(''_'', '' '') |\n title }}'", "config": [ { "name": "person vova", "room": "system", "type": "person", "id": { "entity_id": "person.vova", "device_id": null } }, { "name": "Vova Status Dropdown", "room": null, "type": "input_select", "id": { "entity_id": "input_select.vova_status_dropdown", "device_id": null } } ] }, { "id": "system_presence_sasha", "automation": "- alias: system_presence_sasha\n id: system_presence_sasha\n triggers:\n - trigger: state\n entity_id: person.sasha\n not_from: home\n to: home\n for:\n seconds: 5\n id: to_just_arrived\n - trigger: state\n entity_id: input_select.sasha_status_dropdown\n to: Just Arrived\n for:\n minutes: 3\n id: to_home\n - trigger: state\n entity_id: person.sasha\n from: home\n for:\n seconds: 5\n id: to_just_left\n - trigger: state\n entity_id: input_select.sasha_status_dropdown\n to: Just Left\n for:\n minutes: 3\n id: to_away\n - trigger: state\n entity_id: input_select.sasha_status_dropdown\n to: Away\n for:\n hours: 6\n id: to_extended_away\n actions:\n - action: input_select.select_option\n data:\n entity_id: input_select.sasha_status_dropdown\n option: '{{ trigger.id | replace(''to_'', '''', 1) | replace(''_'', '' '') |\n title }}'", "config": [ { "name": "person sasha", "room": "system", "type": "person", "id": { "entity_id": "person.sasha", "device_id": null } }, { "name": "Sasha Status Dropdown", "room": null, "type": "input_select", "id": { "entity_id": "input_select.sasha_status_dropdown", "device_id": null } } ] }, { "id": "system_presence_vova_at_home", "automation": "- alias: system_presence_vova_at_home\n id: system_presence_vova_at_home\n initial_state: true\n triggers:\n - trigger: state\n entity_id: person.vova\n to: home\n for:\n minutes: 3\n actions:\n - action: notify.telegram\n data:\n message: 👱 Вова дома", "config": [ { "name": "person vova", "room": "system", "type": "person", "id": { "entity_id": "person.vova", "device_id": null } } ] }, { "id": "system_presence_sandra_at_home", "automation": "- alias: system_presence_sandra_at_home\n id: system_presence_sandra_at_home\n initial_state: true\n triggers:\n - trigger: state\n entity_id: person.sandra\n to: home\n for:\n minutes: 3\n actions:\n - action: notify.telegram\n data:\n message: 👧 Саша дома", "config": [ { "name": "person sandra", "room": "system", "type": "person", "id": { "entity_id": "person.sandra", "device_id": null } } ] }, { "id": "system_sasha_tracker", "automation": "- alias: system_sasha_tracker\n id: system_sasha_tracker\n initial_state: true\n triggers:\n - trigger: state\n entity_id: input_boolean.sasha_tracker\n actions:\n - action: device_tracker.see\n data:\n dev_id: sasha\n location_name: '{% if is_state(''input_boolean.sasha_tracker'',''on'')%}home{%else%}not_home{%endif%}'", "config": [ { "name": "Sasha Tracker", "room": null, "type": "input_boolean", "id": { "entity_id": "input_boolean.sasha_tracker", "device_id": null } } ] }, { "id": "system_guest_tracker", "automation": "- alias: system_guest_tracker\n id: system_guest_tracker\n initial_state: true\n triggers:\n - trigger: state\n entity_id: switch.system_guest_mode\n conditions:\n - condition: template\n value_template: \"{% set ignore = ['unknown', 'unavailable', 'none'] %} {{ trigger.from_state.state\\\n \\ not in ignore and\\n trigger.to_state.state not in ignore and\\n trigger.to_state.state\\\n \\ = trigger.from_state.state }}\\n\"\n actions:\n - action: device_tracker.see\n data:\n dev_id: guest\n location_name: '{% if is_state(''switch.system_guest_mode'',''on'')%}home{%else%}not_home{%endif%}'", "config": [ { "name": "System Guest Mode", "room": null, "type": "switch", "id": { "entity_id": "switch.system_guest_mode", "device_id": null } } ] }, { "id": "system_sasha_audio_tts", "automation": "- alias: system_sasha_audio_tts\n id: system_sasha_audio_tts\n initial_state: true\n triggers:\n - trigger: state\n entity_id: input_boolean.sasha_tracker\n conditions:\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'on'\n - condition: state\n entity_id: switch.system_dark_mode\n state: 'off'\n actions:\n - action: media_player.volume_set\n data:\n entity_id:\n - media_player.yandex_hb\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id: media_player.yandex_hb\n media_content_id: '{% set name1 = [''С+аша, '',''Сан+ёк, '',''Алекс+андр, '',''М+итрич,\n '',''Алекс+андр Дм+итриевич, '', ''М+аленький хоз+яин, '', ''З+аяц, '', ''Зайка,\n ''] | random %} {% set greet2 = [''пок+а'',''до свид+ания'',''до встр+ечи'',''чава-как+ава'',''всег+о\n хор+ошего'', ''я б+уду скуч+ать''] | random %} {% set greet1 = [''прив+ет'',''здар+ова'',''здр+авствуй'',''здр+авия\n жел+аю'',''сал+ют'','' Ур+а Ур+а Ты верн+улся дом+ой''] | random %} {{name1}}\n {% if is_state(''input_boolean.sasha_tracker'',''on'')%}{{greet1}}{%else%}{{greet2}}{%endif%}'\n - action: notify.telegram\n data:\n message: Фотография\n data:\n photo:\n - url: secret entrance_snap\n caption: 👶 Санек {%if is_state('input_boolean.sasha_tracker','on')%}дома{%else%}уходит{%endif%}", "config": [ { "name": "yandex hall big", "room": "hall_big", "type": "media_player", "id": { "entity_id": "media_player.yandex_hb", "device_id": null } }, { "name": "system dark mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_dark_mode", "device_id": null } }, { "name": "main volume", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.main_volume", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "alice mode", "room": "system", "type": "input_select", "id": { "entity_id": "input_select.alice_mode", "device_id": null } }, { "name": "Sasha Tracker", "room": null, "type": "input_boolean", "id": { "entity_id": "input_boolean.sasha_tracker", "device_id": null } } ] }, { "id": "system_presence_sergey_at_home", "automation": "- alias: system_presence_sergey_at_home\n id: system_presence_sergey_at_home\n initial_state: true\n triggers:\n - trigger: state\n entity_id: person.sergey\n to: home\n from: not_home\n actions:\n - action: notify.telegram\n data:\n message: 👴 Сережа пришел", "config": [ { "name": "Sergey", "room": null, "type": "person", "id": { "entity_id": "person.sergey", "device_id": null } } ] }, { "id": "system_presence_lena_at_home", "automation": "- alias: system_presence_lena_at_home\n id: system_presence_lena_at_home\n initial_state: true\n triggers:\n - trigger: state\n entity_id: person.elena\n to: home\n from: not_home\n actions:\n - action: notify.telegram\n data:\n message: 👱 Лена пришла", "config": [ { "name": "Elena", "room": null, "type": "person", "id": { "entity_id": "person.elena", "device_id": null } } ] }, { "id": "system_presence_mama_at_home", "automation": "- alias: system_presence_mama_at_home\n id: system_presence_mama_at_home\n initial_state: true\n triggers:\n - trigger: state\n entity_id: person.natasha\n to: home\n from: not_home\n actions:\n - action: notify.telegram\n data:\n message: 👱 Мама пришла", "config": [ { "name": "Natasha", "room": null, "type": "person", "id": { "entity_id": "person.natasha", "device_id": null } } ] }, { "id": "system_presence_papa_at_home", "automation": "- alias: system_presence_papa_at_home\n id: system_presence_papa_at_home\n initial_state: true\n triggers:\n - trigger: state\n entity_id: person.vasya\n to: home\n from: not_home\n actions:\n - action: notify.telegram\n data:\n message: 👱 Папа пришел", "config": [ { "name": "Vasya", "room": null, "type": "person", "id": { "entity_id": "person.vasya", "device_id": null } } ] }, { "id": "toilet_fan_on", "automation": "- alias: toilet_fan_on\n id: toilet_fan_on\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0001b97111_action\n click_type: single\n conditions:\n - condition: state\n entity_id: group.lights_t\n state: 'on'\n - condition: state\n entity_id: fan.esp32_node_b_fan_t\n state: 'off'\n - condition: state\n entity_id: switch.esp32_node_b_fan_b_manual_mode\n state: 'off'\n actions:\n - action: fan.turn_off\n entity_id: fan.esp32_node_b_fan_b\n - action: fan.turn_on\n entity_id: fan.esp32_node_b_fan_t", "config": [ { "name": "esp32 node b fan b", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.esp32_node_b_fan_b", "device_id": null } }, { "name": "esp32 node b fan b manual mode", "room": "bathroom", "type": "switch", "id": { "entity_id": "switch.esp32_node_b_fan_b_manual_mode", "device_id": null } }, { "name": "esp32 node b fan t", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.esp32_node_b_fan_t", "device_id": null } }, { "name": "Lights T Group", "room": null, "type": "group", "id": { "entity_id": "group.lights_t", "device_id": null } }, { "name": "Action Sensor 1b97111", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x00158d0001b97111_action", "device_id": null } } ] }, { "id": "toilet_fan_off", "automation": "- alias: toilet_fan_off\n id: toilet_fan_off\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0001b97111_action\n click_type: single\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.fan_t\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.short_fan_t\n conditions:\n - condition: state\n entity_id: fan.esp32_node_b_fan_t\n state: 'on'\n actions:\n - action: fan.turn_off\n entity_id: fan.esp32_node_b_fan_t\n - action: timer.cancel\n entity_id: timer.fan_t", "config": [ { "name": "esp32 node b fan t", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.esp32_node_b_fan_t", "device_id": null } }, { "name": "timer fan t", "room": "bathroom", "type": "timer", "id": { "entity_id": "timer.fan_t", "device_id": null } }, { "name": "Action Sensor 1b97111", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x00158d0001b97111_action", "device_id": null } }, { "name": "Short Fan T Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.short_fan_t", "device_id": null } } ] }, { "id": "toilet_fan_timer_on", "automation": "- alias: toilet_fan_timer_on\n id: toilet_fan_timer_on\n initial_state: true\n triggers:\n - trigger: state\n entity_id: fan.esp32_node_b_fan_t\n to: 'on'\n actions:\n - action: timer.cancel\n entity_id: timer.fan_t\n - action: timer.start\n entity_id: timer.fan_t", "config": [ { "name": "esp32 node b fan t", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.esp32_node_b_fan_t", "device_id": null } }, { "name": "timer fan t", "room": "bathroom", "type": "timer", "id": { "entity_id": "timer.fan_t", "device_id": null } } ] }, { "id": "toilet_fan_timer_restart", "automation": "- alias: toilet_fan_timer_restart\n id: toilet_fan_timer_restart\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0001e54280_motion\n conditions:\n - condition: state\n entity_id: binary_sensor.0x00158d000232ddd6_contact\n state: 'on'\n - condition: state\n entity_id: fan.esp32_node_b_fan_t\n state: 'on'\n - condition: template\n value_template: '{{(as_timestamp(now()) - as_timestamp(state_attr(''automation.toilet_fan_timer_restart'',\n ''last_triggered''),0)|int(0)) > 10 }}'\n actions:\n - action: timer.cancel\n entity_id: timer.fan_t\n - action: timer.start\n entity_id: timer.fan_t", "config": [ { "name": "esp32 node b fan t", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.esp32_node_b_fan_t", "device_id": null } }, { "name": "timer fan t", "room": "bathroom", "type": "timer", "id": { "entity_id": "timer.fan_t", "device_id": null } }, { "name": "Motion Sensor 1e54280", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001e54280_motion", "device_id": null } }, { "name": "Contact Sensor 232ddd6", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d000232ddd6_contact", "device_id": null } } ] }, { "id": "toilet_fan_auto", "automation": "- alias: toilet_fan_auto\n id: toilet_fan_auto\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /30\n conditions:\n - condition: state\n entity_id: input_boolean.auto_fan_t\n state: 'on'\n - condition: state\n entity_id: switch.esp32_node_b_fan_b_manual_mode\n state: 'off'\n - condition: state\n entity_id: fan.esp32_node_b_fan_t\n state: 'off'\n - condition: state\n entity_id: timer.fan_b\n state: idle\n - condition: template\n value_template: '{{(as_timestamp(now())|int(0) - as_timestamp(states.fan.esp32_node_b_fan_t.last_changed)|int(0)\n ) > 20*60 }}'\n - condition: template\n value_template: '{{not (6>=now().hour|int(0) >=0 or is_state(''switch.system_security_mode'',''on'')\n or (is_state(''binary_sensor.0x00158d0001ef2ffc_contact'',''on'') and (as_timestamp(now())-as_timestamp(states.binary_sensor[''0x00158d0001ef2ffc_contact''].last_changed)\n > 10*60)))}}'\n actions:\n - action: fan.turn_off\n entity_id: fan.esp32_node_b_fan_b\n - action: fan.turn_on\n entity_id: fan.esp32_node_b_fan_t", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "esp32 node b fan b", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.esp32_node_b_fan_b", "device_id": null } }, { "name": "esp32 node b fan b manual mode", "room": "bathroom", "type": "switch", "id": { "entity_id": "switch.esp32_node_b_fan_b_manual_mode", "device_id": null } }, { "name": "esp32 node b fan t", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.esp32_node_b_fan_t", "device_id": null } }, { "name": "timer fan b", "room": "bathroom", "type": "timer", "id": { "entity_id": "timer.fan_b", "device_id": null } }, { "name": "sasha door contact", "room": "hall_small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001ef2ffc_contact", "device_id": null } }, { "name": "Auto Fan T", "room": null, "type": "input_boolean", "id": { "entity_id": "input_boolean.auto_fan_t", "device_id": null } } ] }, { "id": "toilet_light_off_auto", "automation": "- alias: toilet_light_off_auto\n id: toilet_light_off_auto\n initial_state: true\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.main_light_t\n conditions:\n - condition: state\n entity_id: binary_sensor.presence_t\n state: 'off'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: state\n entity_id: group.lights_t\n state: 'on'\n actions:\n - action: light.turn_off\n entity_id: light.0x00158d0002a36f7f_channel_1\n - action: light.turn_off\n entity_id: light.esp32_node_b_light\n data:\n transition: 5", "config": [ { "name": "Presence T", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.presence_t", "device_id": null } }, { "name": "Lights T Group", "room": null, "type": "group", "id": { "entity_id": "group.lights_t", "device_id": null } }, { "name": "Light Channel 1 2a36f7f", "room": null, "type": "light", "id": { "entity_id": "light.0x00158d0002a36f7f_channel_1", "device_id": null } }, { "name": "ESP32 Node B Light", "room": "Bathroom", "type": "light", "id": { "entity_id": "light.esp32_node_b_light", "device_id": null } }, { "name": "Main Light T Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.main_light_t", "device_id": null } } ] }, { "id": "toilet_timer_on", "automation": "- alias: toilet_timer_on\n id: toilet_timer_on\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.presence_t\n from: 'on'\n to: 'off'\n - trigger: state\n entity_id: group.lights_t\n to: 'on'\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_t\n - action: timer.start\n entity_id: timer.main_light_t", "config": [ { "name": "Presence T", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.presence_t", "device_id": null } }, { "name": "Lights T Group", "room": null, "type": "group", "id": { "entity_id": "group.lights_t", "device_id": null } }, { "name": "Main Light T Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.main_light_t", "device_id": null } } ] }, { "id": "toilet_timer_stop", "automation": "- alias: toilet_timer_stop\n id: toilet_timer_stop\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.presence_t\n from: 'off'\n to: 'on'\n - trigger: state\n entity_id: group.lights_t\n to: 'off'\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_t, timer.door_t", "config": [ { "name": "Presence T", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.presence_t", "device_id": null } }, { "name": "Lights T Group", "room": null, "type": "group", "id": { "entity_id": "group.lights_t", "device_id": null } }, { "name": "Door T Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.door_t", "device_id": null } }, { "name": "Main Light T Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.main_light_t", "device_id": null } } ] }, { "id": "toilet_timer_stop_motion_with_light_presence", "automation": "- alias: toilet_timer_stop_motion_with_light_presence\n id: toilet_timer_stop_motion_with_light_presence\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x00158d0001e54280_motion\n to: 'on'\n conditions:\n and:\n - condition: state\n entity_id: binary_sensor.presence_t\n state: 'on'\n - condition: state\n entity_id: group.lights_t\n state: 'on'\n - or:\n - condition: state\n entity_id: timer.main_light_t\n state: active\n - condition: state\n entity_id: timer.door_t\n state: active\n actions:\n - action: timer.cancel\n entity_id: timer.main_light_t, timer.door_t", "config": [ { "name": "Motion Sensor 1e54280", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001e54280_motion", "device_id": null } }, { "name": "Presence T", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.presence_t", "device_id": null } }, { "name": "Lights T Group", "room": null, "type": "group", "id": { "entity_id": "group.lights_t", "device_id": null } }, { "name": "Door T Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.door_t", "device_id": null } }, { "name": "Main Light T Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.main_light_t", "device_id": null } } ] }, { "id": "toilet_auto_light_on", "automation": "- alias: toilet_auto_light_on\n id: toilet_auto_light_on\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0001e54280_motion\n - trigger: state\n entity_id: binary_sensor.0x00158d000232ddd6_contact\n to: 'on'\n from: 'off'\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0001b97111_action\n click_type: single\n conditions:\n - condition: state\n entity_id: group.lights_t\n state: 'off'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'on'\n sequence:\n - action: light.turn_on\n entity_id: light.0x00158d0002a36f7f_channel_1\n - conditions:\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'off'\n sequence:\n - action: light.turn_on\n entity_id: light.esp32_node_b_light", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "Motion Sensor 1e54280", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001e54280_motion", "device_id": null } }, { "name": "Contact Sensor 232ddd6", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d000232ddd6_contact", "device_id": null } }, { "name": "Lights T Group", "room": null, "type": "group", "id": { "entity_id": "group.lights_t", "device_id": null } }, { "name": "Light Channel 1 2a36f7f", "room": null, "type": "light", "id": { "entity_id": "light.0x00158d0002a36f7f_channel_1", "device_id": null } }, { "name": "ESP32 Node B Light", "room": "Bathroom", "type": "light", "id": { "entity_id": "light.esp32_node_b_light", "device_id": null } }, { "name": "Action Sensor 1b97111", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x00158d0001b97111_action", "device_id": null } } ] }, { "id": "toilet_light_toggle", "automation": "- alias: toilet_light_toggle\n id: toilet_light_toggle\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x54ef4410005054cc_action\n click_type: button_2_single\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: group.lights_t\n state: 'on'\n sequence:\n - action: light.turn_off\n entity_id: light.0x00158d0002a36f7f_channel_1, light.esp32_node_b_light\n - conditions:\n - condition: state\n entity_id: group.lights_t\n state: 'off'\n sequence:\n - action: light.turn_on\n entity_id: light.0x00158d0002a36f7f_channel_1", "config": [ { "name": "action sensor bathroom repeater", "room": "bathroom", "type": "sensor", "id": { "entity_id": "sensor.0x54ef4410005054cc_action", "device_id": null } }, { "name": "Lights T Group", "room": null, "type": "group", "id": { "entity_id": "group.lights_t", "device_id": null } }, { "name": "Light Channel 1 2a36f7f", "room": null, "type": "light", "id": { "entity_id": "light.0x00158d0002a36f7f_channel_1", "device_id": null } }, { "name": "ESP32 Node B Light", "room": "Bathroom", "type": "light", "id": { "entity_id": "light.esp32_node_b_light", "device_id": null } } ] }, { "id": "toilet_indicator", "automation": "- alias: toilet_indicator\n id: toilet_indicator\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x00158d000232ddd6_contact\n to: null\n conditions:\n - condition: template\n value_template: \"{% set ignore = ['unknown', 'unavailable', 'none'] %} {{ trigger.from_state.state\\\n \\ not in ignore and\\n trigger.to_state.state not in ignore and\\n trigger.to_state.state\\\n \\ != trigger.from_state.state\\n}}\"\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: binary_sensor.0x00158d000232ddd6_contact\n state: 'on'\n sequence:\n - action: light.turn_on\n data:\n entity_id: light.esp32_node_hs_toilet\n effect: Color Wipe\n brightness: 100\n default:\n - action: light.turn_off\n entity_id: light.esp32_node_hs_toilet", "config": [ { "name": "Contact Sensor 232ddd6", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d000232ddd6_contact", "device_id": null } }, { "name": "ESP32 Node HS Toilet", "room": "Hall Small", "type": "light", "id": { "entity_id": "light.esp32_node_hs_toilet", "device_id": null } } ] }, { "id": "vova_breather_auto_co2", "automation": "- alias: vova_breather_auto_co2\n id: vova_breather_auto_co2\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /3\n conditions:\n - condition: state\n entity_id: switch.system_breather_auto_v\n state: 'on'\n - condition: not\n conditions:\n - condition: state\n entity_id: switch.system_breather_manual_v\n state: 'on'\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: binary_sensor.0x00158d0003fa6cf5_contact\n state: 'off'\n - condition: numeric_state\n entity_id: sensor.esp32_node_v_co2\n above: input_number.co2_high_limit\n - condition: state\n entity_id: binary_sensor.breather_v\n state: 'off'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n sequence:\n - action: fan.turn_on\n entity_id: fan.breather_v\n - condition: numeric_state\n entity_id: sensor.esp32_node_v_co2\n above: input_number.co2_high_limit\n - condition: state\n entity_id: switch.system_breather_auto_speed_v\n state: 'on'\n - action: fan.set_percentage\n entity_id: fan.breather_v\n data:\n percentage: '{{states(''sensor.breather_set_speed_v'')|int(0) }}'\n - conditions:\n - condition: state\n entity_id: binary_sensor.0x00158d0003fa6cf5_contact\n state: 'off'\n - condition: numeric_state\n entity_id: sensor.esp32_node_v_co2\n above: input_number.co2_high_limit\n - condition: state\n entity_id: binary_sensor.breather_v\n state: 'on'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: state\n entity_id: switch.system_breather_auto_speed_v\n state: 'on'\n - condition: numeric_state\n entity_id: sensor.breather_set_speed_v\n above: 0\n sequence:\n - action: fan.set_percentage\n entity_id: fan.breather_v\n data:\n percentage: '{{states(''sensor.breather_set_speed_v'')|int(0) }}'\n - conditions:\n - condition: state\n entity_id: binary_sensor.0x00158d0003fa6cf5_contact\n state: 'off'\n - condition: numeric_state\n entity_id: sensor.esp32_node_v_co2\n below: input_number.co2_low_limit\n - condition: state\n entity_id: binary_sensor.breather_v\n state: 'on'\n sequence:\n - action: fan.turn_off\n entity_id: fan.breather_v\n - conditions:\n - condition: state\n entity_id: binary_sensor.0x00158d0003fa6cf5_contact\n state: 'on'\n - condition: state\n entity_id: binary_sensor.breather_v\n state: 'on'\n sequence:\n - action: fan.turn_off\n entity_id: fan.breather_v", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "co2 high limit", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.co2_high_limit", "device_id": null } }, { "name": "co2 low limit", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.co2_low_limit", "device_id": null } }, { "name": "system breather auto s", "room": "sasha_room", "type": "switch", "id": { "entity_id": "switch.system_breather_auto_s", "device_id": null } }, { "name": "Contact Sensor 3fa6cf5", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0003fa6cf5_contact", "device_id": null } }, { "name": "Breather V", "room": "Vova Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.breather_v", "device_id": null } }, { "name": "Breather V Fan", "room": "Vova Room", "type": "fan", "id": { "entity_id": "fan.breather_v", "device_id": null } }, { "name": "Breather Set Speed V", "room": "Vova Room", "type": "sensor", "id": { "entity_id": "sensor.breather_set_speed_v", "device_id": null } }, { "name": "ESP32 Node V CO2", "room": "Vova Room", "type": "sensor", "id": { "entity_id": "sensor.esp32_node_v_co2", "device_id": null } }, { "name": "System Breather Auto Speed V", "room": null, "type": "switch", "id": { "entity_id": "switch.system_breather_auto_speed_v", "device_id": null } }, { "name": "System Breather Auto V", "room": null, "type": "switch", "id": { "entity_id": "switch.system_breather_auto_v", "device_id": null } }, { "name": "System Breather Manual V", "room": null, "type": "switch", "id": { "entity_id": "switch.system_breather_manual_v", "device_id": null } } ] }, { "id": "vova_breather_auto_timer", "automation": "- alias: vova_breather_auto_timer\n id: vova_breather_auto_timer\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.digma_ir_v_breather_remote_used\n to: 'on'\n id: ir_used_remote\n - trigger: event\n event_type: yandex_intent\n event_data:\n text: Выключи вентиляцию\n id: to_off_alice\n - trigger: event\n event_type: yandex_intent\n event_data:\n text: Включи вентиляцию\n id: to_on_alice\n - trigger: time\n at: '21:00:00'\n id: time_trigger_night\n - trigger: time\n at: 09:00:00\n id: time_trigger_day\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: to_off_alice\n sequence:\n - condition: template\n value_template: '{{ trigger.event.data.entity_id == ''media_player.yandex_v''\n }}'\n - if:\n - condition: state\n entity_id: binary_sensor.breather_v\n state: 'on'\n then:\n - action: fan.turn_off\n entity_id: fan.breather_v\n - action: switch.turn_on\n entity_id: switch.system_breather_auto_v\n - conditions:\n - condition: trigger\n id: to_on_alice\n sequence:\n - condition: template\n value_template: '{{ trigger.event.data.entity_id == ''media_player.yandex_v''\n }}'\n - if:\n - condition: state\n entity_id: binary_sensor.breather_v\n state: 'off'\n then:\n - action: switch.turn_on\n entity_id: switch.system_breather_manual_v\n - action: fan.turn_on\n entity_id: fan.breather_v\n - conditions:\n - condition: trigger\n id: time_trigger_night\n sequence:\n - action: switch.turn_on\n entity_id: switch.system_breather_manual_v\n - action: fan.set_percentage\n entity_id: fan.breather_v\n data:\n percentage: 50\n - action: fan.set_preset_mode\n data:\n entity_id: fan.purifier2s\n preset_mode: Silent\n - conditions:\n - condition: trigger\n id: time_trigger_day\n sequence:\n - action: fan.turn_off\n entity_id: fan.breather_v\n - action: timer.cancel\n entity_id: timer.breather_v\n - action: switch.turn_on\n entity_id: switch.system_breather_auto_v\n - action: fan.set_preset_mode\n data:\n entity_id: fan.purifier2s\n preset_mode: Silent", "config": [ { "name": "yandex vova room", "room": "vova_room", "type": "media_player", "id": { "entity_id": "media_player.yandex_v", "device_id": null } }, { "name": "Breather V", "room": "Vova Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.breather_v", "device_id": null } }, { "name": "Digma IR V Breather Remote Used", "room": "Vova Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.digma_ir_v_breather_remote_used", "device_id": null } }, { "name": "Breather V Fan", "room": "Vova Room", "type": "fan", "id": { "entity_id": "fan.breather_v", "device_id": null } }, { "name": "Purifier2s Fan", "room": null, "type": "fan", "id": { "entity_id": "fan.purifier2s", "device_id": null } }, { "name": "System Breather Auto V", "room": null, "type": "switch", "id": { "entity_id": "switch.system_breather_auto_v", "device_id": null } }, { "name": "System Breather Manual V", "room": null, "type": "switch", "id": { "entity_id": "switch.system_breather_manual_v", "device_id": null } }, { "name": "Breather V Timer", "room": "Vova Room", "type": "timer", "id": { "entity_id": "timer.breather_v", "device_id": null } } ] }, { "id": "vova_breather_plug_toggle", "automation": "- alias: vova_breather_plug_toggle\n id: vova_breather_plug_toggle\n initial_state: true\n max_exceeded: silent\n mode: queued\n max: 10\n triggers:\n - trigger: state\n entity_id: switch.0x00158d000344998e_plug\n to: 'off'\n for:\n seconds: 30\n conditions:\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n actions:\n - action: switch.turn_on\n entity_id: switch.0x00158d000344998e_plug", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "Switch Plug 344998e", "room": null, "type": "switch", "id": { "entity_id": "switch.0x00158d000344998e_plug", "device_id": null } } ] }, { "id": "vova_breather_switches_interlock", "automation": "- alias: vova_breather_switches_interlock\n id: vova_breather_switches_interlock\n triggers:\n - trigger: state\n entity_id:\n - switch.system_hourly_mode_breather_v\n - switch.system_breather_auto_v\n - switch.system_breather_manual_v\n conditions:\n - condition: template\n value_template: '{{ trigger.to_state.state == ''on'' }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: homeassistant.turn_off\n target:\n entity_id: '{% if trigger.from_state.entity_id == ''switch.system_hourly_mode_breather_v''\n %} {{ ''switch.system_breather_auto_v'', ''switch.system_breather_manual_v''\n }} {% elif trigger.from_state.entity_id == ''switch.system_breather_auto_v''\n %} {{ ''switch.system_hourly_mode_breather_v'', ''switch.system_breather_manual_v''\n }} {% else %} {{ ''switch.system_hourly_mode_breather_v'', ''switch.system_breather_auto_v''\n }} {% endif %}'", "config": [ { "name": "System Breather Auto V", "room": null, "type": "switch", "id": { "entity_id": "switch.system_breather_auto_v", "device_id": null } }, { "name": "System Breather Manual V", "room": null, "type": "switch", "id": { "entity_id": "switch.system_breather_manual_v", "device_id": null } }, { "name": "System Hourly Mode Breather V", "room": null, "type": "switch", "id": { "entity_id": "switch.system_hourly_mode_breather_v", "device_id": null } } ] }, { "id": "vova_breather_switches_default", "automation": "- alias: vova_breather_switches_default\n id: vova_breather_switches_default\n triggers:\n - trigger: template\n value_template: '{{ is_state(''switch.system_hourly_mode_breather_v'',''off'')\n and is_state(''switch.system_breather_auto_v'',''off'') and is_state(''switch.system_breather_manual_v'',''off'')\n }}'\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: switch.turn_on\n entity_id: switch.system_breather_auto_v", "config": [ { "name": "System Breather Auto V", "room": null, "type": "switch", "id": { "entity_id": "switch.system_breather_auto_v", "device_id": null } }, { "name": "System Breather Manual V", "room": null, "type": "switch", "id": { "entity_id": "switch.system_breather_manual_v", "device_id": null } }, { "name": "System Hourly Mode Breather V", "room": null, "type": "switch", "id": { "entity_id": "switch.system_hourly_mode_breather_v", "device_id": null } } ] }, { "id": "vova_main_lamp_left_button", "automation": "- alias: vova_main_lamp_left_button\n id: vova_main_lamp_left_button\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0001712d55_action\n click_type: button_1_single\n conditions:\n - condition: template\n value_template: '{{ states(''light.square_led_v'') in [''on'',''off''] and states(''light.square_led_v_nightlight'')\n in [''on'',''off''] }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: binary_sensor.square_led_v_nightlight\n state: 'on'\n - condition: state\n entity_id: group.lights_main_v\n state: 'off'\n sequence:\n - action: yeelight.set_mode\n data:\n entity_id: light.square_led_v\n mode: normal\n - action: light.turn_on\n entity_id: light.square_led_v\n data:\n brightness: 230\n color_temp_kelvin: 5000\n - conditions:\n - condition: state\n entity_id: binary_sensor.square_led_v_nightlight\n state: 'off'\n - condition: state\n entity_id: group.lights_main_v\n state: 'off'\n sequence:\n - action: light.turn_on\n entity_id: light.square_led_v\n data:\n brightness: 230\n color_temp_kelvin: 5000\n - conditions:\n - condition: state\n entity_id: group.lights_main_v\n state: 'on'\n sequence:\n - action: light.turn_off\n entity_id: light.square_led_v, light.square_led_v_nightlight", "config": [ { "name": "Square LED V Nightlight", "room": "Vova Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.square_led_v_nightlight", "device_id": null } }, { "name": "Lights Main V Group", "room": "Vova Room", "type": "group", "id": { "entity_id": "group.lights_main_v", "device_id": null } }, { "name": "Square LED V", "room": "Vova Room", "type": "light", "id": { "entity_id": "light.square_led_v", "device_id": null } }, { "name": "Square LED V Nightlight", "room": "Vova Room", "type": "light", "id": { "entity_id": "light.square_led_v_nightlight", "device_id": null } }, { "name": "Action Sensor 1712d55", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x00158d0001712d55_action", "device_id": null } } ] }, { "id": "vova_main_lamp_right_button", "automation": "- alias: vova_main_lamp_right_button\n id: vova_main_lamp_right_button\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0001712d55_action\n click_type: button_2_single\n conditions:\n - condition: template\n value_template: '{{ states(''light.square_led_v'') in [''on'',''off''] and states(''light.square_led_v_nightlight'')\n in [''on'',''off''] }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: binary_sensor.square_led_v_nightlight\n state: 'on'\n - condition: state\n entity_id: group.lights_main_v\n state: 'off'\n sequence:\n - action: yeelight.set_mode\n data:\n entity_id: light.square_led_v\n mode: normal\n - action: light.turn_on\n entity_id: light.square_led_v\n data:\n brightness: 14\n color_temp_kelvin: 3000\n - conditions:\n - condition: state\n entity_id: binary_sensor.square_led_v_nightlight\n state: 'off'\n - condition: state\n entity_id: group.lights_main_v\n state: 'off'\n sequence:\n - action: light.turn_on\n entity_id: light.square_led_v\n data:\n brightness: 14\n color_temp_kelvin: 3000\n - conditions:\n - condition: state\n entity_id: group.lights_main_v\n state: 'on'\n sequence:\n - action: light.turn_off\n entity_id: light.square_led_v, light.square_led_v_nightlight", "config": [ { "name": "Square LED V Nightlight", "room": "Vova Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.square_led_v_nightlight", "device_id": null } }, { "name": "Lights Main V Group", "room": "Vova Room", "type": "group", "id": { "entity_id": "group.lights_main_v", "device_id": null } }, { "name": "Square LED V", "room": "Vova Room", "type": "light", "id": { "entity_id": "light.square_led_v", "device_id": null } }, { "name": "Square LED V Nightlight", "room": "Vova Room", "type": "light", "id": { "entity_id": "light.square_led_v_nightlight", "device_id": null } }, { "name": "Action Sensor 1712d55", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x00158d0001712d55_action", "device_id": null } } ] }, { "id": "vova_square_led_restart", "automation": "- alias: vova_square_led_restart\n id: vova_square_led_restart\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /1\n conditions:\n - condition: state\n entity_id: light.square_led_v\n state: unavailable\n for:\n minutes: 2\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: state\n entity_id: switch.system_square_led_v_restart_key\n state: 'on'\n - condition: template\n value_template: \"{% set ignore = ['unknown', 'unavailable', 'none'] %} {{ states('switch.shelly_1pm_led_v')\\\n \\ not in ignore }} \\n\"\n actions:\n - repeat:\n while:\n - condition: state\n entity_id: light.square_led_v\n state: unavailable\n - condition: template\n value_template: '{{ repeat.index <= 5 }}'\n sequence:\n - action: switch.turn_off\n entity_id: switch.shelly_1pm_led_v\n - delay:\n seconds: 15\n - action: switch.turn_on\n entity_id: switch.shelly_1pm_led_v\n - action: notify.telegram\n data:\n message: 🚨 Square LED V restart done({{repeat.index}})!\n - delay:\n seconds: 30\n - condition: state\n entity_id: light.square_led_v\n state: unavailable\n - action: notify.telegram\n data:\n message: 🚨 Square LED V restart unsuccessful!\n - action: switch.turn_off\n entity_id: switch.system_square_led_v_restart_key", "config": [ { "name": "Square LED V", "room": "Vova Room", "type": "light", "id": { "entity_id": "light.square_led_v", "device_id": null } }, { "name": "Shelly 1PM LED V", "room": "Vova Room", "type": "switch", "id": { "entity_id": "switch.shelly_1pm_led_v", "device_id": null } }, { "name": "System Square LED V Restart Key", "room": null, "type": "switch", "id": { "entity_id": "switch.system_square_led_v_restart_key", "device_id": null } } ] }, { "id": "vova_square_led_restart_key_toggle", "automation": "- alias: vova_square_led_restart_key_toggle\n id: vova_square_led_restart_key_toggle\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: light.square_led_v\n from: unavailable\n actions:\n - action: switch.turn_on\n entity_id: switch.system_square_led_v_restart_key", "config": [ { "name": "Square LED V", "room": "Vova Room", "type": "light", "id": { "entity_id": "light.square_led_v", "device_id": null } }, { "name": "System Square LED V Restart Key", "room": null, "type": "switch", "id": { "entity_id": "switch.system_square_led_v_restart_key", "device_id": null } } ] }, { "id": "vova_main_lamp_switch_on_if_off", "automation": "- alias: vova_main_lamp_switch_on_if_off\n id: vova_main_lamp_switch_on_if_off\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0001712d55_action\n click_type: button_1_single\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0001712d55_action\n click_type: button_2_single\n conditions:\n - condition: state\n entity_id: switch.shelly_1pm_led_v\n state: 'off'\n actions:\n - action: switch.turn_on\n entity_id: switch.shelly_1pm_led_v", "config": [ { "name": "Action Sensor 1712d55", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x00158d0001712d55_action", "device_id": null } }, { "name": "Shelly 1PM LED V", "room": "Vova Room", "type": "switch", "id": { "entity_id": "switch.shelly_1pm_led_v", "device_id": null } } ] }, { "id": "vova_main_lamp_off_bed_strips_on", "automation": "- alias: vova_main_lamp_off_bed_strips_on\n id: vova_main_lamp_off_bed_strips_on\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: group.lights_main_v\n to: 'off'\n conditions:\n - condition: state\n entity_id: binary_sensor.light_outside_mi\n state: 'off'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: light.turn_on\n entity_id: light.d1mini_bed_leds_strip_dima, light.d1mini_bed_leds_strip_sandra\n data:\n brightness: 26", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "light outside mi", "room": "outside", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.light_outside_mi", "device_id": null } }, { "name": "Lights Main V Group", "room": "Vova Room", "type": "group", "id": { "entity_id": "group.lights_main_v", "device_id": null } }, { "name": "D1Mini Bed LEDs Strip Dima", "room": null, "type": "light", "id": { "entity_id": "light.d1mini_bed_leds_strip_dima", "device_id": null } }, { "name": "D1Mini Bed LEDs Strip Sandra", "room": null, "type": "light", "id": { "entity_id": "light.d1mini_bed_leds_strip_sandra", "device_id": null } } ] }, { "id": "vova_led_strip_bed_control_on", "automation": "- alias: vova_led_strip_bed_control_on\n id: vova_led_strip_bed_control_on\n mode: parallel\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d00053faae1_motion\n id: on_dima\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d00044c7971_motion\n id: on_sandra\n conditions:\n - condition: state\n entity_id: binary_sensor.bed_led_enable\n state: 'on'\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: on_sandra\n - condition: state\n entity_id: light.d1mini_bed_leds_strip_sandra\n state: 'off'\n sequence:\n - action: light.turn_on\n entity_id: light.d1mini_bed_leds_strip_sandra\n data:\n brightness: '{%- if is_state(''binary_sensor.tod_day'',''off'') -%} 50 {%-\n else -%} 100 {% endif %}\n\n '\n rgb_color:\n - 255\n - 255\n - 255\n transition: 2\n - conditions:\n - condition: trigger\n id: on_dima\n - condition: state\n entity_id: light.d1mini_bed_leds_strip_dima\n state: 'off'\n sequence:\n - action: light.turn_on\n entity_id: light.d1mini_bed_leds_strip_dima\n data:\n brightness: '{%- if is_state(''binary_sensor.tod_day'',''off'') -%} 100\n {%- else -%} 153 {% endif %}\n\n '\n rgb_color:\n - 255\n - 255\n - 255\n transition: 2\n - conditions:\n - condition: trigger\n id: on_sandra\n - condition: state\n entity_id: light.d1mini_bed_leds_strip_sandra\n state: 'on'\n sequence:\n - action: timer.cancel\n entity_id: timer.led_strip_bed_sandra_v\n - action: timer.start\n entity_id: timer.led_strip_bed_sandra_v\n - conditions:\n - condition: trigger\n id: on_dima\n - condition: state\n entity_id: light.d1mini_bed_leds_strip_dima\n state: 'on'\n sequence:\n - action: timer.cancel\n entity_id: timer.led_strip_bed_dima_v\n - action: timer.start\n entity_id: timer.led_strip_bed_dima_v", "config": [ { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "Motion Sensor 44c7971", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d00044c7971_motion", "device_id": null } }, { "name": "Motion Sensor 53faae1", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d00053faae1_motion", "device_id": null } }, { "name": "Bed LED Enable", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.bed_led_enable", "device_id": null } }, { "name": "D1Mini Bed LEDs Strip Dima", "room": null, "type": "light", "id": { "entity_id": "light.d1mini_bed_leds_strip_dima", "device_id": null } }, { "name": "D1Mini Bed LEDs Strip Sandra", "room": null, "type": "light", "id": { "entity_id": "light.d1mini_bed_leds_strip_sandra", "device_id": null } }, { "name": "LED Strip Bed Dima V Timer", "room": "Vova Room", "type": "timer", "id": { "entity_id": "timer.led_strip_bed_dima_v", "device_id": null } }, { "name": "LED Strip Bed Sandra V Timer", "room": "Vova Room", "type": "timer", "id": { "entity_id": "timer.led_strip_bed_sandra_v", "device_id": null } } ] }, { "id": "vova_led_strip_bed_timer_control", "automation": "- alias: vova_led_strip_bed_timer_control\n id: vova_led_strip_bed_timer_control\n mode: parallel\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: state\n entity_id: light.d1mini_bed_leds_strip_sandra\n to: null\n id: is_sandra\n - trigger: state\n entity_id: light.d1mini_bed_leds_strip_dima\n to: null\n id: is_dima\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: is_sandra\n sequence:\n - action: timer.{{'start' if is_state('light.d1mini_bed_leds_strip_sandra','on')\n else 'cancel'}}\n entity_id: timer.led_strip_bed_sandra_v\n - conditions:\n - condition: trigger\n id: is_dima\n sequence:\n - action: timer.{{'start' if is_state('light.d1mini_bed_leds_strip_dima','on')\n else 'cancel'}}\n entity_id: timer.led_strip_bed_dima_v", "config": [ { "name": "D1Mini Bed LEDs Strip Dima", "room": null, "type": "light", "id": { "entity_id": "light.d1mini_bed_leds_strip_dima", "device_id": null } }, { "name": "D1Mini Bed LEDs Strip Sandra", "room": null, "type": "light", "id": { "entity_id": "light.d1mini_bed_leds_strip_sandra", "device_id": null } }, { "name": "LED Strip Bed Dima V Timer", "room": "Vova Room", "type": "timer", "id": { "entity_id": "timer.led_strip_bed_dima_v", "device_id": null } }, { "name": "LED Strip Bed Sandra V Timer", "room": "Vova Room", "type": "timer", "id": { "entity_id": "timer.led_strip_bed_sandra_v", "device_id": null } } ] }, { "id": "vova_led_strip_bed_control_off", "automation": "- alias: vova_led_strip_bed_control_off\n id: vova_led_strip_bed_control_off\n mode: parallel\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.led_strip_bed_dima_v\n id: off_dima\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.led_strip_bed_sandra_v\n id: off_sandra\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: off_sandra\n sequence:\n - wait_template: '{{states(''light.d1mini_bed_leds_strip_sandra'') in [''on'',''off'']}}'\n - repeat:\n sequence:\n - action: light.turn_off\n entity_id: light.d1mini_bed_leds_strip_sandra\n data:\n transition: 10\n - delay:\n seconds: 1\n until:\n - condition: not\n conditions:\n - condition: state\n entity_id: light.d1mini_bed_leds_strip_sandra\n state: 'on'\n - conditions:\n - condition: trigger\n id: off_dima\n sequence:\n - wait_template: '{{states(''light.d1mini_bed_leds_strip_dima'') in [''on'',''off'']}}'\n - repeat:\n sequence:\n - action: light.turn_off\n entity_id: light.d1mini_bed_leds_strip_dima\n data:\n transition: 10\n - delay:\n seconds: 1\n until:\n - condition: not\n conditions:\n - condition: state\n entity_id: light.d1mini_bed_leds_strip_dima\n state: 'on'", "config": [ { "name": "D1Mini Bed LEDs Strip Dima", "room": null, "type": "light", "id": { "entity_id": "light.d1mini_bed_leds_strip_dima", "device_id": null } }, { "name": "D1Mini Bed LEDs Strip Sandra", "room": null, "type": "light", "id": { "entity_id": "light.d1mini_bed_leds_strip_sandra", "device_id": null } }, { "name": "LED Strip Bed Dima V Timer", "room": "Vova Room", "type": "timer", "id": { "entity_id": "timer.led_strip_bed_dima_v", "device_id": null } }, { "name": "LED Strip Bed Sandra V Timer", "room": "Vova Room", "type": "timer", "id": { "entity_id": "timer.led_strip_bed_sandra_v", "device_id": null } } ] }, { "id": "vova_led_strip_bed_control_unavailable", "automation": "- alias: vova_led_strip_bed_control_unavailable\n id: vova_led_strip_bed_control_unavailable\n mode: parallel\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: state\n entity_id: light.d1mini_bed_leds_strip_dima\n from: unavailable\n to: 'on'\n id: un_dima\n - trigger: state\n entity_id: light.d1mini_bed_leds_strip_sandra\n from: unavailable\n to: 'on'\n id: un_sandra\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: un_sandra\n sequence:\n - not:\n - condition: state\n entity_id: timer.led_strip_bed_sandra_v\n state: active\n - action: timer.cancel\n entity_id: timer.led_strip_bed_sandra_v\n - action: timer.start\n entity_id: timer.led_strip_bed_sandra_v\n - conditions:\n - condition: trigger\n id: un_dima\n sequence:\n - not:\n - condition: state\n entity_id: timer.led_strip_bed_sandra_v\n state: active\n - action: timer.cancel\n entity_id: timer.led_strip_bed_dima_v\n - action: timer.start\n entity_id: timer.led_strip_bed_dima_v", "config": [ { "name": "D1Mini Bed LEDs Strip Dima", "room": null, "type": "light", "id": { "entity_id": "light.d1mini_bed_leds_strip_dima", "device_id": null } }, { "name": "D1Mini Bed LEDs Strip Sandra", "room": null, "type": "light", "id": { "entity_id": "light.d1mini_bed_leds_strip_sandra", "device_id": null } }, { "name": "LED Strip Bed Dima V Timer", "room": "Vova Room", "type": "timer", "id": { "entity_id": "timer.led_strip_bed_dima_v", "device_id": null } }, { "name": "LED Strip Bed Sandra V Timer", "room": "Vova Room", "type": "timer", "id": { "entity_id": "timer.led_strip_bed_sandra_v", "device_id": null } } ] }, { "id": "vova_led_strip_bed_restart", "automation": "- alias: vova_led_strip_bed_restart\n id: vova_led_strip_bed_restart\n initial_state: false\n triggers:\n - trigger: time_pattern\n minutes: /1\n conditions:\n - condition: state\n entity_id: light.d1mini_bed_leds_strip_dima, light.d1mini_bed_leds_strip_sandra\n state: unavailable\n for:\n minutes: 1\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: state\n entity_id: switch.system_led_strip_bed_v_restart_key\n state: 'on'\n actions:\n - repeat:\n while:\n - condition: state\n entity_id: light.d1mini_bed_leds_strip_dima\n state: unavailable\n - condition: template\n value_template: '{{ repeat.index <= 5 }}'\n sequence:\n - action: switch.turn_off\n entity_id: switch.0x00158d0001a248e3_channel_1\n - delay:\n seconds: 15\n - action: switch.turn_on\n entity_id: switch.0x00158d0001a248e3_channel_1\n - action: notify.telegram\n data:\n message: 🚨 LED Strip Bed V restart done({{repeat.index}})!\n - delay:\n seconds: 30\n - condition: state\n entity_id: light.d1mini_bed_leds_strip_dima\n state: unavailable\n - action: notify.telegram\n data:\n message: 🚨 Led Strip Bed V restart unsuccessful!\n - action: switch.turn_off\n entity_id: switch.system_led_strip_bed_v_restart_key", "config": [ { "name": "D1Mini Bed LEDs Strip Dima", "room": null, "type": "light", "id": { "entity_id": "light.d1mini_bed_leds_strip_dima", "device_id": null } }, { "name": "D1Mini Bed LEDs Strip Sandra", "room": null, "type": "light", "id": { "entity_id": "light.d1mini_bed_leds_strip_sandra", "device_id": null } }, { "name": "Switch Channel 1 1a248e3", "room": null, "type": "switch", "id": { "entity_id": "switch.0x00158d0001a248e3_channel_1", "device_id": null } }, { "name": "System LED Strip Bed V Restart Key", "room": null, "type": "switch", "id": { "entity_id": "switch.system_led_strip_bed_v_restart_key", "device_id": null } } ] }, { "id": "vova_led_strip_bed_restart_key_toggle", "automation": "- alias: vova_led_strip_bed_restart_key_toggle\n id: vova_led_strip_bed_restart_key_toggle\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: light.d1mini_bed_leds_strip_dima\n from: unavailable\n actions:\n - action: switch.turn_on\n entity_id: switch.system_led_strip_bed_v_restart_key", "config": [ { "name": "D1Mini Bed LEDs Strip Dima", "room": null, "type": "light", "id": { "entity_id": "light.d1mini_bed_leds_strip_dima", "device_id": null } }, { "name": "System LED Strip Bed V Restart Key", "room": null, "type": "switch", "id": { "entity_id": "switch.system_led_strip_bed_v_restart_key", "device_id": null } } ] }, { "id": "vova_main_light_off_with_occupancy", "automation": "- alias: vova_main_light_off_with_occupancy\n id: vova_main_light_off_with_occupancy\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.occupancy_v\n to: 'off'\n for:\n hours: 2\n conditions:\n - condition: state\n entity_id: group.lights_v\n state: 'on'\n actions:\n - action: light.turn_off\n entity_id: light.square_led_v, light.square_led_v_nightlight, light.d1mini_bed_leds_strip_dima,\n light.d1mini_bed_leds_strip_sandra, light.0x54ef441000d4e7fd_light\n data:\n transition: 15", "config": [ { "name": "Occupancy V", "room": "Vova Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.occupancy_v", "device_id": null } }, { "name": "Lights V Group", "room": "Vova Room", "type": "group", "id": { "entity_id": "group.lights_v", "device_id": null } }, { "name": "Light 54ef441000d4e7fd", "room": null, "type": "light", "id": { "entity_id": "light.0x54ef441000d4e7fd_light", "device_id": null } }, { "name": "D1Mini Bed LEDs Strip Dima", "room": null, "type": "light", "id": { "entity_id": "light.d1mini_bed_leds_strip_dima", "device_id": null } }, { "name": "D1Mini Bed LEDs Strip Sandra", "room": null, "type": "light", "id": { "entity_id": "light.d1mini_bed_leds_strip_sandra", "device_id": null } }, { "name": "Square LED V", "room": "Vova Room", "type": "light", "id": { "entity_id": "light.square_led_v", "device_id": null } }, { "name": "Square LED V Nightlight", "room": "Vova Room", "type": "light", "id": { "entity_id": "light.square_led_v_nightlight", "device_id": null } } ] }, { "id": "vova_led_color_control", "automation": "- alias: vova_led_color_control\n id: vova_led_color_control\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d00016bdb4a_action\n conditions:\n - condition: template\n value_template: '{{ states(''light.0x54ef441000d4e7fd_light'') in [''on'',''off'']\n }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - choose:\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''single'' }}'\n sequence:\n - action: light.toggle\n entity_id: light.0x54ef441000d4e7fd_light\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''double'' }}'\n sequence:\n - action: light.turn_on\n entity_id: light.0x54ef441000d4e7fd_light\n data:\n brightness: 230\n color_temp_kelvin: 5000\n - conditions:\n - condition: template\n value_template: '{{ trigger.event.data.click_type == ''hold'' }}'\n sequence:\n - action: light.turn_on\n entity_id: light.0x54ef441000d4e7fd_light\n data:\n brightness: 14\n color_temp_kelvin: 3000", "config": [ { "name": "Light 54ef441000d4e7fd", "room": null, "type": "light", "id": { "entity_id": "light.0x54ef441000d4e7fd_light", "device_id": null } }, { "name": "Action Sensor 16bdb4a", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x00158d00016bdb4a_action", "device_id": null } } ] }, { "id": "vova_main_light_control_with_alice", "automation": "- alias: vova_main_light_control_with_alice\n id: vova_main_light_control_with_alice\n initial_state: true\n triggers:\n - trigger: event\n event_type: yandex_intent\n event_data:\n text: Выключи свет в Вовиной комнате\n id: to_off_alice\n - trigger: event\n event_type: yandex_intent\n event_data:\n text: Включи свет в Вовиной комнате\n id: to_on_alice\n conditions:\n - condition: template\n value_template: '{{ states(''light.square_led_v'') in [''on'',''off''] and states(''light.square_led_v_nightlight'')\n in [''on'',''off''] }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: to_off_alice\n sequence:\n - action: light.turn_off\n entity_id: light.square_led_v\n - conditions:\n - condition: trigger\n id: to_on_alice\n sequence:\n - action: light.turn_on\n entity_id: light.square_led_v\n data:\n brightness: 230\n color_temp_kelvin: 5000", "config": [ { "name": "Square LED V", "room": "Vova Room", "type": "light", "id": { "entity_id": "light.square_led_v", "device_id": null } }, { "name": "Square LED V Nightlight", "room": "Vova Room", "type": "light", "id": { "entity_id": "light.square_led_v_nightlight", "device_id": null } } ] }, { "id": "system_printer_toner_level", "automation": "- alias: system_printer_toner_level\n id: system_printer_toner_level\n initial_state: true\n mode: queued\n max: 10\n max_exceeded: silent\n triggers:\n - trigger: numeric_state\n entity_id:\n - sensor.hp_178nw_black\n - sensor.hp_178nw_cyan\n - sensor.hp_178nw_magenta\n - sensor.hp_178nw_yellow\n below: 30\n actions:\n - action: notify.telegram\n data:\n message: 🖨 Внимание! Необходимо заказать картриджи. B {{states('sensor.hp_178nw_black')|int(0)}}%,\n C {{states('sensor.hp_178nw_cyan')|int(0)}}%, M {{states('sensor.hp_178nw_magenta')|int(0)}}%,\n Y {{states('sensor.hp_178nw_yellow')|int(0)}}%", "config": [ { "name": "HP 178nw Black", "room": null, "type": "sensor", "id": { "entity_id": "sensor.hp_178nw_black", "device_id": null } }, { "name": "HP 178nw Cyan", "room": null, "type": "sensor", "id": { "entity_id": "sensor.hp_178nw_cyan", "device_id": null } }, { "name": "HP 178nw Magenta", "room": null, "type": "sensor", "id": { "entity_id": "sensor.hp_178nw_magenta", "device_id": null } }, { "name": "HP 178nw Yellow", "room": null, "type": "sensor", "id": { "entity_id": "sensor.hp_178nw_yellow", "device_id": null } } ] }, { "id": "system_printer_offline", "automation": "- alias: system_printer_offline\n id: system_printer_offline\n initial_state: true\n triggers:\n - trigger: state\n entity_id: sensor.hp_color_laser_mfp_178nw\n to: unavailable\n for:\n minutes: 5\n actions:\n - action: notify.telegram\n data:\n message: ⚠ Принтер не в сети! Проверьте питание!", "config": [ { "name": "HP Color Laser MFP 178nw", "room": null, "type": "sensor", "id": { "entity_id": "sensor.hp_color_laser_mfp_178nw", "device_id": null } } ] }, { "id": "bathroom_miscale_weight_person", "automation": "- alias: bathroom_miscale_weight_person\n id: bathroom_miscale_weight_person\n triggers:\n - trigger: state\n entity_id: binary_sensor.weight_changed\n from: 'off'\n to: 'on'\n actions:\n - variables:\n who_could_weigh: \"{%- macro weight_person() -%} \\n {%- for item in states.person\\\n \\ if\\n (item.state == 'home' and 'input_number.weight_' + item.name | lower\\\n \\ in\\n states.input_number | selectattr('entity_id', 'search', '^input_number.weight_')\\n\\\n \\ | map(attribute='entity_id') | list ) -%} \\n {%- set x = states('input_number.weight_'\\\n \\ + item.name | lower) | float(0) | round(1) -%} \\n {%- set y = (x *\\\n \\ 3 / 100) -%} \\n {%- if (x > 0) and ((x - y) < (states('sensor.8cd0b2a04f02_weight')\\\n \\ | float(0) | round(1)) < (x + y)) -%} \\n {{ item.name | lower }},\\\n \\ \\n {%- endif -%} \\n {%- endfor -%}\\n{%- endmacro -%} {{ weight_person().split(',')\\\n \\ | select(\\\"ne\\\", \\\"\\\") | sort | unique | list }}\"\n - if:\n - condition: template\n value_template: '{{ who_could_weigh | count == 1 }} '\n then:\n - action: input_number.set_value\n data:\n entity_id: '{{ ''input_number.weight_'' + who_could_weigh | first }} '\n value: '{{ states(''sensor.8cd0b2a04f02_weight'') | float(0) | round(1) }}'", "config": [ { "name": "Weight Changed", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.weight_changed", "device_id": null } }, { "name": "Weight", "room": null, "type": "input_number", "id": { "entity_id": "input_number.weight_", "device_id": null } }, { "name": "Weight Sensor 8cd0b2a04f02", "room": null, "type": "sensor", "id": { "entity_id": "sensor.8cd0b2a04f02_weight", "device_id": null } } ] }, { "id": "security_everybody_out_1min", "automation": "- alias: security_everybody_out_1min\n id: security_everybody_out_1min\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.family_home\n to: 'off'\n for:\n minutes: 1\n actions:\n - action: notify.mobile_app_iphone_16_pro_dima\n data:\n message: Включение режима охраны через 1 минуту!\n title: Никого нет дома!\n data:\n actions:\n - action: guestmode\n title: Гостевой режим\n authenticationRequired: false\n activationMode: background\n icon: sfsymbols:person.circle.fill", "config": [ { "name": "Family Home", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.family_home", "device_id": null } } ] }, { "id": "security_everybody_out_reply_from_app", "automation": "- alias: security_everybody_out_reply_from_app\n id: security_everybody_out_reply_from_app\n initial_state: true\n triggers:\n - trigger: event\n event_type: mobile_app_notification_action\n event_data:\n service: guestmode\n actions:\n - action: switch.turn_on\n entity_id: switch.system_guest_mode", "config": [ { "name": "System Guest Mode", "room": null, "type": "switch", "id": { "entity_id": "switch.system_guest_mode", "device_id": null } } ] }, { "id": "security_wrapper", "automation": "- alias: security_wrapper\n id: security_wrapper\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.family_home\n to: 'off'\n for:\n minutes: 2\n id: to_on\n - trigger: state\n entity_id: binary_sensor.family_home\n to: 'on'\n for:\n seconds: 15\n id: to_off\n conditions:\n - condition: state\n entity_id: switch.system_guest_mode\n state: 'off'\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: to_on\n sequence:\n - action: switch.turn_on\n entity_id: switch.system_security_mode\n - conditions:\n - condition: trigger\n id: to_off\n sequence:\n - action: switch.turn_off\n entity_id: switch.system_security_mode, switch.system_guest_mode\n - delay:\n seconds: 3\n - action: notify.telegram\n data:\n message: 👮 Режим охраны {{ iif(is_state('switch.system_security_mode','off'),\n 'выключен!', 'включен!', '')}}", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "Family Home", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.family_home", "device_id": null } }, { "name": "System Guest Mode", "room": null, "type": "switch", "id": { "entity_id": "switch.system_guest_mode", "device_id": null } } ] }, { "id": "security_state_change", "automation": "- alias: security_state_change\n id: security_state_change\n initial_state: true\n triggers:\n - trigger: state\n entity_id: switch.system_security_mode\n to: null\n for:\n seconds: 15\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: switch.system_security_mode\n state: 'on'\n sequence:\n - action: notify.telegram\n data:\n message: 🏢 Никого нет дома, выключаем освещение!\n - action: script.turn_on\n entity_id: script.away_mode_on\n - action: notify.telegram\n data:\n message: 🔔 Освещение выключено!\n - conditions:\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n sequence:\n - action: input_boolean.turn_off\n data:\n entity_id: switch.system_security_mode\n - action: script.turn_on\n entity_id: script.away_mode_off", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "Away Mode Off Script", "room": null, "type": "script", "id": { "entity_id": "script.away_mode_off", "device_id": null } }, { "name": "Away Mode On Script", "room": null, "type": "script", "id": { "entity_id": "script.away_mode_on", "device_id": null } } ] }, { "id": "security_sensors_state_change", "automation": "- alias: security_sensors_state_change\n id: security_sensors_state_change\n initial_state: true\n mode: queued\n max: 25\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id:\n - binary_sensor.0x00158d00027129ae_contact\n - binary_sensor.0x00158d0001ef2ffc_contact\n - binary_sensor.0x00158d0002a14c5e_contact\n - binary_sensor.0x00158d0002529b9c_contact\n - binary_sensor.0x00158d00025315e9_contact\n - binary_sensor.0x00158d0001e5d6be_contact\n - binary_sensor.582d344031f7_contact\n - binary_sensor.0x00158d0002531749_contact\n - binary_sensor.0x00158d00025371f6_contact\n - binary_sensor.0x00158d000200ad58_contact\n - binary_sensor.0x00158d0003fa6cf5_contact\n - binary_sensor.0x00158d00025370d1_contact\n to: null\n - trigger: state\n entity_id:\n - binary_sensor.0x00158d0001ae9f61_motion\n - binary_sensor.0x00158d0001aea602_motion\n - binary_sensor.0x00158d0003f27ce2_motion\n - binary_sensor.0x00158d0001e05856_motion\n - binary_sensor.0x00158d0001e53cda_motion\n - binary_sensor.0x00158d0001e54280_motion\n - binary_sensor.0x00158d000224f89f_motion\n - binary_sensor.0x00158d000236bb94_motion\n - binary_sensor.0x00158d000236bc6d_motion\n - binary_sensor.0x00158d0002b4729d_motion\n - binary_sensor.0x00158d0002b482e9_motion\n - binary_sensor.0x00158d0002b48381_motion\n - binary_sensor.0x00158d0003140824_motion\n - binary_sensor.0x00158d0001d5995e_motion\n - binary_sensor.0x00158d00044c7971_motion\n - binary_sensor.0x00158d00053faae1_motion\n - binary_sensor.g5_flex_entrance_motion\n to: 'on'\n conditions:\n - condition: state\n entity_id: switch.system_security_mode\n state: 'on'\n - condition: state\n entity_id: timer.security_delay\n state: idle\n - condition: numeric_state\n entity_id: sensor.ha_uptime\n above: 0\n actions:\n - action: notify.telegram\n data:\n message: 👮 Сработал датчик {{trigger.to_state.attributes.friendly_name}}!", "config": [ { "name": "contact sensor 1", "room": "master_bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d000200ad58_contact", "device_id": null } }, { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "motion sensor kitchen 1", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b4729d_motion", "device_id": null } }, { "name": "motion sensor kitchen 2", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b48381_motion", "device_id": null } }, { "name": "ha uptime", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.ha_uptime", "device_id": null } }, { "name": "main door contact", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001e5d6be_contact", "device_id": null } }, { "name": "bathroom contact sensor", "room": "bathroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002a14c5e_contact", "device_id": null } }, { "name": "bathroom motion sensor", "room": "bathroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d000236bc6d_motion", "device_id": null } }, { "name": "entrance motion sensor", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001e05856_motion", "device_id": null } }, { "name": "fridge motion sensor", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b482e9_motion", "device_id": null } }, { "name": "g5 flex entrance motion", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.g5_flex_entrance_motion", "device_id": null } }, { "name": "hall small motion sensor 1", "room": "hall_small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001ae9f61_motion", "device_id": null } }, { "name": "wardrobe contact", "room": "hall_small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d00025315e9_contact", "device_id": null } }, { "name": "sasha door contact", "room": "hall_small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001ef2ffc_contact", "device_id": null } }, { "name": "motion sensor master bedroom", "room": "master_bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001e53cda_motion", "device_id": null } }, { "name": "contact sensor sasha", "room": "sasha_room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d00025370d1_contact", "device_id": null } }, { "name": "motion sensor sasha 1", "room": "sasha_room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d000224f89f_motion", "device_id": null } }, { "name": "motion sensor sasha 2", "room": "sasha_room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0003140824_motion", "device_id": null } }, { "name": "Motion Sensor 1aea602", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001aea602_motion", "device_id": null } }, { "name": "Motion Sensor 1d5995e", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001d5995e_motion", "device_id": null } }, { "name": "Motion Sensor 1e54280", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001e54280_motion", "device_id": null } }, { "name": "Motion Sensor 236bb94", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d000236bb94_motion", "device_id": null } }, { "name": "Contact Sensor 2529b9c", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002529b9c_contact", "device_id": null } }, { "name": "Contact Sensor 2531749", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002531749_contact", "device_id": null } }, { "name": "Contact Sensor 25371f6", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d00025371f6_contact", "device_id": null } }, { "name": "Contact Sensor 27129ae", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d00027129ae_contact", "device_id": null } }, { "name": "Motion Sensor 3f27ce2", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0003f27ce2_motion", "device_id": null } }, { "name": "Contact Sensor 3fa6cf5", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0003fa6cf5_contact", "device_id": null } }, { "name": "Motion Sensor 44c7971", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d00044c7971_motion", "device_id": null } }, { "name": "Motion Sensor 53faae1", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d00053faae1_motion", "device_id": null } }, { "name": "Contact Sensor 582d344031f7", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.582d344031f7_contact", "device_id": null } }, { "name": "Security Delay Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.security_delay", "device_id": null } } ] }, { "id": "security_alarm_delay", "automation": "- alias: security_alarm_delay\n id: security_alarm_delay\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.582d344031f7_contact\n from: 'off'\n to: 'on'\n conditions:\n - condition: state\n entity_id: switch.system_security_mode\n state: 'on'\n actions:\n - action: timer.cancel\n entity_id: timer.security_delay\n - action: timer.start\n entity_id: timer.security_delay", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "Contact Sensor 582d344031f7", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.582d344031f7_contact", "device_id": null } }, { "name": "Security Delay Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.security_delay", "device_id": null } } ] }, { "id": "security_main_door_vibration", "automation": "- alias: security_main_door_vibration\n id: security_main_door_vibration\n initial_state: true\n triggers:\n - trigger: state\n entity_id: sensor.0x00158d0002b5fbc1_action\n to: vibration\n conditions:\n - condition: state\n entity_id: switch.system_security_mode\n state: 'on'\n actions:\n - action: notify.telegram\n data:\n message: 🚪 Внимание! Главная дверь - Вибрация!", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "Action Sensor 2b5fbc1", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x00158d0002b5fbc1_action", "device_id": null } } ] }, { "id": "security_sensors_state_change_night", "automation": "- alias: security_sensors_state_change_night\n id: security_sensors_state_change_night\n initial_state: true\n mode: queued\n max: 25\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id:\n - binary_sensor.0x00158d00025371f6_contact\n - binary_sensor.0x00158d000200ad58_contact\n - binary_sensor.0x00158d0003fa6cf5_contact\n - binary_sensor.0x00158d00025370d1_contact\n - binary_sensor.582d344031f7_contact\n - binary_sensor.0x00158d0001e5d6be_contact\n - binary_sensor.0x00158d0002531749_contact\n from: 'off'\n to: 'on'\n conditions:\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'off'\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n actions:\n - action: notify.telegram\n data:\n message: '{{\"\\U0001f46e\"}} {%-if trigger.to_state.attributes.device_class==''window''\n and trigger.to_state.state==''on''%}Открыто окно {{trigger.to_state.attributes.friendly_name}}\n {%-elif trigger.to_state.attributes.device_class==''window'' and trigger.to_state.state==''off''%}Окно\n закрыто {{trigger.to_state.attributes.friendly_name}} {%-elif trigger.to_state.attributes.device_class==''door''\n and trigger.to_state.state==''on''%}Дверь открыта {{trigger.to_state.attributes.friendly_name}}\n {%-elif trigger.to_state.attributes.device_class==''door'' and trigger.to_state.state==''off''%}Дверь\n закрыта {{trigger.to_state.attributes.friendly_name}} {%-else%}NA{%endif%}'", "config": [ { "name": "contact sensor 1", "room": "master_bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d000200ad58_contact", "device_id": null } }, { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "main door contact", "room": "hall_big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001e5d6be_contact", "device_id": null } }, { "name": "contact sensor sasha", "room": "sasha_room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d00025370d1_contact", "device_id": null } }, { "name": "Contact Sensor 2531749", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002531749_contact", "device_id": null } }, { "name": "Contact Sensor 25371f6", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d00025371f6_contact", "device_id": null } }, { "name": "Contact Sensor 3fa6cf5", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0003fa6cf5_contact", "device_id": null } }, { "name": "Contact Sensor 582d344031f7", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.582d344031f7_contact", "device_id": null } } ] }, { "id": "system_error_counter", "automation": "- alias: system_error_counter\n id: system_error_counter\n initial_state: true\n mode: parallel\n max: 25\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: system_log_event\n event_data:\n level: ERROR\n conditions:\n - condition: template\n value_template: '{{ not ''system_error_counter'' in (trigger.event.data.message|string)\n }}'\n - condition: template\n value_template: '{{ not ''a0d7b954_ide'' in (trigger.event.data.message|string)\n }}'\n actions:\n - action: counter.increment\n entity_id: counter.error_counter", "config": [ { "name": "Error Counter", "room": null, "type": "counter", "id": { "entity_id": "counter.error_counter", "device_id": null } } ] }, { "id": "system_warning_counter", "automation": "- alias: system_warning_counter\n id: system_warning_counter\n mode: parallel\n max: 25\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: event\n event_type: system_log_event\n event_data:\n level: WARNING\n conditions:\n - condition: template\n value_template: '{{ not ''system_warning_counter'' in (trigger.event.data.message|string)\n }}'\n - condition: template\n value_template: '{{ not ''a0d7b954_ide'' in (trigger.event.data.message|string)\n }}'\n actions:\n - action: counter.increment\n entity_id: counter.warning_counter", "config": [ { "name": "Warning Counter", "room": null, "type": "counter", "id": { "entity_id": "counter.warning_counter", "device_id": null } } ] }, { "id": "system_triggered_automations_counter", "automation": "- alias: system_triggered_automations_counter\n id: system_triggered_automations_counter\n mode: parallel\n max: 25\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: event\n event_type: automation_triggered\n conditions:\n - condition: template\n value_template: '{{ not ''system_triggered_automations_counter'' in (trigger.event.data.name|string)\n }}'\n - condition: template\n value_template: '{{ not ''system_esphome_ble_advert'' in (trigger.event.data.name|string)\n }}'\n actions:\n - action: counter.increment\n entity_id: counter.triggered_automations", "config": [ { "name": "Triggered Automations", "room": null, "type": "counter", "id": { "entity_id": "counter.triggered_automations", "device_id": null } } ] }, { "id": "system_executed_scripts", "automation": "- alias: system_executed_scripts\n id: system_executed_scripts\n mode: parallel\n max: 25\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: script_started\n actions:\n - action: counter.increment\n entity_id: counter.executed_scripts", "config": [ { "name": "Executed Scripts", "room": null, "type": "counter", "id": { "entity_id": "counter.executed_scripts", "device_id": null } } ] }, { "id": "system_start_message", "automation": "- alias: system_start\n id: system_start_message\n initial_state: true\n triggers:\n - trigger: homeassistant\n event: start\n actions:\n - action: notify.telegram\n data:\n message: 😃 Сервер({{state_attr('update.home_assistant_core_update','installed_version')}})\n запущен за {{states('sensor.start_time')|int(0)}}сек {{states('sensor.errors_during_boot')|int(0)\n | format(morph='ошибка', as_text=false) }}, {{states('sensor.warnings_during_boot')|int(0)|\n format(morph='предупреждение', as_text=false) }}\n - action: script.turn_on\n entity_id: script.system_start\n - action: counter.increment\n entity_id: counter.restart_counter\n - delay:\n seconds: 10\n - action: homeassistant.reload_config_entry\n data:\n entry_id: 88ea33f726cb0d5ca6d8d320267c468c", "config": [ { "name": "Restart Counter", "room": null, "type": "counter", "id": { "entity_id": "counter.restart_counter", "device_id": null } }, { "name": "System Start Script", "room": null, "type": "script", "id": { "entity_id": "script.system_start", "device_id": null } }, { "name": "Errors During Boot", "room": null, "type": "sensor", "id": { "entity_id": "sensor.errors_during_boot", "device_id": null } }, { "name": "Start Time", "room": null, "type": "sensor", "id": { "entity_id": "sensor.start_time", "device_id": null } }, { "name": "Warnings During Boot", "room": null, "type": "sensor", "id": { "entity_id": "sensor.warnings_during_boot", "device_id": null } } ] }, { "id": "system_stop_message", "automation": "- alias: system_stop\n id: system_stop_message\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: homeassistant\n event: shutdown\n actions:\n - action: switch.turn_off\n entity_id: switch.system_main_lead\n - action: notify.telegram\n data:\n message: 😡 Сервер({{state_attr('update.home_assistant_core_update','installed_version')}})\n остановлен после {{states('sensor.ha_uptime_text').replace('d','д').replace('h','ч').replace('m','м')}}\n работы", "config": [ { "name": "ha uptime", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.ha_uptime", "device_id": null } }, { "name": "HA Uptime Text", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ha_uptime_text", "device_id": null } }, { "name": "System Main Lead", "room": null, "type": "switch", "id": { "entity_id": "switch.system_main_lead", "device_id": null } } ] }, { "id": "system_start_stop_flag_set", "automation": "- alias: system_start_stop_flag_set\n id: system_start_stop_flag_set\n initial_state: true\n triggers:\n - trigger: homeassistant\n event: start\n id: homeassistant_start\n - trigger: homeassistant\n event: shutdown\n actions:\n - action: \"{% if trigger.id == 'homeassistant_start' -%}\\n input_boolean.turn_off\\n\\\n {% else -%}\\n input_boolean.turn_on\\n{% endif %}\\n\"\n data:\n entity_id: input_boolean.ha_shutdown\n - action: \"{% if trigger.id == 'homeassistant_start' -%}\\n automation.turn_on\\n\\\n {% else -%}\\n automation.turn_off\\n{% endif %}\\n\"\n data:\n entity_id:\n - automation.system_gw3_state\n - automation.system_zb_devices_status\n - automation.system_esp_devices_status\n - automation.system_xiaomi_gw3_error", "config": [ { "name": "input boolean ha shutdown", "room": "system", "type": "input_boolean", "id": { "entity_id": "input_boolean.ha_shutdown", "device_id": null } }, { "name": "System ESP Devices Status Automation", "room": null, "type": "automation", "id": { "entity_id": "automation.system_esp_devices_status", "device_id": null } }, { "name": "System GW3 State Automation", "room": null, "type": "automation", "id": { "entity_id": "automation.system_gw3_state", "device_id": null } }, { "name": "System Xiaomi GW3 Error Automation", "room": null, "type": "automation", "id": { "entity_id": "automation.system_xiaomi_gw3_error", "device_id": null } }, { "name": "System ZB Devices Status Automation", "room": null, "type": "automation", "id": { "entity_id": "automation.system_zb_devices_status", "device_id": null } } ] }, { "id": "system_github_star", "automation": "- alias: system_github_star\n id: system_github_star\n initial_state: true\n triggers:\n - trigger: state\n entity_id: sensor.to4ko_myconfig_stars\n to: null\n conditions:\n - condition: template\n value_template: \"{% set ignore = ['unknown', 'unavailable', 'none','0'] %} {{\\\n \\ trigger.from_state.state not in ignore and\\n trigger.to_state.state not in\\\n \\ ignore and\\n trigger.to_state.state = trigger.from_state.state }}\\n\"\n actions:\n - action: notify.telegram\n data:\n message: '⭐ GitHub Star -> {{ trigger.to_state.state }} '", "config": [ { "name": "To4ko Myconfig Stars", "room": null, "type": "sensor", "id": { "entity_id": "sensor.to4ko_myconfig_stars", "device_id": null } } ] }, { "id": "system_new_device_tracker_found", "automation": "- alias: system_new_device_tracker_found\n id: system_new_device_tracker_found\n initial_state: true\n mode: queued\n max: 10\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: device_tracker_new_device\n actions:\n - action: notify.telegram\n data:\n message: '✴ Новое устройство: {{ trigger.event.data.host_name if trigger.event.data.host_name\n is defined else ''NA'' }} - ({{ trigger.event.data.entity_id if trigger.event.data.entity_id\n is defined else ''NA'' }})'", "config": [] }, { "id": "system_entity_change", "automation": "- alias: system_entity_change\n id: system_entity_change\n initial_state: true\n mode: queued\n max: 20\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: entity_registry_updated\n conditions:\n - condition: template\n value_template: '{{ ''mi_11'' not in trigger.event.data.entity_id }}'\n - condition: template\n value_template: '{{ ''pova_5'' not in trigger.event.data.entity_id }}'\n - condition: template\n value_template: '{{ ''lower'' not in trigger.event.data.action }}'\n - condition: template\n value_template: '{{ ''update'' not in trigger.event.data.action }}'\n actions:\n - action: telegram_bot.send_message\n data:\n message: '❇ Entity - {{ trigger.event.data.action | capitalize }}: {{ trigger.event.data.old_entity_id+''->''\n if trigger.event.data.old_entity_id is defined }}{{ trigger.event.data.entity_id\n if trigger.event.data.entity_id is defined else ''NA'' }}'\n target: secret tel_chat_id\n timeout: 180", "config": [ { "name": "Tel Chat ID Secret", "room": null, "type": "secret", "id": { "entity_id": "secret tel_chat_id", "device_id": null } } ] }, { "id": "system_device_entity_deletion", "automation": "- alias: system_device_entity_deletion\n id: system_device_entity_deletion\n initial_state: true\n mode: queued\n max: 20\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: device_registry_updated\n actions:\n - action: python_script.exec\n data:\n device_id: '{{ trigger.event.data.device_id }}'\n source: \"registry = hass.data['device_registry']\\ndevice = registry.async_get(data['device_id'])\\n\\\n if device and device.name_by_user == 'delete':\\n registry.async_remove_device(data['device_id'])\\n\"", "config": [] }, { "id": "system_new_day_telegram", "automation": "- alias: system_new_day_telegram\n id: system_new_day_telegram\n initial_state: true\n triggers:\n - trigger: time\n at: 00:00:01\n actions:\n - action: notify.telegram\n data:\n message: 🌅 Начался новый день За прошедшие сутки перезагрузок - {{states('counter.restart_counter')|int(0)\n }}, ошибок - {{states('counter.error_counter')|int(0) }}, предупреждений -\n {{states('counter.warning_counter')|int(0)}}, ошибок входа - {{states('counter.badlogin_counter')|int(0)}}, cработало\n автоматизаций - {{states('counter.triggered_automations')|int(0)}}, ошибок\n автоматизаций - {{states('counter.automation_error_counter')|int(0)}}, запущенно\n скриптов - {{states('counter.executed_scripts')|int(0)}}. Входная дверь открывалась\n - {{states('counter.main_door_hb')|int(0)}}раз(а). Чайник включали - {{states('counter.kettle_k')|int(0)}}раз(а)\n - action: counter.reset\n entity_id:\n - counter.warning_counter\n - counter.error_counter\n - counter.restart_counter\n - counter.badlogin_counter\n - counter.main_door_hb\n - counter.automation_error_counter\n - counter.kettle_k\n - counter.triggered_automations\n - counter.executed_scripts\n - counter.toilet_tank\n - action: switch.turn_off\n entity_id: switch.system_dark_mode\n - action: tts.clear_cache\n - action: input_select.select_next\n entity_id: input_select.dishwasher\n - action: automation.turn_on\n entity_id: automation.vova_tv_control", "config": [ { "name": "system dark mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_dark_mode", "device_id": null } }, { "name": "kettle counter", "room": "kitchen", "type": "counter", "id": { "entity_id": "counter.kettle_k", "device_id": null } }, { "name": "dishwasher", "room": "kitchen", "type": "input_select", "id": { "entity_id": "input_select.dishwasher", "device_id": null } }, { "name": "counter main door hb", "room": "hall_big", "type": "counter", "id": { "entity_id": "counter.main_door_hb", "device_id": null } }, { "name": "Vova TV Control Automation", "room": null, "type": "automation", "id": { "entity_id": "automation.vova_tv_control", "device_id": null } }, { "name": "Automation Error Counter", "room": null, "type": "counter", "id": { "entity_id": "counter.automation_error_counter", "device_id": null } }, { "name": "Badlogin Counter", "room": null, "type": "counter", "id": { "entity_id": "counter.badlogin_counter", "device_id": null } }, { "name": "Error Counter", "room": null, "type": "counter", "id": { "entity_id": "counter.error_counter", "device_id": null } }, { "name": "Executed Scripts", "room": null, "type": "counter", "id": { "entity_id": "counter.executed_scripts", "device_id": null } }, { "name": "Restart Counter", "room": null, "type": "counter", "id": { "entity_id": "counter.restart_counter", "device_id": null } }, { "name": "Toilet Tank", "room": null, "type": "counter", "id": { "entity_id": "counter.toilet_tank", "device_id": null } }, { "name": "Triggered Automations", "room": null, "type": "counter", "id": { "entity_id": "counter.triggered_automations", "device_id": null } }, { "name": "Warning Counter", "room": null, "type": "counter", "id": { "entity_id": "counter.warning_counter", "device_id": null } } ] }, { "id": "system_weather_to_telegram", "automation": "- alias: system_weather_to_telegram\n id: system_weather_to_telegram\n initial_state: true\n triggers:\n - trigger: time\n at: 07:00:00\n - trigger: time\n at: '21:00:00'\n actions:\n - action: script.turn_on\n entity_id: script.briefing_telegram", "config": [ { "name": "Briefing Telegram Script", "room": null, "type": "script", "id": { "entity_id": "script.briefing_telegram", "device_id": null } } ] }, { "id": "system_login_failure", "automation": "- alias: system_login_failure\n id: system_login_failure\n initial_state: true\n triggers:\n - trigger: persistent_notification\n update_type:\n - added\n - updated\n notification_id: http-login\n id: http-login\n - trigger: persistent_notification\n update_type:\n - added\n - updated\n notification_id: ip-ban\n id: ip-ban\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: counter.increment\n entity_id: counter.badlogin_counter\n - parallel:\n - action: telegram_bot.send_message\n data:\n target: secret tel_chat_id\n title: \"{%- if trigger.id == 'http-login' %}\\n {{- '\\\\U0001F6AB' -}}\\n\\\n {% else %}\\n {{- '\\\\U000026D4' -}}\\n{% endif %}\"\n message: \"{% set ipadress = trigger.notification.message | replace('\\\\n',\\\n \\ ' ') | regex_replace('.*\\\\((?=\\\\d+\\\\.\\\\d+\\\\.\\\\d+\\\\.\\\\d+)') | regex_replace('\\\\\\\n ).*')\\n | replace('Too many login attempts from ', '') %}\\n\\n{% if trigger.id\\\n \\ == 'http-login' -%}\\n Неудачная попытка входа в систему с адреса {{\\\n \\ ipadress }}\\n{%- else -%}\\n Заблокирован IP адрес {{ ipadress }} после\\\n \\ 5 попыток входа\\n{%- endif %}\\n\"\n disable_web_page_preview: true\n - action: persistent_notification.dismiss\n data:\n notification_id: '{{ trigger.id }}'", "config": [ { "name": "Badlogin Counter", "room": null, "type": "counter", "id": { "entity_id": "counter.badlogin_counter", "device_id": null } }, { "name": "Tel Chat ID Secret", "room": null, "type": "secret", "id": { "entity_id": "secret tel_chat_id", "device_id": null } } ] }, { "id": "system_blocked_ip", "automation": "- alias: system_blocked_ip\n id: system_blocked_ip\n initial_state: true\n triggers:\n - trigger: state\n entity_id: persistent_notification.ip_ban\n to: null\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: notify.telegram\n data:\n message: '{% set ipadress = trigger.to_state.attributes.message.split(''from\n '')[1] | regex_replace(''\\s+.*'') %} {{\"\\U000026d4\"}} Заблокирован IP: {{\n ipadress }}\n\n '\n - action: persistent_notification.dismiss\n data:\n notification_id: ip_ban", "config": [ { "name": "IP Ban Notification", "room": null, "type": "persistent_notification", "id": { "entity_id": "persistent_notification.ip_ban", "device_id": null } } ] }, { "id": "system_groups_rebuild", "automation": "- alias: system_groups_rebuild\n id: system_groups_rebuild\n initial_state: true\n mode: queued\n max: 10\n max_exceeded: silent\n triggers:\n - trigger: time_pattern\n hours: /1\n - trigger: homeassistant\n event: start\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: group.set\n data:\n object_id: updates_monitor\n entities: '{%-for state in states.update | selectattr(''attributes.device_class'',\n ''defined'') | selectattr(''attributes.device_class'', ''eq'',''firmware'')\n %} {{ state.entity_id}}{%- if not loop.last -%}, {%- endif -%} {%-endfor%}'\n - action: group.set\n data:\n object_id: gw3_zigbee_entities\n entities: '{%-for state in states.sensor if state.entity_id.endswith(\"_zigbee\")%}\n {{ state.entity_id}}{%- if not loop.last -%}, {%- endif -%} {%-endfor%}'\n - action: group.set\n data:\n object_id: gw3_ble_entities\n entities: '{%-for state in states.sensor if state.entity_id.endswith(\"_ble\")%}\n {{ state.entity_id}}{%- if not loop.last -%}, {%- endif -%} {%-endfor%}'\n - action: group.set\n data:\n object_id: gw3_mesh_entities\n entities: '{%-for state in states.sensor if state.entity_id.endswith(\"_mesh\")%}\n {{ state.entity_id}}{%- if not loop.last -%}, {%- endif -%} {%-endfor%}'\n - action: group.set\n data:\n object_id: gw3_zigbee_battery_low\n entities: '{%-for state in states.binary_sensor if state.entity_id.endswith(\"_battery_low\")%}\n {{ state.entity_id}}{%- if not loop.last -%}, {%- endif -%} {%-endfor%}'\n - action: group.set\n data:\n object_id: esp_devices_uptime\n entities: '{%-for state in states.sensor if state.entity_id.endswith(\"_uptime_s\")%}\n {{ state.entity_id}}{%- if not loop.last -%}, {%- endif -%} {%-endfor%}'\n - action: group.set\n data:\n object_id: batteries\n entities: '{%-for state in states.sensor if (state.entity_id.endswith(\"_battery\")\n and ''esp32'' not in state.entity_id)%} {{ state.entity_id}}{%- if not loop.last\n -%}, {%- endif -%} {%-endfor%}'\n - action: group.set\n data:\n object_id: lights_all\n entities: '{%- for state in states.group if (\"lights_\" in state.entity_id) %}\n {{- expand(state.entity_id)|map(attribute=''entity_id'')|list|join('','')\n }}{%- if not loop.last -%}, {%- endif -%} {%- endfor %}'", "config": [] }, { "id": "system_battery_level_check", "automation": "- alias: system_battery_level_check\n id: system_battery_level_check\n initial_state: true\n triggers:\n - trigger: time\n at: '20:30:00'\n actions:\n - action: notify.telegram\n data:\n message: \"{%- set datanames = namespace(low_batt=[]) -%} {%- set threshold_zb\\\n \\ = states('input_number.battery_low_level_zb')|int(0) -%} {%- set threshold_bt\\\n \\ = states('input_number.battery_low_level_bt')|int(0) -%} {%- set domains\\\n \\ = ['sensor'] %} {%- for domain in domains -%} {%- for item in states[domain]\\\n \\ if((\\\"_battery\\\" in item.entity_id and ((\\\"0x\\\" in item.entity_id and item.state|int(0)\\\n \\ <= threshold_zb) or (\\\"0x\\\" not in item.entity_id and item.state|int(0)\\\n \\ <= threshold_bt)) and item.entity_id in integration_entities('xiaomi_gateway3')))-%}\\n\\\n \\ {%- set datanames.low_batt = datanames.low_batt + [item.name.replace('\\\n \\ Battery','') +' '+item.state+'%'] -%}\\n{%- endfor %} {%- endfor %} {%- set\\\n \\ num_low_bat = datanames.low_batt | length %} {%- set low_bat = datanames.low_batt\\\n \\ | join(', ') %} {%- if num_low_bat > 0 %} {{\\\"\\\\U0001f6a8\\\"}} Низкий заряд\\\n \\ батарей ({{ num_low_bat}}шт): {{low_bat}} {%- else %} {{\\\"\\\\U0001f50b\\\"\\\n }} Батарей с низким уровнем заряда не найдено {%- endif %}\"", "config": [ { "name": "Battery Low Level BT", "room": null, "type": "input_number", "id": { "entity_id": "input_number.battery_low_level_bt", "device_id": null } }, { "name": "Battery Low Level ZB", "room": null, "type": "input_number", "id": { "entity_id": "input_number.battery_low_level_zb", "device_id": null } } ] }, { "id": "system_database_purge", "automation": "- alias: system_database_purge\n id: system_database_purge\n initial_state: true\n triggers:\n - trigger: time\n at: 02:00:00\n actions:\n - action: recorder.purge\n data:\n keep_days: 15\n repack: true\n - action: notify.telegram\n data:\n message: 💫 Очистка базы", "config": [] }, { "id": "system_transmission_completed_torrent", "automation": "- alias: system_transmission_completed_torrent\n id: system_transmission_completed_torrent\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: transmission_downloaded_torrent\n actions:\n - action: notify.telegram\n data:\n message: 💯 Загрузка завершена {{trigger.event.data.name}}", "config": [] }, { "id": "system_config_error_notification", "automation": "- alias: system_config_error_notification\n id: system_config_error_notification\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id:\n - persistent_notification.homeassistant_check_config\n - persistent_notification.invalid_config\n to: notifying\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: notify.telegram\n data:\n message: ❌ Перезапуск отменён. Конфигурация содержит ошибки {{ trigger.to_state.attributes.message\n }}\n - action: persistent_notification.dismiss\n data:\n notification_id: \"{% if 'could not be set up' in trigger.to_state.attributes.message\\\n \\ | lower %}\\n invalid_config\\n{% else %}\\n homeassistant_check_config\\n\\\n {% endif %}\\n\"", "config": [ { "name": "Home Assistant Check Config Notification", "room": null, "type": "persistent_notification", "id": { "entity_id": "persistent_notification.homeassistant_check_config", "device_id": null } }, { "name": "Invalid Config Notification", "room": null, "type": "persistent_notification", "id": { "entity_id": "persistent_notification.invalid_config", "device_id": null } } ] }, { "id": "system_automation_error", "automation": "- alias: system_automation_error\n id: system_automation_error\n initial_state: true\n mode: queued\n max: 10\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: system_log_event\n event_data:\n level: ERROR\n conditions:\n - condition: template\n value_template: \"{{ \\n trigger.event.data.message | regex_search('Error while\\\n \\ executing automation') or\\n trigger.event.data.message | regex_search('Error\\\n \\ executing script')\\n}}\"\n - condition: template\n value_template: '{{ trigger.event.data.name is not search(this.entity_id, ignorecase=True)\n }}'\n actions:\n - action: notify.telegram\n data:\n message: '{{ ''\\U0000274C'' }} Ошибка выполнения автоматизации: {{ trigger.event.data.message\n | e }}\n\n '\n - action: counter.increment\n data:\n entity_id: counter.automation_error_counter", "config": [ { "name": "Automation Error Counter", "room": null, "type": "counter", "id": { "entity_id": "counter.automation_error_counter", "device_id": null } } ] }, { "id": "system_error_per_hour", "automation": "- alias: system_error_per_hour\n id: system_error_per_hour\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: numeric_state\n entity_id: sensor.error_counter_hourly\n above: 100\n conditions:\n - condition: template\n value_template: '{{(as_timestamp(now())-as_timestamp(state_attr(''automation.system_error_per_hour'',\n ''last_triggered''), 0)|int(0) ,0) > 15 }}'\n - condition: template\n value_template: '{{ (states(''sensor.error_counter_hourly'')|int(0) % 50) == 0\n }}'\n actions:\n - action: notify.telegram\n data:\n message: ⚠ Внимание Количество ошибок в час выросло до {{states('sensor.error_counter_hourly')|int(0)}}", "config": [ { "name": "Error Counter Hourly", "room": null, "type": "sensor", "id": { "entity_id": "sensor.error_counter_hourly", "device_id": null } } ] }, { "id": "system_warning_per_hour", "automation": "- alias: system_warning_per_hour\n id: system_warning_per_hour\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: numeric_state\n entity_id: sensor.warning_counter_hourly\n above: 100\n conditions:\n - condition: template\n value_template: '{{(as_timestamp(now())-as_timestamp(state_attr(''automation.system_warning_per_hour'',\n ''last_triggered''), 0)|int(0) ,0) > 15 }}'\n - condition: template\n value_template: '{{ (states(''sensor.warning_counter_hourly'')|int(0) % 50) ==\n 0 }}'\n actions:\n - action: notify.telegram\n data:\n message: ⚠ Внимание Количество предупреждений в час выросло до {{states('sensor.warning_counter_hourly')|int(0)}}", "config": [ { "name": "Warning Counter Hourly", "room": null, "type": "sensor", "id": { "entity_id": "sensor.warning_counter_hourly", "device_id": null } } ] }, { "id": "system_critical_error_notify", "automation": "- alias: system_critical_error_notify\n id: system_critical_error_notify\n initial_state: true\n mode: queued\n max: 10\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: system_log_event\n event_data:\n level: FATAL\n - trigger: event\n event_type: system_log_event\n event_data:\n level: CRITICAL\n actions:\n - action: notify.telegram\n data:\n message: '🔴 Критическая ошибка системы: {{ trigger.event.data.message | e}}'", "config": [] }, { "id": "system_silent_mode_toggle", "automation": "- alias: system_silent_mode_toggle\n id: system_silent_mode_toggle\n initial_state: true\n mode: queued\n max: 10\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: switch.system_silent_mode\n from: 'on'\n to: 'off'\n - trigger: state\n entity_id: switch.system_silent_mode\n from: 'off'\n to: 'on'\n actions:\n - action: switch.turn_{{states('switch.system_silent_mode')}}\n entity_id: switch.esp32_domofon_mute, switch.sonoff_mini_1_mute\n - action: input_number.set_value\n data:\n entity_id: input_number.main_volume\n value: '{% if is_state(''switch.system_silent_mode'',''on'') %}0{%else%}0.4{%endif%}'\n - action: number.set_value\n data:\n entity_id: number.up_chime_volume\n value: '{% if is_state(''switch.system_silent_mode'',''on'') %}0{%else%}80{%endif%}'\n - action: notify.telegram\n data:\n message: \"{% if is_state('switch.system_silent_mode','on') %}\\n {{'\\\\U0001f515'}}\\\n \\ Режим тишины включен\\n{%else%}\\n {{'\\\\U0001f514'}} Режим тишины выключен\\n\\\n {%endif%}\\n\"", "config": [ { "name": "system silent mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_silent_mode", "device_id": null } }, { "name": "esp32 domofon mute", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.esp32_domofon_mute", "device_id": null } }, { "name": "main volume", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.main_volume", "device_id": null } }, { "name": "Up Chime Volume", "room": null, "type": "number", "id": { "entity_id": "number.up_chime_volume", "device_id": null } } ] }, { "id": "system_gw3_state", "automation": "- alias: system_gw3_state\n id: system_gw3_state\n initial_state: true\n mode: queued\n max: 5\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id:\n - binary_sensor.54ef444329cd_gateway\n - binary_sensor.54ef44437eb6_gateway\n - binary_sensor.54ef44433076_gateway\n - binary_sensor.54ef44439a55_gateway\n - binary_sensor.54ef443f1fac_gateway\n - binary_sensor.54ef44439a55_gateway\n - binary_sensor.54ef4443a353_gateway\n to: 'off'\n - trigger: state\n entity_id:\n - binary_sensor.54ef444329cd_gateway\n - binary_sensor.54ef44437eb6_gateway\n - binary_sensor.54ef44433076_gateway\n - binary_sensor.54ef44439a55_gateway\n - binary_sensor.54ef443f1fac_gateway\n - binary_sensor.54ef44439a55_gateway\n - binary_sensor.54ef4443a353_gateway\n from: 'off'\n conditions:\n - condition: template\n value_template: '{{ trigger.to_state.state = trigger.from_state.state }}'\n - condition: numeric_state\n entity_id: sensor.ha_uptime\n above: 0\n actions:\n - action: notify.telegram\n data:\n message: '⚙ {{trigger.to_state.attributes.friendly_name}}: {% if trigger.from_state.state\n in [''on'',''off'',''unknown'',''unavailable''] %}{{trigger.from_state.state}}{%else%}online{%endif%}\n -> {% if trigger.to_state.state in [''on'',''off'',''unknown'',''unavailable'']\n %}{{trigger.to_state.state}}{%else%}online{%endif%}'", "config": [ { "name": "ha uptime", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.ha_uptime", "device_id": null } }, { "name": "Gateway 54ef443f1fac", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.54ef443f1fac_gateway", "device_id": null } }, { "name": "Gateway 54ef444329cd", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.54ef444329cd_gateway", "device_id": null } }, { "name": "Gateway 54ef44433076", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.54ef44433076_gateway", "device_id": null } }, { "name": "Gateway 54ef44437eb6", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.54ef44437eb6_gateway", "device_id": null } }, { "name": "Gateway 54ef44439a55", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.54ef44439a55_gateway", "device_id": null } }, { "name": "Gateway 54ef4443a353", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.54ef4443a353_gateway", "device_id": null } } ] }, { "id": "system_watchdog", "automation": "- alias: system_watchdog\n id: system_watchdog\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x00158d000323c87c_contact\n to: null\n for:\n seconds: 2\n actions:\n - action: notify.telegram\n data:\n message: '{% if is_state(''binary_sensor.0x00158d000323c87c_contact'',''off'')\n %} {{''\\U0001F7E2''}} Watchdog: API Connected {%else%} {{''\\U0001F534''}}\n Watchdog: API Disconnected {%endif%}\n\n '", "config": [ { "name": "Contact Sensor 323c87c", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d000323c87c_contact", "device_id": null } } ] }, { "id": "system_dark_mode", "automation": "- alias: system_dark_mode\n id: system_dark_mode\n initial_state: true\n triggers:\n - trigger: state\n entity_id: switch.system_dark_mode\n actions:\n - action: notify.telegram\n data:\n message: \"{% if is_state('switch.system_dark_mode','on') %}\\n {{'\\\\U0001f318'}}\\\n \\ Режим темноты включен\\n{%else%}\\n {{'\\\\U00002600'}} Режим темноты выключен\\n\\\n {%endif%}\\n\"\n - condition: state\n entity_id: switch.system_dark_mode\n state: 'off'\n - action: switch.turn_off\n entity_id: switch.system_silent_mode", "config": [ { "name": "system silent mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_silent_mode", "device_id": null } }, { "name": "system dark mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_dark_mode", "device_id": null } } ] }, { "id": "system_hot_water_pipe", "automation": "- alias: system_hot_water_pipe\n id: system_hot_water_pipe\n initial_state: true\n triggers:\n - trigger: numeric_state\n entity_id: sensor.esp32_node_b_hot_pipe\n below: 40\n for:\n minutes: 5\n - trigger: numeric_state\n entity_id: sensor.esp32_node_b_hot_pipe\n above: 40\n for:\n minutes: 5\n conditions:\n - condition: state\n entity_id: input_boolean.hot_water\n state: 'on'\n - condition: not\n conditions:\n - condition: state\n entity_id: sensor.esp32_node_b_hot_pipe\n state: unavailable\n actions:\n - action: notify.telegram\n data:\n message: 🌡 Внимание Горячая вода {% if states('sensor.esp32_node_b_hot_pipe')|float(0)\n > 40 %}включена{%else%}выключена{%endif%}", "config": [ { "name": "Hot Water", "room": null, "type": "input_boolean", "id": { "entity_id": "input_boolean.hot_water", "device_id": null } }, { "name": "ESP32 Node B Hot Pipe", "room": "Bathroom", "type": "sensor", "id": { "entity_id": "sensor.esp32_node_b_hot_pipe", "device_id": null } } ] }, { "id": "system_cold_water_pipe", "automation": "- alias: system_cold_water_pipe\n id: system_cold_water_pipe\n initial_state: false\n triggers:\n - trigger: numeric_state\n entity_id: sensor.esp32_node_b_cold_pipe\n above: sensor.0x00158d0001e58754_temperature\n for:\n minutes: 5\n actions:\n - action: notify.telegram\n data:\n message: 🌡 Внимание Температура трубы холодной воды выше {{states('sensor.esp32_node_b_cold_pipe')|int(0)}}°C", "config": [ { "name": "ESP32 Node B Cold Pipe", "room": "Bathroom", "type": "sensor", "id": { "entity_id": "sensor.esp32_node_b_cold_pipe", "device_id": null } } ] }, { "id": "system_central_heating", "automation": "- alias: system_central_heating\n id: system_central_heating\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.central_heating\n to: 'off'\n for:\n minutes: 30\n - trigger: state\n entity_id: binary_sensor.central_heating\n to: 'on'\n for:\n minutes: 30\n actions:\n - action: input_boolean.turn_{{states('binary_sensor.central_heating')}}\n entity_id: input_boolean.central_heating\n - action: notify.telegram\n data:\n message: 🌡 Внимание Отопление {% if is_state('binary_sensor.central_heating','on')\n %}включено{%else%}выключено{%endif%}", "config": [ { "name": "Central Heating", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.central_heating", "device_id": null } }, { "name": "Central Heating", "room": null, "type": "input_boolean", "id": { "entity_id": "input_boolean.central_heating", "device_id": null } } ] }, { "id": "system_heating_pipes_warning", "automation": "- alias: system_heating_pipes_warning\n id: system_heating_pipes_warning\n initial_state: true\n triggers:\n - trigger: numeric_state\n entity_id:\n - sensor.esp32_node_v_heating_pipe\n - sensor.esp32_node_mb_heating_pipe\n below: 30\n for:\n minutes: 5\n conditions:\n - condition: state\n entity_id: input_boolean.central_heating\n state: 'on'\n actions:\n - action: notify.telegram\n data:\n message: 🌡 Внимание Температура трубы {{trigger.to_state.attributes.friendly_name}}\n ниже 30°C", "config": [ { "name": "Central Heating", "room": null, "type": "input_boolean", "id": { "entity_id": "input_boolean.central_heating", "device_id": null } }, { "name": "ESP32 Node MB Heating Pipe", "room": "Master Bedroom", "type": "sensor", "id": { "entity_id": "sensor.esp32_node_mb_heating_pipe", "device_id": null } }, { "name": "ESP32 Node V Heating Pipe", "room": "Vova Room", "type": "sensor", "id": { "entity_id": "sensor.esp32_node_v_heating_pipe", "device_id": null } } ] }, { "id": "system_zb_devices_status", "automation": "- alias: system_zb_devices_status\n id: system_zb_devices_status\n initial_state: true\n mode: queued\n max: 100\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: state_changed\n conditions:\n - condition: state\n entity_id: input_boolean.ha_shutdown\n state: 'off'\n - condition: numeric_state\n entity_id: sensor.ha_uptime\n above: 0\n - condition: template\n value_template: '{{ trigger.event.data.entity_id in expand(''group.zigbee_devices'')\n | map(attribute=''entity_id'') | list }}'\n - condition: template\n value_template: '{{ trigger.event.data.new_state.state = trigger.event.data.old_state.state\n }}'\n - condition: template\n value_template: '{{ trigger.event.data.new_state.state in [''unavailable''] or\n trigger.event.data.old_state.state in [''unavailable''] }}'\n actions:\n - if:\n - condition: template\n value_template: '{{ states(''input_boolean.ha_shutdown'') == ''off'' }}'\n then:\n - action: notify.telegram\n data:\n message: '{% if trigger.event.data.new_state.state in [''unavailable''] %}{{''\\U0001F4A5''}}\n {% elif trigger.event.data.old_state.state in [''unavailable''] %}{{''\\U00002705''}}\n {% else %}{{''\\U00002049''}} {% endif %} ZB: {{iif(device_attr(trigger.event.data.entity_id,\n ''name_by_user'') = none, device_attr(trigger.event.data.entity_id, ''name_by_user''),\n device_attr(trigger.event.data.entity_id, ''name''), device_attr(trigger.event.data.entity_id,\n ''name''))}}: {{trigger.event.data.old_state.state}} -> {{trigger.event.data.new_state.state}}\n\n '", "config": [ { "name": "input boolean ha shutdown", "room": "system", "type": "input_boolean", "id": { "entity_id": "input_boolean.ha_shutdown", "device_id": null } }, { "name": "ha uptime", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.ha_uptime", "device_id": null } } ] }, { "id": "system_zb_devices_status_normal", "automation": "- alias: system_zb_devices_status_normal\n id: system_zb_devices_status_normal\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: numeric_state\n entity_id: sensor.zigbee_devices_unavailable\n below: 1\n for:\n seconds: 5\n actions:\n - action: notify.telegram\n data:\n message: '✅ ZB: Все устройства онлайн'", "config": [ { "name": "Zigbee Devices Unavailable", "room": null, "type": "sensor", "id": { "entity_id": "sensor.zigbee_devices_unavailable", "device_id": null } } ] }, { "id": "system_esp_devices_status", "automation": "- alias: system_esp_devices_status\n id: system_esp_devices_status\n initial_state: true\n mode: queued\n max: 15\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id:\n - binary_sensor.esp32_strip_1s_bookshelf_mb_status\n - binary_sensor.digma_ir_k_status\n - binary_sensor.digma_ir_mb_status\n - binary_sensor.d1mini_light_l_status\n - binary_sensor.digma_strip_hb_status\n - binary_sensor.digma_ir_s_status\n - binary_sensor.digma_ir_v_status\n - binary_sensor.esp32_node_v_status\n - binary_sensor.esp32_node_k_status\n - binary_sensor.esp32_node_hs_status\n - binary_sensor.esp32_node_mb_status\n - binary_sensor.esp8266_oven_temp_k_status\n - binary_sensor.esp32_pzem_hb_status\n - binary_sensor.esp8266_hood_k_status\n - binary_sensor.esp32_strip_1s_wadrobe_mb_status\n - binary_sensor.sonoff_mini_1_status\n - binary_sensor.sonoff_mini_r4_kiosk_charger_status\n - binary_sensor.mono_strip_1_status\n - binary_sensor.sonoff_mini_4_status\n - binary_sensor.sonoff_pow_r2_1_status\n - binary_sensor.esp32_node_b_status\n - binary_sensor.esp32_node_b_valve_status\n - binary_sensor.sonoff_pow_r2_2_status\n - binary_sensor.esp32_node_s_status\n - binary_sensor.esp32_node_s_ha_connect_status\n - binary_sensor.esp32_domofon_status\n - binary_sensor.esp32_poe_ble_s_status\n - binary_sensor.d1mini_distance_sensor_status\n - binary_sensor.esp32_poe_ble_hs_status\n - binary_sensor.esp32_poe_ble_mb_status\n - binary_sensor.sonoff_pow_r2_3_status\n - binary_sensor.d1mini_bed_leds_status\n - binary_sensor.d1mini_air_freshener_status\n - binary_sensor.sp111_socket_1_status\n - binary_sensor.sonoff_basic_4_status\n - binary_sensor.esp32_strip_1s_entrance_hb_status\n - binary_sensor.esp32_strip_1s_wadrobe_hb_status\n from: 'on'\n to: 'off'\n for:\n minutes: 2\n actions:\n - action: notify.telegram\n data:\n message: '🔴 ESP: {{iif(device_attr(trigger.entity_id, ''name_by_user'') = none,\n device_attr(trigger.entity_id, ''name_by_user''), device_attr(trigger.entity_id,\n ''name''), device_attr(trigger.entity_id, ''name''))}}: {{trigger.from_state.state}}\n -> {{trigger.to_state.state}}'", "config": [ { "name": "D1Mini Air Freshener Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.d1mini_air_freshener_status", "device_id": null } }, { "name": "D1Mini Bed LEDs Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.d1mini_bed_leds_status", "device_id": null } }, { "name": "D1Mini Distance Sensor Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.d1mini_distance_sensor_status", "device_id": null } }, { "name": "D1Mini Light L Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.d1mini_light_l_status", "device_id": null } }, { "name": "Digma IR K Status", "room": "Kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.digma_ir_k_status", "device_id": null } }, { "name": "Digma IR MB Status", "room": "Master Bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.digma_ir_mb_status", "device_id": null } }, { "name": "Digma IR S Status", "room": "Sasha Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.digma_ir_s_status", "device_id": null } }, { "name": "Digma IR V Status", "room": "Vova Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.digma_ir_v_status", "device_id": null } }, { "name": "Digma Strip HB Status", "room": "Hall Big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.digma_strip_hb_status", "device_id": null } }, { "name": "ESP32 Domofon Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_domofon_status", "device_id": null } }, { "name": "ESP32 Node B Status", "room": "Bathroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_node_b_status", "device_id": null } }, { "name": "ESP32 Node B Valve Status", "room": "Bathroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_node_b_valve_status", "device_id": null } }, { "name": "ESP32 Node HS Status", "room": "Hall Small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_node_hs_status", "device_id": null } }, { "name": "ESP32 Node K Status", "room": "Kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_node_k_status", "device_id": null } }, { "name": "ESP32 Node MB Status", "room": "Master Bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_node_mb_status", "device_id": null } }, { "name": "ESP32 Node S HA Connect Status", "room": "Sasha Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_node_s_ha_connect_status", "device_id": null } }, { "name": "ESP32 Node S Status", "room": "Sasha Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_node_s_status", "device_id": null } }, { "name": "ESP32 Node V Status", "room": "Vova Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_node_v_status", "device_id": null } }, { "name": "ESP32 Poe BLE HS Status", "room": "Hall Small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_poe_ble_hs_status", "device_id": null } }, { "name": "ESP32 Poe BLE MB Status", "room": "Master Bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_poe_ble_mb_status", "device_id": null } }, { "name": "ESP32 Poe BLE S Status", "room": "Sasha Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_poe_ble_s_status", "device_id": null } }, { "name": "ESP32 PZEM HB Status", "room": "Hall Big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_pzem_hb_status", "device_id": null } }, { "name": "ESP32 Strip 1s Bookshelf MB Status", "room": "Master Bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_strip_1s_bookshelf_mb_status", "device_id": null } }, { "name": "ESP32 Strip 1s Entrance HB Status", "room": "Hall Big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_strip_1s_entrance_hb_status", "device_id": null } }, { "name": "ESP32 Strip 1s Wadrobe HB Status", "room": "Hall Big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_strip_1s_wadrobe_hb_status", "device_id": null } }, { "name": "ESP32 Strip 1s Wadrobe MB Status", "room": "Master Bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_strip_1s_wadrobe_mb_status", "device_id": null } }, { "name": "ESP8266 Hood K Status", "room": "Kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp8266_hood_k_status", "device_id": null } }, { "name": "ESP8266 Oven Temp K Status", "room": "Kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp8266_oven_temp_k_status", "device_id": null } }, { "name": "Mono Strip 1 Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.mono_strip_1_status", "device_id": null } }, { "name": "Sonoff Basic 4 Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.sonoff_basic_4_status", "device_id": null } }, { "name": "Sonoff Mini 1 Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.sonoff_mini_1_status", "device_id": null } }, { "name": "Sonoff Mini 4 Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.sonoff_mini_4_status", "device_id": null } }, { "name": "Sonoff Mini R4 Kiosk Charger Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.sonoff_mini_r4_kiosk_charger_status", "device_id": null } }, { "name": "Sonoff Pow R2 1 Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.sonoff_pow_r2_1_status", "device_id": null } }, { "name": "Sonoff Pow R2 2 Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.sonoff_pow_r2_2_status", "device_id": null } }, { "name": "Sonoff Pow R2 3 Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.sonoff_pow_r2_3_status", "device_id": null } }, { "name": "SP111 Socket 1 Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.sp111_socket_1_status", "device_id": null } } ] }, { "id": "system_esp_devices_status_to_on", "automation": "- alias: system_esp_devices_status_to_on\n id: system_esp_devices_status_to_on\n initial_state: true\n mode: queued\n max: 15\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id:\n - binary_sensor.esp32_strip_1s_bookshelf_mb_status\n - binary_sensor.digma_ir_k_status\n - binary_sensor.digma_ir_mb_status\n - binary_sensor.d1mini_light_l_status\n - binary_sensor.digma_strip_hb_status\n - binary_sensor.digma_ir_s_status\n - binary_sensor.digma_ir_v_status\n - binary_sensor.esp32_node_v_status\n - binary_sensor.esp32_node_k_status\n - binary_sensor.esp32_node_hs_status\n - binary_sensor.esp32_node_mb_status\n - binary_sensor.esp8266_oven_temp_k_status\n - binary_sensor.esp32_pzem_hb_status\n - binary_sensor.esp8266_hood_k_status\n - binary_sensor.esp32_strip_1s_wadrobe_mb_status\n - binary_sensor.sonoff_mini_1_status\n - binary_sensor.sonoff_mini_r4_kiosk_charger_status\n - binary_sensor.mono_strip_1_status\n - binary_sensor.sonoff_mini_4_status\n - binary_sensor.sonoff_pow_r2_1_status\n - binary_sensor.esp32_node_b_status\n - binary_sensor.esp32_node_b_valve_status\n - binary_sensor.sonoff_pow_r2_2_status\n - binary_sensor.esp32_node_s_status\n - binary_sensor.esp32_node_s_ha_connect_status\n - binary_sensor.esp32_domofon_status\n - binary_sensor.esp32_poe_ble_s_status\n - binary_sensor.d1mini_distance_sensor_status\n - binary_sensor.esp32_poe_ble_hs_status\n - binary_sensor.esp32_poe_ble_mb_status\n - binary_sensor.sonoff_pow_r2_3_status\n - binary_sensor.d1mini_bed_leds_status\n - binary_sensor.d1mini_air_freshener_status\n - binary_sensor.sp111_socket_1_status\n - binary_sensor.sonoff_basic_4_status\n - binary_sensor.esp32_strip_1s_entrance_hb_status\n - binary_sensor.esp32_strip_1s_wadrobe_hb_status\n from: 'off'\n to: 'on'\n for:\n seconds: 5\n conditions:\n - condition: numeric_state\n entity_id: sensor.ha_uptime\n above: 0\n actions:\n - action: notify.telegram\n data:\n message: '🟢 ESP: {{iif(device_attr(trigger.entity_id, ''name_by_user'') = none,\n device_attr(trigger.entity_id, ''name_by_user''), device_attr(trigger.entity_id,\n ''name''), device_attr(trigger.entity_id, ''name''))}}: {{trigger.from_state.state}}\n -> {{trigger.to_state.state}}'", "config": [ { "name": "ha uptime", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.ha_uptime", "device_id": null } }, { "name": "D1Mini Air Freshener Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.d1mini_air_freshener_status", "device_id": null } }, { "name": "D1Mini Bed LEDs Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.d1mini_bed_leds_status", "device_id": null } }, { "name": "D1Mini Distance Sensor Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.d1mini_distance_sensor_status", "device_id": null } }, { "name": "D1Mini Light L Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.d1mini_light_l_status", "device_id": null } }, { "name": "Digma IR K Status", "room": "Kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.digma_ir_k_status", "device_id": null } }, { "name": "Digma IR MB Status", "room": "Master Bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.digma_ir_mb_status", "device_id": null } }, { "name": "Digma IR S Status", "room": "Sasha Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.digma_ir_s_status", "device_id": null } }, { "name": "Digma IR V Status", "room": "Vova Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.digma_ir_v_status", "device_id": null } }, { "name": "Digma Strip HB Status", "room": "Hall Big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.digma_strip_hb_status", "device_id": null } }, { "name": "ESP32 Domofon Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_domofon_status", "device_id": null } }, { "name": "ESP32 Node B Status", "room": "Bathroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_node_b_status", "device_id": null } }, { "name": "ESP32 Node B Valve Status", "room": "Bathroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_node_b_valve_status", "device_id": null } }, { "name": "ESP32 Node HS Status", "room": "Hall Small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_node_hs_status", "device_id": null } }, { "name": "ESP32 Node K Status", "room": "Kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_node_k_status", "device_id": null } }, { "name": "ESP32 Node MB Status", "room": "Master Bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_node_mb_status", "device_id": null } }, { "name": "ESP32 Node S HA Connect Status", "room": "Sasha Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_node_s_ha_connect_status", "device_id": null } }, { "name": "ESP32 Node S Status", "room": "Sasha Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_node_s_status", "device_id": null } }, { "name": "ESP32 Node V Status", "room": "Vova Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_node_v_status", "device_id": null } }, { "name": "ESP32 Poe BLE HS Status", "room": "Hall Small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_poe_ble_hs_status", "device_id": null } }, { "name": "ESP32 Poe BLE MB Status", "room": "Master Bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_poe_ble_mb_status", "device_id": null } }, { "name": "ESP32 Poe BLE S Status", "room": "Sasha Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_poe_ble_s_status", "device_id": null } }, { "name": "ESP32 PZEM HB Status", "room": "Hall Big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_pzem_hb_status", "device_id": null } }, { "name": "ESP32 Strip 1s Bookshelf MB Status", "room": "Master Bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_strip_1s_bookshelf_mb_status", "device_id": null } }, { "name": "ESP32 Strip 1s Entrance HB Status", "room": "Hall Big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_strip_1s_entrance_hb_status", "device_id": null } }, { "name": "ESP32 Strip 1s Wadrobe HB Status", "room": "Hall Big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_strip_1s_wadrobe_hb_status", "device_id": null } }, { "name": "ESP32 Strip 1s Wadrobe MB Status", "room": "Master Bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_strip_1s_wadrobe_mb_status", "device_id": null } }, { "name": "ESP8266 Hood K Status", "room": "Kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp8266_hood_k_status", "device_id": null } }, { "name": "ESP8266 Oven Temp K Status", "room": "Kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp8266_oven_temp_k_status", "device_id": null } }, { "name": "Mono Strip 1 Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.mono_strip_1_status", "device_id": null } }, { "name": "Sonoff Basic 4 Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.sonoff_basic_4_status", "device_id": null } }, { "name": "Sonoff Mini 1 Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.sonoff_mini_1_status", "device_id": null } }, { "name": "Sonoff Mini 4 Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.sonoff_mini_4_status", "device_id": null } }, { "name": "Sonoff Mini R4 Kiosk Charger Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.sonoff_mini_r4_kiosk_charger_status", "device_id": null } }, { "name": "Sonoff Pow R2 1 Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.sonoff_pow_r2_1_status", "device_id": null } }, { "name": "Sonoff Pow R2 2 Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.sonoff_pow_r2_2_status", "device_id": null } }, { "name": "Sonoff Pow R2 3 Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.sonoff_pow_r2_3_status", "device_id": null } }, { "name": "SP111 Socket 1 Status", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.sp111_socket_1_status", "device_id": null } } ] }, { "id": "system_xiaomi_gw3_error", "automation": "- alias: system_xiaomi_gw3_error\n id: system_xiaomi_gw3_error\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: system_log_event\n event_data:\n level: ERROR\n conditions:\n - condition: template\n value_template: '{{ \"xiaomi_gateway3\" in (trigger.event.data.message|string) or\n \"xiaomi_gateway3\" in (trigger.event.data.message|string) }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: notify.telegram\n data:\n message: ⛔ GW3 Ошибка обнаружена в логе", "config": [] }, { "id": "system_fully_kiosk_connection", "automation": "- alias: system_fully_kiosk_connection\n id: system_fully_kiosk_connection\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: switch.kiosk_screen\n to: unavailable\n id: to_unavail\n for:\n minutes: 5\n - trigger: state\n entity_id: switch.kiosk_screen\n from: unavailable\n id: from_unavail\n for:\n minutes: 1\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: template\n value_template: '{{(as_timestamp(now())|int(0) - as_timestamp(state_attr(''automation.system_fully_browser_restart'',\n ''last_triggered''),0)|int(0)) > 5*60 }}'\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: to_unavail\n sequence:\n - action: notify.telegram\n data:\n message: '⛔ Fully: связь потеряна'\n - conditions:\n - condition: trigger\n id: from_unavail\n sequence:\n - action: notify.telegram\n data:\n message: '✅ Fully: связь восстановлена'", "config": [ { "name": "kiosk screen", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.kiosk_screen", "device_id": null } } ] }, { "id": "system_already_running_log", "automation": "- alias: system_already_running_log\n id: system_already_running_log\n initial_state: true\n max: 10\n max_exceeded: silent\n mode: queued\n triggers:\n - trigger: event\n event_type: system_log_event\n event_data:\n level: WARNING\n conditions:\n - condition: template\n value_template: '{{ \"Already running\" in (trigger.event.data.message|string) }}'\n actions:\n - action: notify.telegram\n data:\n message: ⛔ Warning {{ trigger.event.data.message | join | e }}", "config": [] }, { "id": "system_automation_reload", "automation": "- alias: system_automation_reload\n id: system_automation_reload\n initial_state: true\n triggers:\n - trigger: event\n event_type: automation_reloaded\n actions:\n - action: notify.telegram\n data:\n message: 💬 Автоматизации перезагружены", "config": [] }, { "id": "system_scripts_reload", "automation": "- alias: system_scripts_reload\n id: system_scripts_reload\n initial_state: true\n triggers:\n - trigger: event\n event_type: call_service\n event_data:\n domain: script\n service: reload\n actions:\n - action: notify.telegram\n data:\n message: 💬 Скрипты перезагружены", "config": [] }, { "id": "system_devices_stats", "automation": "- alias: system_devices_stats\n id: system_devices_stats\n initial_state: true\n triggers:\n - trigger: time\n at: '23:59:55'\n actions:\n - action: input_number.set_value\n data:\n entity_id: input_number.breather_v_run_time\n value: '{{ (states(''input_number.breather_v_run_time'') | float(0) + states(''sensor.breather_v_run_time_today'')\n | float(0)) | round(2, ''common'') }}'\n - action: input_number.set_value\n data:\n entity_id: input_number.breather_s_run_time\n value: '{{ (states(''input_number.breather_s_run_time'') | float(0) + states(''sensor.breather_s_run_time_today'')\n | float(0)) | round(2, ''common'') }}'\n - action: input_number.set_value\n data:\n entity_id: input_number.breather_mb_run_time\n value: '{{ (states(''input_number.breather_mb_run_time'') | float(0) + states(''sensor.breather_mb_run_time_today'')\n | float(0)) | round(2, ''common'') }}'", "config": [ { "name": "Breather MB Run Time", "room": "Master Bedroom", "type": "input_number", "id": { "entity_id": "input_number.breather_mb_run_time", "device_id": null } }, { "name": "Breather S Run Time", "room": "Sasha Room", "type": "input_number", "id": { "entity_id": "input_number.breather_s_run_time", "device_id": null } }, { "name": "Breather V Run Time", "room": "Vova Room", "type": "input_number", "id": { "entity_id": "input_number.breather_v_run_time", "device_id": null } }, { "name": "Breather MB Run Time Today", "room": "Master Bedroom", "type": "sensor", "id": { "entity_id": "sensor.breather_mb_run_time_today", "device_id": null } }, { "name": "Breather S Run Time Today", "room": "Sasha Room", "type": "sensor", "id": { "entity_id": "sensor.breather_s_run_time_today", "device_id": null } }, { "name": "Breather V Run Time Today", "room": "Vova Room", "type": "sensor", "id": { "entity_id": "sensor.breather_v_run_time_today", "device_id": null } } ] }, { "id": "system_ac_power_status", "automation": "- alias: system_ac_power_status\n id: system_ac_power_status\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x00158d0003262acc_contact\n to: 'on'\n from: 'off'\n for:\n seconds: 3\n - trigger: state\n entity_id: binary_sensor.0x00158d0003262acc_contact\n to: 'off'\n from: 'on'\n for:\n seconds: 3\n actions:\n - action: notify.telegram\n data:\n message: '{% if is_state(''binary_sensor.0x00158d0003262acc_contact'',''on'')\n %}{{''\\U00002705''}} Электроснабжение восстановлено {% else %}{{''\\U0000274c''}}\n Внимание Электроснабжение прекращено {%endif%}\n\n '", "config": [ { "name": "Contact Sensor 3262acc", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0003262acc_contact", "device_id": null } } ] }, { "id": "system_esp_reboot", "automation": "- alias: system_esp_reboot\n id: system_esp_reboot\n initial_state: true\n mode: queued\n max: 15\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id:\n - sensor.esp32_strip_1s_bookshelf_mb_uptime_s\n - sensor.digma_ir_k_uptime_s\n - sensor.digma_ir_mb_uptime_s\n - sensor.d1mini_light_l_uptime_s\n - sensor.digma_strip_hb_uptime_s\n - sensor.digma_ir_s_uptime_s\n - sensor.digma_ir_v_uptime_s\n - sensor.esp32_node_v_uptime_s\n - sensor.esp32_node_k_uptime_s\n - sensor.esp32_node_hs_uptime_s\n - sensor.esp32_node_mb_uptime_s\n - sensor.esp8266_oven_temp_k_uptime_s\n - sensor.esp32_pzem_hb_uptime_s\n - sensor.esp8266_hood_k_uptime_s\n - sensor.esp32_strip_1s_wadrobe_mb_uptime_s\n - sensor.sonoff_mini_1_uptime_s\n - sensor.sonoff_mini_r4_kiosk_charger_uptime_s\n - sensor.mono_strip_1_uptime_s\n - sensor.sonoff_mini_4_uptime_s\n - sensor.sonoff_pow_r2_1_uptime_s\n - sensor.esp32_node_b_uptime_s\n - sensor.sonoff_pow_r2_2_uptime_s\n - sensor.esp32_node_s_uptime_s\n - sensor.esp32_domofon_uptime_s\n - sensor.esp32_poe_ble_s_uptime_s\n - sensor.d1mini_distance_sensor_uptime_s\n - sensor.esp32_poe_ble_hs_uptime_s\n - sensor.esp32_poe_ble_mb_uptime_s\n - sensor.sonoff_pow_r2_3_uptime_s\n - sensor.d1mini_bed_leds_uptime_s\n - sensor.d1mini_air_freshener_uptime_s\n - sensor.sp111_socket_1_uptime_s\n - sensor.sonoff_basic_4_uptime_s\n from: unavailable\n for:\n seconds: 10\n conditions:\n - condition: template\n value_template: '{{ 0 <= states(trigger.entity_id)|int(-1) < 30 }}'\n actions:\n - action: notify.telegram\n data:\n message: '♻ ESP: {{iif(device_attr(trigger.entity_id, ''name_by_user'') = none,\n device_attr(trigger.entity_id, ''name_by_user''), device_attr(trigger.entity_id,\n ''name''), device_attr(trigger.entity_id, ''name''))}} перезапустился, аптайм\n {{states(trigger.entity_id)|int(0)}}с'", "config": [ { "name": "D1Mini Air Freshener Uptime", "room": null, "type": "sensor", "id": { "entity_id": "sensor.d1mini_air_freshener_uptime_s", "device_id": null } }, { "name": "D1Mini Bed LEDs Uptime", "room": null, "type": "sensor", "id": { "entity_id": "sensor.d1mini_bed_leds_uptime_s", "device_id": null } }, { "name": "D1Mini Distance Sensor Uptime", "room": null, "type": "sensor", "id": { "entity_id": "sensor.d1mini_distance_sensor_uptime_s", "device_id": null } }, { "name": "D1Mini Light L Uptime", "room": null, "type": "sensor", "id": { "entity_id": "sensor.d1mini_light_l_uptime_s", "device_id": null } }, { "name": "Digma IR K Uptime", "room": "Kitchen", "type": "sensor", "id": { "entity_id": "sensor.digma_ir_k_uptime_s", "device_id": null } }, { "name": "Digma IR MB Uptime", "room": "Master Bedroom", "type": "sensor", "id": { "entity_id": "sensor.digma_ir_mb_uptime_s", "device_id": null } }, { "name": "Digma IR S Uptime", "room": "Sasha Room", "type": "sensor", "id": { "entity_id": "sensor.digma_ir_s_uptime_s", "device_id": null } }, { "name": "Digma IR V Uptime", "room": "Vova Room", "type": "sensor", "id": { "entity_id": "sensor.digma_ir_v_uptime_s", "device_id": null } }, { "name": "Digma Strip HB Uptime", "room": "Hall Big", "type": "sensor", "id": { "entity_id": "sensor.digma_strip_hb_uptime_s", "device_id": null } }, { "name": "ESP32 Domofon Uptime", "room": null, "type": "sensor", "id": { "entity_id": "sensor.esp32_domofon_uptime_s", "device_id": null } }, { "name": "ESP32 Node B Uptime", "room": "Bathroom", "type": "sensor", "id": { "entity_id": "sensor.esp32_node_b_uptime_s", "device_id": null } }, { "name": "ESP32 Node HS Uptime", "room": "Hall Small", "type": "sensor", "id": { "entity_id": "sensor.esp32_node_hs_uptime_s", "device_id": null } }, { "name": "ESP32 Node K Uptime", "room": "Kitchen", "type": "sensor", "id": { "entity_id": "sensor.esp32_node_k_uptime_s", "device_id": null } }, { "name": "ESP32 Node MB Uptime", "room": "Master Bedroom", "type": "sensor", "id": { "entity_id": "sensor.esp32_node_mb_uptime_s", "device_id": null } }, { "name": "ESP32 Node S Uptime", "room": "Sasha Room", "type": "sensor", "id": { "entity_id": "sensor.esp32_node_s_uptime_s", "device_id": null } }, { "name": "ESP32 Node V Uptime", "room": "Vova Room", "type": "sensor", "id": { "entity_id": "sensor.esp32_node_v_uptime_s", "device_id": null } }, { "name": "ESP32 Poe BLE HS Uptime", "room": "Hall Small", "type": "sensor", "id": { "entity_id": "sensor.esp32_poe_ble_hs_uptime_s", "device_id": null } }, { "name": "ESP32 Poe BLE MB Uptime", "room": "Master Bedroom", "type": "sensor", "id": { "entity_id": "sensor.esp32_poe_ble_mb_uptime_s", "device_id": null } }, { "name": "ESP32 Poe BLE S Uptime", "room": "Sasha Room", "type": "sensor", "id": { "entity_id": "sensor.esp32_poe_ble_s_uptime_s", "device_id": null } }, { "name": "ESP32 PZEM HB Uptime", "room": "Hall Big", "type": "sensor", "id": { "entity_id": "sensor.esp32_pzem_hb_uptime_s", "device_id": null } }, { "name": "ESP32 Strip 1s Bookshelf MB Uptime", "room": "Master Bedroom", "type": "sensor", "id": { "entity_id": "sensor.esp32_strip_1s_bookshelf_mb_uptime_s", "device_id": null } }, { "name": "ESP32 Strip 1s Wadrobe MB Uptime", "room": "Master Bedroom", "type": "sensor", "id": { "entity_id": "sensor.esp32_strip_1s_wadrobe_mb_uptime_s", "device_id": null } }, { "name": "ESP8266 Hood K Uptime", "room": "Kitchen", "type": "sensor", "id": { "entity_id": "sensor.esp8266_hood_k_uptime_s", "device_id": null } }, { "name": "ESP8266 Oven Temp K Uptime", "room": "Kitchen", "type": "sensor", "id": { "entity_id": "sensor.esp8266_oven_temp_k_uptime_s", "device_id": null } }, { "name": "Mono Strip 1 Uptime", "room": null, "type": "sensor", "id": { "entity_id": "sensor.mono_strip_1_uptime_s", "device_id": null } }, { "name": "Sonoff Basic 4 Uptime", "room": null, "type": "sensor", "id": { "entity_id": "sensor.sonoff_basic_4_uptime_s", "device_id": null } }, { "name": "Sonoff Mini 1 Uptime", "room": null, "type": "sensor", "id": { "entity_id": "sensor.sonoff_mini_1_uptime_s", "device_id": null } }, { "name": "Sonoff Mini 4 Uptime", "room": null, "type": "sensor", "id": { "entity_id": "sensor.sonoff_mini_4_uptime_s", "device_id": null } }, { "name": "Sonoff Mini R4 Kiosk Charger Uptime", "room": null, "type": "sensor", "id": { "entity_id": "sensor.sonoff_mini_r4_kiosk_charger_uptime_s", "device_id": null } }, { "name": "Sonoff Pow R2 1 Uptime", "room": null, "type": "sensor", "id": { "entity_id": "sensor.sonoff_pow_r2_1_uptime_s", "device_id": null } }, { "name": "Sonoff Pow R2 2 Uptime", "room": null, "type": "sensor", "id": { "entity_id": "sensor.sonoff_pow_r2_2_uptime_s", "device_id": null } }, { "name": "Sonoff Pow R2 3 Uptime", "room": null, "type": "sensor", "id": { "entity_id": "sensor.sonoff_pow_r2_3_uptime_s", "device_id": null } }, { "name": "SP111 Socket 1 Uptime", "room": null, "type": "sensor", "id": { "entity_id": "sensor.sp111_socket_1_uptime_s", "device_id": null } } ] }, { "id": "system_briefing_entities_force_update", "automation": "- alias: system_briefing_entities_force_update\n id: system_briefing_entities_force_update\n initial_state: true\n triggers:\n - trigger: time\n at: 06:50:00\n id: id_morning\n - trigger: time\n at: '20:50:00'\n id: id_evening\n actions:\n - action: hassio.addon_restart\n data:\n addon: a0d7b954_appdaemon\n - condition: template\n value_template: \"{%- set sensors = expand('group.weather_fcst_entities') %} {%-\\\n \\ set act_time = as_timestamp(now()) %} {%- for sensor in sensors %}\\n {%-\\\n \\ if as_timestamp(sensor.last_updated) == as_timestamp(sensors | map(attribute='last_updated')\\\n \\ | min ) %}\\n {{ (act_time|int(0)-as_timestamp(sensor.last_updated)|int(0))>30*60\\\n \\ }}\\n {%- endif %}\\n{%- endfor %}\"\n - action: homeassistant.update_entity\n entity_id:\n - sensor.pirateweather_summary_0d\n - sensor.pirateweather_daytime_high_temperature_0d\n - sensor.pirateweather_precip_probability_0d\n - sensor.pirateweather_precip_0d\n - sensor.pirateweather_summary_1d\n - sensor.pirateweather_daytime_high_temperature_1d\n - sensor.pirateweather_precip_probability_1d\n - sensor.pirateweather_precip_1d\n - delay:\n seconds: 5\n - action: input_number.set_value\n data:\n entity_id: input_number.temp_volume\n value: '{% set ent_id = ''media_player.yandex_st'' %} {% set vol =\n state_attr(ent_id,''volume_level'') %} {{ vol }}\n\n '\n - action: input_number.set_value\n data:\n entity_id: input_number.tts_volume\n value: 0\n - action: media_player.volume_set\n data:\n entity_id: media_player.yandex_st\n volume_level: '{{states(\"input_number.tts_volume\")|float(0)}}'\n - action: media_player.volume_set\n data:\n entity_id: media_player.yandex_st\n volume_level: '{{states(\"input_number.tts_volume\")|float(0)}}'\n - action: media_player.volume_set\n data:\n entity_id: media_player.yandex_st\n volume_level: '{{states(\"input_number.tts_volume\")|float(0)}}'\n - repeat:\n while:\n - condition: template\n value_template: '{{ (as_timestamp(now()) - as_timestamp(state_attr(''sensor.yandex_response'',''time_fired''))\n ) > 10 }}'\n - condition: template\n value_template: '{{ repeat.index <= 10 }}'\n sequence:\n - if:\n - condition: trigger\n id: id_morning\n then:\n - action: media_player.play_media\n data:\n entity_id: media_player.yandex_st\n media_content_id: какая сегодня погода\n media_content_type: question:tts_reply\n extra:\n volume_level: 0\n else:\n - action: media_player.play_media\n data:\n entity_id: media_player.yandex_st\n media_content_id: какая завтра погода\n media_content_type: question:tts_reply\n extra:\n volume_level: 0\n - delay:\n seconds: 3\n - delay:\n seconds: 2\n - if:\n - condition: template\n value_template: '{{ (as_timestamp(now()) - as_timestamp(state_attr(''sensor.yandex_response'',''time_fired''))\n + 0 ) > 30 }}'\n then:\n - action: notify.telegram\n data:\n message: 🌤 Ошибка получения погоды. Последний апдейт - {{as_timestamp(state_attr('sensor.yandex_response','time_fired')) |\n timestamp_custom('%d-%m-%Y %H:%M:%S',true,0)}}\n - action: input_boolean.turn_on\n target:\n entity_id: input_boolean.ya_weather_error\n else:\n - action: input_boolean.turn_off\n target:\n entity_id: input_boolean.ya_weather_error\n - wait_template: '{% set ent_id = ''sensor.yandex_st'' + ''_alice_state'' %} {{\n is_state(ent_id,''idle'') }}\n\n '\n timeout:\n minutes: 5\n - action: input_number.set_value\n data:\n entity_id: input_number.tts_volume\n value: '{{states(\"input_number.temp_volume\")|float(0)}}'\n - action: media_player.volume_set\n data:\n entity_id: media_player.yandex_st\n volume_level: '{{states(\"input_number.tts_volume\")|float(0)}}'", "config": [ { "name": "yandex sasha room", "room": "sasha_room", "type": "media_player", "id": { "entity_id": "media_player.yandex_s", "device_id": null } }, { "name": "Ya Weather Error", "room": null, "type": "input_boolean", "id": { "entity_id": "input_boolean.ya_weather_error", "device_id": null } }, { "name": "Temp Volume", "room": null, "type": "input_number", "id": { "entity_id": "input_number.temp_volume", "device_id": null } }, { "name": "TTS Volume", "room": null, "type": "input_number", "id": { "entity_id": "input_number.tts_volume", "device_id": null } }, { "name": "Yandex St", "room": null, "type": "media_player", "id": { "entity_id": "media_player.yandex_st", "device_id": null } }, { "name": "PirateWeather Daytime High Temperature 0d", "room": null, "type": "sensor", "id": { "entity_id": "sensor.pirateweather_daytime_high_temperature_0d", "device_id": null } }, { "name": "PirateWeather Daytime High Temperature 1d", "room": null, "type": "sensor", "id": { "entity_id": "sensor.pirateweather_daytime_high_temperature_1d", "device_id": null } }, { "name": "PirateWeather Precip 0d", "room": null, "type": "sensor", "id": { "entity_id": "sensor.pirateweather_precip_0d", "device_id": null } }, { "name": "PirateWeather Precip 1d", "room": null, "type": "sensor", "id": { "entity_id": "sensor.pirateweather_precip_1d", "device_id": null } }, { "name": "PirateWeather Precip Probability 0d", "room": null, "type": "sensor", "id": { "entity_id": "sensor.pirateweather_precip_probability_0d", "device_id": null } }, { "name": "PirateWeather Precip Probability 1d", "room": null, "type": "sensor", "id": { "entity_id": "sensor.pirateweather_precip_probability_1d", "device_id": null } }, { "name": "PirateWeather Summary 0d", "room": null, "type": "sensor", "id": { "entity_id": "sensor.pirateweather_summary_0d", "device_id": null } }, { "name": "PirateWeather Summary 1d", "room": null, "type": "sensor", "id": { "entity_id": "sensor.pirateweather_summary_1d", "device_id": null } } ] }, { "id": "system_hot_water_boolean_change", "automation": "- alias: system_hot_water_boolean_change\n id: system_hot_water_boolean_change\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.hot_water\n to: null\n - trigger: homeassistant\n event: start\n - trigger: event\n event_type: automation_reloaded\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: template\n value_template: '{{ states(''binary_sensor.hot_water'') in [''on'',''off''] }}'\n actions:\n - action: input_boolean.turn_{{states('binary_sensor.hot_water')}}\n entity_id: input_boolean.hot_water", "config": [ { "name": "Hot Water", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.hot_water", "device_id": null } }, { "name": "Hot Water", "room": null, "type": "input_boolean", "id": { "entity_id": "input_boolean.hot_water", "device_id": null } } ] }, { "id": "system_cold_water_boolean_change", "automation": "- alias: system_cold_water_boolean_change\n id: system_cold_water_boolean_change\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.cold_water\n to: null\n - trigger: homeassistant\n event: start\n - trigger: event\n event_type: automation_reloaded\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: template\n value_template: '{{ states(''binary_sensor.cold_water'') in [''on'',''off''] }}'\n actions:\n - action: input_boolean.turn_{{states('binary_sensor.cold_water')}}\n entity_id: input_boolean.cold_water", "config": [ { "name": "Cold Water", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.cold_water", "device_id": null } }, { "name": "Cold Water", "room": null, "type": "input_boolean", "id": { "entity_id": "input_boolean.cold_water", "device_id": null } } ] }, { "id": "system_central_heating_boolean_change", "automation": "- alias: system_central_heating_boolean_change\n id: system_central_heating_boolean_change\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.central_heating\n to: null\n - trigger: homeassistant\n event: start\n - trigger: event\n event_type: automation_reloaded\n conditions:\n - condition: template\n value_template: '{{ is_state(''binary_sensor.central_heating'',''on'') or is_state(''binary_sensor.central_heating'',''off'')\n }}'\n actions:\n - action: input_boolean.turn_{{states('binary_sensor.central_heating')}}\n entity_id: input_boolean.central_heating", "config": [ { "name": "Central Heating", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.central_heating", "device_id": null } }, { "name": "Central Heating", "room": null, "type": "input_boolean", "id": { "entity_id": "input_boolean.central_heating", "device_id": null } } ] }, { "id": "system_light_dark_mode_on_action", "automation": "- alias: system_light_dark_mode_on_action\n id: system_light_dark_mode_on_action\n initial_state: true\n triggers:\n - trigger: state\n entity_id: switch.system_dark_mode\n from: 'off'\n to: 'on'\n actions:\n - action: light.turn_off\n entity_id:\n - light.esp32_node_k_light\n - light.mono_strip_1_light\n - light.0x54ef441000680083_channel_2\n - light.round_led_st\n - light.esp32_strip_1s_entrance_hb_rgb\n - light.esp32_strip_1s_wadrobe_hb_rgb", "config": [ { "name": "system dark mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_dark_mode", "device_id": null } }, { "name": "esp32 strip 1s entrance hb rgb", "room": "hall_big", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_entrance_hb_rgb", "device_id": null } }, { "name": "esp32 strip 1s wadrobe hb rgb", "room": "hall_big", "type": "light", "id": { "entity_id": "light.esp32_strip_1s_wadrobe_hb_rgb", "device_id": null } }, { "name": "mono strip 1 light", "room": "hall_small", "type": "light", "id": { "entity_id": "light.mono_strip_1_light", "device_id": null } }, { "name": "esp32 node k light", "room": "kitchen", "type": "light", "id": { "entity_id": "light.esp32_node_k_light", "device_id": null } }, { "name": "Light Channel 2 680083", "room": null, "type": "light", "id": { "entity_id": "light.0x54ef441000680083_channel_2", "device_id": null } }, { "name": "Round LED St", "room": null, "type": "light", "id": { "entity_id": "light.round_led_st", "device_id": null } } ] }, { "id": "system_config_entry_discovery", "automation": "- alias: system_config_entry_discovery\n id: system_config_entry_discovery\n mode: single\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: state\n entity_id: persistent_notification.config_entry_discovery\n to: notifying\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: notify.telegram\n data:\n message: 📟 Найдено новое устройство", "config": [ { "name": "Config Entry Discovery Notification", "room": null, "type": "persistent_notification", "id": { "entity_id": "persistent_notification.config_entry_discovery", "device_id": null } } ] }, { "id": "system_gw3_devices_msg_missed", "automation": "- alias: system_gw3_devices_msg_missed\n id: system_gw3_devices_msg_missed\n initial_state: false\n mode: queued\n max: 70\n triggers:\n - trigger: event\n event_type: state_changed\n conditions:\n - condition: numeric_state\n entity_id: sensor.ha_uptime\n above: 1\n - condition: state\n entity_id: input_boolean.ha_shutdown\n state: 'off'\n - condition: template\n value_template: '{{ trigger.event.data.entity_id in expand(''group.gw3_zigbee_entities'')\n | map(attribute=''entity_id'') | list }}'\n - condition: template\n value_template: '{{ state_attr(trigger.event.data.entity_id, ''last_missed'')\n |int(0) > 9 }}'\n actions:\n - action: notify.telegram\n data:\n message: ⏭ Внимание {{iif(device_attr(trigger.event.data.entity_id, 'name_by_user')\n = none, device_attr(trigger.event.data.entity_id, 'name_by_user'), device_attr(trigger.event.data.entity_id,\n 'name'), device_attr(trigger.event.data.entity_id, 'name'))}} пропустил {{\n state_attr(trigger.event.data.entity_id, 'last_missed') | format(morph='пакет',\n as_text=false) }}", "config": [ { "name": "input boolean ha shutdown", "room": "system", "type": "input_boolean", "id": { "entity_id": "input_boolean.ha_shutdown", "device_id": null } }, { "name": "ha uptime", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.ha_uptime", "device_id": null } } ] }, { "id": "system_esphome_ble_advert", "automation": "- alias: system_esphome_ble_advert\n id: system_esphome_ble_advert\n mode: parallel\n max: 500\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: event\n event_type: esphome.on_ble_advertise\n actions:\n - action: ble_monitor.parse_data\n data:\n packet: '{{ trigger.event.data.packet }}'\n gateway_id: '{{ trigger.event.data.gateway_id }}'", "config": [] }, { "id": "system_music_restrictions", "automation": "- alias: system_music_restrictions\n id: system_music_restrictions\n mode: single\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: state\n entity_id: media_player.yandex_s\n to: playing\n id: by_state\n - trigger: time\n at: '23:00:00'\n id: by_time\n conditions:\n - condition: state\n entity_id: switch.system_music_allowed\n state: 'off'\n - condition: template\n value_template: '{{states(''sensor.time'').split('':'')[0]|int >= 23 or states(''sensor.time'').split('':'')[0]|int\n < 7}}'\n actions:\n - if:\n - condition: trigger\n id: by_time\n then:\n - action: media_player.turn_off\n entity_id: media_player.yandex_s\n - action: media_player.turn_off\n entity_id: media_player.yandex_v\n - delay:\n seconds: 3\n - action: media_player.turn_off\n entity_id: media_player.yandex_s\n - action: media_player.turn_off\n entity_id: media_player.yandex_v\n - if:\n - condition: trigger\n id: on_state\n then:\n - action: media_player.turn_off\n entity_id: media_player.yandex_s\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id: media_player.yandex_s\n media_content_id: Сашенька, ночью надо спать, а не сказки слушать Спокойной\n ночи\n extra:\n volume_level: '0.2'", "config": [ { "name": "yandex vova room", "room": "vova_room", "type": "media_player", "id": { "entity_id": "media_player.yandex_v", "device_id": null } }, { "name": "yandex sasha room", "room": "sasha_room", "type": "media_player", "id": { "entity_id": "media_player.yandex_s", "device_id": null } }, { "name": "time", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.time", "device_id": null } }, { "name": "alice mode", "room": "system", "type": "input_select", "id": { "entity_id": "input_select.alice_mode", "device_id": null } }, { "name": "System Music Allowed", "room": null, "type": "switch", "id": { "entity_id": "switch.system_music_allowed", "device_id": null } } ] }, { "id": "system_supervisor_unhealthyn", "automation": "- alias: system_supervisor_unhealthy\n id: system_supervisor_unhealthyn\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.supervisor_is_healthy\n to: null\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: binary_sensor.supervisor_is_healthy\n state: 'on'\n sequence:\n - action: notify.telegram\n data:\n message: ✅ Supevisor перешел в состояние Healthy\n default:\n - action: notify.telegram\n data:\n message: ❌ Supevisor перешел в состояние Unhealthy", "config": [ { "name": "Supervisor Is Healthy", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.supervisor_is_healthy", "device_id": null } } ] }, { "id": "system_ya_station_mode", "automation": "- alias: system_ya_station_mode\n id: system_ya_station_mode\n mode: queued\n max: 10\n max_exceeded: silent\n initial_state: true\n triggers:\n - trigger: state\n id: non_local\n entity_id:\n - binary_sensor.yandex_k\n - binary_sensor.yandex_s\n - binary_sensor.yandex_hb\n - binary_sensor.yandex_v\n - binary_sensor.yandex_mb\n from: 'off'\n to: 'on'\n - trigger: state\n entity_id:\n - binary_sensor.yandex_k\n - binary_sensor.yandex_s\n - binary_sensor.yandex_hb\n - binary_sensor.yandex_v\n - binary_sensor.yandex_mb\n from: 'on'\n to: 'off'\n actions:\n - action: notify.telegram\n data:\n message: 🔊 Станция {{trigger.to_state.name | e}} {% if trigger.id == 'non_local'\n -%} отключила локальный режим управления {%- else -%} перешла в локальный\n режим управления {%- endif %}", "config": [ { "name": "Yandex HB", "room": "Hall Big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.yandex_hb", "device_id": null } }, { "name": "Yandex K", "room": "Kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.yandex_k", "device_id": null } }, { "name": "Yandex MB", "room": "Master Bedroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.yandex_mb", "device_id": null } }, { "name": "Yandex S", "room": "Sasha Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.yandex_s", "device_id": null } }, { "name": "Yandex V", "room": "Vova Room", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.yandex_v", "device_id": null } } ] }, { "id": "system_fully_integration_reload", "automation": "- alias: system_fully_integration_reload\n id: system_fully_integration_reload\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /10\n conditions:\n - condition: state\n entity_id: sensor.kiosk_battery\n state:\n - unknown\n - unavailable\n for:\n minutes: 5\n actions:\n - action: homeassistant.reload_config_entry\n data:\n entry_id: 2eb872806bf50b75953836ae0584662b", "config": [ { "name": "Kiosk Battery", "room": null, "type": "sensor", "id": { "entity_id": "sensor.kiosk_battery", "device_id": null } } ] }, { "id": "system_fully_tablet_charge_on", "automation": "- alias: system_fully_tablet_charge_on\n id: system_fully_tablet_charge_on\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /15\n conditions:\n - condition: numeric_state\n entity_id: sensor.kiosk_battery\n below: 20\n actions:\n - action: notify.telegram\n data:\n message: '🔌 Fully: Принудительное включение зарядки'\n - action: switch.turn_on\n entity_id: switch.sonoff_mini_r4_kiosk_charger_relay", "config": [ { "name": "Kiosk Battery", "room": null, "type": "sensor", "id": { "entity_id": "sensor.kiosk_battery", "device_id": null } }, { "name": "Sonoff Mini R4 Kiosk Charger Relay", "room": null, "type": "switch", "id": { "entity_id": "switch.sonoff_mini_r4_kiosk_charger_relay", "device_id": null } } ] }, { "id": "system_fully_browser_restart", "automation": "- alias: system_fully_browser_restart\n id: system_fully_browser_restart\n initial_state: true\n triggers:\n - trigger: time_pattern\n hours: /2\n id: auto\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.28d1273bc2f4_action\n click_type: single\n id: manual\n actions:\n - action: button.press\n entity_id: button.kiosk_restart_browser\n - action: timer.start\n entity_id: timer.kiosk_restart_manual", "config": [ { "name": "Kiosk Restart Browser", "room": null, "type": "button", "id": { "entity_id": "button.kiosk_restart_browser", "device_id": null } }, { "name": "Action Sensor 28d1273bc2f4", "room": null, "type": "sensor", "id": { "entity_id": "sensor.28d1273bc2f4_action", "device_id": null } }, { "name": "Kiosk Restart Manual Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.kiosk_restart_manual", "device_id": null } } ] }, { "id": "system_repair_event_notify", "automation": "- alias: system_repair_event_notify\n id: system_repair_event_notify\n initial_state: true\n mode: queued\n max: 50\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: repairs_issue_registry_updated\n event_data:\n service: create\n actions:\n - action: notify.telegram\n data:\n message: '🐛 Проблема в {{ trigger.event.data.domain | e }}, детали: {{\n trigger.event.data.issue_id | e }}'", "config": [] }, { "id": "system_repair_sensor_update", "automation": "- alias: system_repair_sensor_update\n id: system_repair_sensor_update\n mode: restart\n triggers:\n - trigger: event\n event_type: repairs_issue_registry_updated\n event_data:\n service: create\n - trigger: homeassistant\n event: start\n actions:\n - action: homeassistant.update_entity\n data:\n entity_id: sensor.repairs_state", "config": [ { "name": "Repairs State", "room": null, "type": "sensor", "id": { "entity_id": "sensor.repairs_state", "device_id": null } } ] }, { "id": "system_day_night_switch", "automation": "- alias: system_day_night_switch\n id: system_day_night_switch\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.tod_day\n to: 'on'\n conditions:\n - condition: state\n entity_id: switch.system_security_mode\n state: 'off'\n actions:\n - action: switch.turn_off\n entity_id: switch.system_silent_mode", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "system silent mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_silent_mode", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } } ] }, { "id": "system_doorbell_volume", "automation": "- alias: system_doorbell_volume\n id: system_doorbell_volume\n initial_state: true\n triggers:\n - trigger: time_pattern\n hours: /1\n - trigger: homeassistant\n event: start\n actions:\n - action: number.set_value\n data:\n entity_id: number.up_chime_volume\n value: '{{iif(is_state(''switch.system_silent_mode'',''on''),0,80) }}'", "config": [ { "name": "system silent mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_silent_mode", "device_id": null } }, { "name": "Up Chime Volume", "room": null, "type": "number", "id": { "entity_id": "number.up_chime_volume", "device_id": null } } ] }, { "id": "system_ds621_set_fan_speed", "automation": "- alias: system_ds621_set_fan_speed\n id: system_ds621_set_fan_speed\n initial_state: true\n triggers:\n - trigger: state\n entity_id: input_select.ds1621_fan_speed_select\n to: null\n actions:\n - action: mqtt.publish\n data:\n payload: '{{ states(''input_select.ds1621_fan_speed_select'') | lower }}'\n topic: 1621/fan_speed_set\n retain: true", "config": [ { "name": "DS1621 Fan Speed Select", "room": null, "type": "input_select", "id": { "entity_id": "input_select.ds1621_fan_speed_select", "device_id": null } } ] }, { "id": "system_nodes_net_speed_change", "automation": "- alias: system_nodes_net_speed_change\n id: system_nodes_net_speed_change\n initial_state: true\n mode: queued\n max: 50\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id:\n - sensor.ms01a_enp3s0f0np0_speed\n - sensor.ms01a_enp3s0f1np1_speed\n - sensor.ms01a_enp88s0_speed\n - sensor.ms01a_enp90s0_speed\n - sensor.ms01a_enp1s0f0_speed\n - sensor.ms01a_enp1s0f1_speed\n - sensor.ms01a_enp1s0f2_speed\n - sensor.ms01a_enp1s0f3_speed\n - sensor.ms01b_enp3s0f0np0_speed\n - sensor.ms01b_enp3s0f1np1_speed\n - sensor.ms01b_enp88s0_speed\n - sensor.ms01b_enp90s0_speed\n - sensor.ms01b_enp1s0f0_speed\n - sensor.ms01b_enp1s0f1_speed\n - sensor.ms01b_enp1s0f2_speed\n - sensor.ms01b_enp1s0f3_speed\n to: null\n actions:\n - variables:\n old_value: '{%if trigger.from_state.state|float(0) < 1000 %} {{trigger.from_state.state}}\n Mb/s {%elif trigger.from_state.state|float(0) >= 1000 %} {{trigger.from_state.state|int(0)\n / 1000 }} Gb/s {%endif%}'\n new_value: '{%if trigger.to_state.state|float(0) < 1000 %} {{trigger.to_state.state}}\n Mb/s {%elif trigger.to_state.state|float(0) >= 1000 %} {{trigger.to_state.state|int(0)\n / 1000 }} Gb/s {%endif%}'\n - action: notify.telegram\n data:\n message: '🚦 {{trigger.to_state.name}}: {{old_value}} -> {{new_value}}'", "config": [ { "name": "MS01A enp1s0f0 Speed", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ms01a_enp1s0f0_speed", "device_id": null } }, { "name": "MS01A enp1s0f1 Speed", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ms01a_enp1s0f1_speed", "device_id": null } }, { "name": "MS01A enp1s0f2 Speed", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ms01a_enp1s0f2_speed", "device_id": null } }, { "name": "MS01A enp1s0f3 Speed", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ms01a_enp1s0f3_speed", "device_id": null } }, { "name": "MS01A enp3s0f0np0 Speed", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ms01a_enp3s0f0np0_speed", "device_id": null } }, { "name": "MS01A enp3s0f1np1 Speed", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ms01a_enp3s0f1np1_speed", "device_id": null } }, { "name": "MS01A enp88s0 Speed", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ms01a_enp88s0_speed", "device_id": null } }, { "name": "MS01A enp90s0 Speed", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ms01a_enp90s0_speed", "device_id": null } }, { "name": "MS01B enp1s0f0 Speed", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ms01b_enp1s0f0_speed", "device_id": null } }, { "name": "MS01B enp1s0f1 Speed", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ms01b_enp1s0f1_speed", "device_id": null } }, { "name": "MS01B enp1s0f2 Speed", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ms01b_enp1s0f2_speed", "device_id": null } }, { "name": "MS01B enp1s0f3 Speed", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ms01b_enp1s0f3_speed", "device_id": null } }, { "name": "MS01B enp3s0f0np0 Speed", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ms01b_enp3s0f0np0_speed", "device_id": null } }, { "name": "MS01B enp3s0f1np1 Speed", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ms01b_enp3s0f1np1_speed", "device_id": null } }, { "name": "MS01B enp88s0 Speed", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ms01b_enp88s0_speed", "device_id": null } }, { "name": "MS01B enp90s0 Speed", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ms01b_enp90s0_speed", "device_id": null } } ] }, { "id": "system_primary_ip_change", "automation": "- alias: system_primary_ip_change\n id: system_primary_ip_change\n initial_state: true\n mode: queued\n max: 50\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: sensor.udm_last_active_ip\n to: null\n actions:\n - action: notify.telegram\n data:\n message: '🚦 {{trigger.to_state.name}}: {{trigger.from_state.state}} -> {{trigger.to_state.state}}'", "config": [ { "name": "UDM Last Active IP", "room": null, "type": "sensor", "id": { "entity_id": "sensor.udm_last_active_ip", "device_id": null } } ] }, { "id": "system_plex_status_change", "automation": "- alias: system_plex_status_change\n id: system_plex_status_change\n initial_state: true\n mode: queued\n max: 50\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: sensor.plex_12\n to: unavalable\n id: id_to\n - trigger: state\n entity_id: sensor.plex_12\n from: unavalable\n id: id_from\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: id_to\n sequence:\n - action: notify.telegram\n data:\n message: 🔴 Plex went offline\n - conditions:\n - condition: trigger\n id: id_from\n sequence:\n - action: notify.telegram\n data:\n message: 🟢 Plex back online", "config": [ { "name": "Plex 12", "room": null, "type": "sensor", "id": { "entity_id": "sensor.plex_12", "device_id": null } } ] }, { "id": "system_retart_gateway", "automation": "- alias: system_retart_gateway\n id: system_retart_gateway\n initial_state: true\n mode: queued\n max: 50\n max_exceeded: silent\n triggers:\n - trigger: numeric_state\n entity_id: sensor.gateway3a_hb_free_memory\n below: 10000\n for:\n hours: 1\n actions:\n - action: select.select_option\n data:\n option: reboot\n target:\n entity_id: select.54ef443f1fac_command\n - action: notify.telegram\n data:\n message: 🔴 Gateway HB restart", "config": [ { "name": "Command 54ef443f1fac", "room": null, "type": "select", "id": { "entity_id": "select.54ef443f1fac_command", "device_id": null } }, { "name": "Gateway3A HB Free Memory", "room": "Hall Big", "type": "sensor", "id": { "entity_id": "sensor.gateway3a_hb_free_memory", "device_id": null } } ] }, { "id": "system_googlevideo_unavalable", "automation": "- alias: system_googlevideo_unavalable\n id: system_googlevideo_unavalable\n initial_state: true\n mode: queued\n max: 50\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.googlevideo_com\n to: 'off'\n for:\n minutes: 1\n id: to_off\n - trigger: state\n entity_id: binary_sensor.googlevideo_com\n to: 'on'\n for:\n minutes: 1\n id: to_on\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: to_off\n sequence:\n - action: input_boolean.turn_on\n target:\n entity_id: input_boolean.googlevideo_error\n - action: notify.telegram\n data:\n message: 🔴 Googlevideo connection lost\n - conditions:\n - condition: trigger\n id: to_on\n - condition: state\n entity_id: input_boolean.googlevideo_error\n state: 'on'\n sequence:\n - action: input_boolean.turn_off\n target:\n entity_id: input_boolean.googlevideo_error\n - action: notify.telegram\n data:\n message: 🟢 Googlevideo connection restored", "config": [ { "name": "GoogleVideo Com", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.googlevideo_com", "device_id": null } }, { "name": "GoogleVideo Error", "room": null, "type": "input_boolean", "id": { "entity_id": "input_boolean.googlevideo_error", "device_id": null } } ] }, { "id": "system_1621_go2rtc_streamcount", "automation": "- alias: system_1621_go2rtc_streamcount\n id: system_1621_go2rtc_streamcount\n initial_state: true\n mode: queued\n max: 50\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: sensor.1621_go2rtc_active_streams\n to: null\n for:\n seconds: 30\n conditions:\n - condition: state\n entity_id: sensor.1621_go2rtc_active_streams\n state: '0'\n actions:\n - action: button.press\n entity_id: button.kiosk_load_start_url", "config": [ { "name": "Kiosk Load Start URL", "room": null, "type": "button", "id": { "entity_id": "button.kiosk_load_start_url", "device_id": null } }, { "name": "1621 Go2RTC Active Streams", "room": null, "type": "sensor", "id": { "entity_id": "sensor.1621_go2rtc_active_streams", "device_id": null } } ] }, { "id": "system_health_cpu_temp", "automation": "- alias: system_health_cpu_temp\n id: system_health_cpu_temp\n initial_state: true\n mode: queued\n max: 5\n max_exceeded: silent\n triggers:\n - trigger: numeric_state\n entity_id: sensor.ms01a_cpu_temp, sensor.ms01b_cpu_temp, sensor.pbs100_cpu_temp\n above: 95\n for:\n minutes: 5\n id: temp_95\n - trigger: numeric_state\n entity_id: sensor.ms01a_cpu_temp, sensor.ms01b_cpu_temp, sensor.pbs100_cpu_temp\n above: 80\n for:\n minutes: 5\n id: temp_80\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: temp_95\n sequence:\n - parallel:\n - action: notify.mobile_app_iphone_16_pro_dima\n data:\n title: Внимание!\n message: '{{ trigger.to_state.attributes.friendly_name }} >90°'\n data:\n push:\n sound:\n name: default\n critical: 1\n volume: 1.0\n - action: notify.telegram\n data:\n message: 🔥 Внимание! {{ trigger.to_state.attributes.friendly_name }} >90°\n - conditions:\n - condition: trigger\n id: temp_80\n sequence:\n - parallel:\n - action: notify.telegram\n data:\n message: 🔥 Внимание! {{ trigger.to_state.attributes.friendly_name }} >80°", "config": [] }, { "id": "system_health_ssd_temp_70", "automation": "- alias: system_health_ssd_temp_70\n id: system_health_ssd_temp_70\n initial_state: true\n mode: queued\n max: 5\n max_exceeded: silent\n triggers:\n - trigger: numeric_state\n entity_id:\n - sensor.ms01a_nvme0_temp\n - sensor.ms01a_nvme1_temp\n - sensor.ms01b_nvme0_temp\n - sensor.ms01b_nvme1_temp\n - sensor.pbs100_nvme0_temp\n - sensor.pbs100_sda_temp\n above: 70\n for:\n minutes: 3\n actions:\n - action: notify.telegram\n data:\n message: 🌡 Внимание! {{ trigger.to_state.attributes.friendly_name }} >70°!", "config": [ { "name": "MS01A NVME0 Temp", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ms01a_nvme0_temp", "device_id": null } }, { "name": "MS01A NVME1 Temp", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ms01a_nvme1_temp", "device_id": null } }, { "name": "MS01B NVME0 Temp", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ms01b_nvme0_temp", "device_id": null } }, { "name": "MS01B NVME1 Temp", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ms01b_nvme1_temp", "device_id": null } }, { "name": "PBS100 NVME0 Temp", "room": null, "type": "sensor", "id": { "entity_id": "sensor.pbs100_nvme0_temp", "device_id": null } }, { "name": "PBS100 SDA Temp", "room": null, "type": "sensor", "id": { "entity_id": "sensor.pbs100_sda_temp", "device_id": null } } ] }, { "id": "system_health_synology_disks_status", "automation": "- alias: system_health_synology_disks_status\n id: system_health_synology_disks_status\n initial_state: true\n mode: queued\n max: 15\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id:\n - sensor.ds1621plus_drive_1_status\n - sensor.ds1621plus_drive_2_status\n - sensor.ds1621plus_drive_3_status\n - sensor.ds1621plus_drive_5_status\n - sensor.ds1621plus_drive_6_status\n - sensor.ds1621plus_m_2_drive_1_status\n - sensor.ds1621plus_m_2_drive_2_status\n - sensor.ds1621plus_drive_1_status_smart\n - sensor.ds1621plus_drive_2_status_smart\n - sensor.ds1621plus_drive_3_status_smart\n - sensor.ds1621plus_drive_5_status_smart\n - sensor.ds1621plus_drive_6_status_smart\n - sensor.ds1621plus_m_2_drive_1_status_smart\n - sensor.ds1621plus_m_2_drive_2_status_smart\n - sensor.ds920plus_drive_1_status\n - sensor.ds920plus_drive_2_status\n - sensor.ds920plus_drive_3_status\n - sensor.ds920plus_drive_4_status\n - sensor.ds920plus_cache_device_1_status\n - sensor.ds920plus_cache_device_2_status\n - sensor.ds920plus_drive_1_status_smart\n - sensor.ds920plus_drive_2_status_smart\n - sensor.ds920plus_drive_3_status_smart\n - sensor.ds920plus_drive_4_status_smart\n - sensor.ds920plus_cache_device_1_status_smart\n - sensor.ds920plus_cache_device_2_status_smart\n to: null\n for:\n minutes: 1\n conditions:\n - condition: template\n value_template: '{{ trigger.to_state.state != trigger.from_state.state and trigger.to_state.state\n not in [''unavailable''] and trigger.from_state.state not in [''unavailable'']\n }}'\n actions:\n - action: notify.telegram\n data:\n message: '🧰 Внимание! {{ trigger.to_state.name }}: {{ trigger.from_state.state\n }} -> {{ trigger.to_state.state }}!'", "config": [ { "name": "DS1621plus Drive 1 Status", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds1621plus_drive_1_status", "device_id": null } }, { "name": "DS1621plus Drive 1 Status Smart", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds1621plus_drive_1_status_smart", "device_id": null } }, { "name": "DS1621plus Drive 2 Status", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds1621plus_drive_2_status", "device_id": null } }, { "name": "DS1621plus Drive 2 Status Smart", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds1621plus_drive_2_status_smart", "device_id": null } }, { "name": "DS1621plus Drive 3 Status", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds1621plus_drive_3_status", "device_id": null } }, { "name": "DS1621plus Drive 3 Status Smart", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds1621plus_drive_3_status_smart", "device_id": null } }, { "name": "DS1621plus Drive 5 Status", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds1621plus_drive_5_status", "device_id": null } }, { "name": "DS1621plus Drive 5 Status Smart", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds1621plus_drive_5_status_smart", "device_id": null } }, { "name": "DS1621plus Drive 6 Status", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds1621plus_drive_6_status", "device_id": null } }, { "name": "DS1621plus Drive 6 Status Smart", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds1621plus_drive_6_status_smart", "device_id": null } }, { "name": "DS1621plus M 2 Drive 1 Status", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds1621plus_m_2_drive_1_status", "device_id": null } }, { "name": "DS1621plus M 2 Drive 1 Status Smart", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds1621plus_m_2_drive_1_status_smart", "device_id": null } }, { "name": "DS1621plus M 2 Drive 2 Status", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds1621plus_m_2_drive_2_status", "device_id": null } }, { "name": "DS1621plus M 2 Drive 2 Status Smart", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds1621plus_m_2_drive_2_status_smart", "device_id": null } }, { "name": "DS920plus Cache Device 1 Status", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds920plus_cache_device_1_status", "device_id": null } }, { "name": "DS920plus Cache Device 1 Status Smart", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds920plus_cache_device_1_status_smart", "device_id": null } }, { "name": "DS920plus Cache Device 2 Status", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds920plus_cache_device_2_status", "device_id": null } }, { "name": "DS920plus Cache Device 2 Status Smart", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds920plus_cache_device_2_status_smart", "device_id": null } }, { "name": "DS920plus Drive 1 Status", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds920plus_drive_1_status", "device_id": null } }, { "name": "DS920plus Drive 1 Status Smart", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds920plus_drive_1_status_smart", "device_id": null } }, { "name": "DS920plus Drive 2 Status", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds920plus_drive_2_status", "device_id": null } }, { "name": "DS920plus Drive 2 Status Smart", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds920plus_drive_2_status_smart", "device_id": null } }, { "name": "DS920plus Drive 3 Status", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds920plus_drive_3_status", "device_id": null } }, { "name": "DS920plus Drive 3 Status Smart", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds920plus_drive_3_status_smart", "device_id": null } }, { "name": "DS920plus Drive 4 Status", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds920plus_drive_4_status", "device_id": null } }, { "name": "DS920plus Drive 4 Status Smart", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ds920plus_drive_4_status_smart", "device_id": null } } ] }, { "id": "toilet_tank_counter", "automation": "- alias: toilet_tank_counter\n id: toilet_tank_counter\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x00158d0003262a35_contact\n from: 'off'\n to: 'on'\n conditions:\n - condition: template\n value_template: \"{% set ignore = ['unknown', 'unavailable', 'none'] %} {{ trigger.from_state.state\\\n \\ not in ignore and\\n trigger.to_state.state not in ignore and\\n trigger.to_state.state\\\n \\ != trigger.from_state.state\\n}}\\n\"\n actions:\n - action: counter.increment\n entity_id: counter.toilet_tank", "config": [ { "name": "Contact Sensor 3262a35", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0003262a35_contact", "device_id": null } }, { "name": "Toilet Tank", "room": null, "type": "counter", "id": { "entity_id": "counter.toilet_tank", "device_id": null } } ] }, { "id": "toilet_air_freshener_counter", "automation": "- alias: toilet_air_freshener_counter\n id: toilet_air_freshener_counter\n initial_state: true\n triggers:\n - trigger: state\n entity_id: number.d1mini_air_freshener_counter\n to: null\n conditions:\n - condition: template\n value_template: '{{ trigger.to_state.state|int(0) > trigger.from_state.state|int(0)\n }}'\n - condition: template\n value_template: \"{% set ignore = ['unknown', 'unavailable', 'none'] %} {{ trigger.from_state.state\\\n \\ not in ignore and\\n trigger.to_state.state not in ignore and\\n trigger.to_state.state\\\n \\ != trigger.from_state.state\\n}}\\n\"\n - condition: template\n value_template: '{{ (states(''sensor.d1mini_air_freshener_canister_left'')|int(0)\n < 10) and (states(''number.d1mini_air_freshener_counter'')|int(0) % 25) == 0\n }}'\n actions:\n - action: notify.telegram\n data:\n message: 🔋 Необходимо заменить баллон в освежителе - осталось менее {{states('sensor.d1mini_air_freshener_canister_left')|int(0)}}%!", "config": [ { "name": "D1Mini Air Freshener Counter", "room": null, "type": "number", "id": { "entity_id": "number.d1mini_air_freshener_counter", "device_id": null } }, { "name": "D1Mini Air Freshener Canister Left", "room": null, "type": "sensor", "id": { "entity_id": "sensor.d1mini_air_freshener_canister_left", "device_id": null } } ] }, { "id": "toilet_air_freshener_spray", "automation": "- alias: toilet_air_freshener_spray\n id: toilet_air_freshener_spray\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x00158d000232ddd6_contact\n from: 'off'\n to: 'on'\n for:\n minutes: 2\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: state\n entity_id: group.lights_t\n state: 'on'\n - condition: state\n entity_id: fan.esp32_node_b_fan_t\n state: 'off'\n actions:\n - if:\n - condition: state\n entity_id: switch.esp32_node_b_fan_b_manual_mode\n state: 'off'\n then:\n - action: fan.turn_on\n entity_id: fan.esp32_node_b_fan_t\n - wait_for_trigger:\n - trigger: state\n entity_id: binary_sensor.0x00158d000232ddd6_contact\n to: 'off'\n for:\n seconds: 10\n timeout:\n minutes: 30\n continue_on_timeout: false\n - action: timer.cancel\n entity_id: timer.fan_t\n - action: timer.start\n entity_id: timer.short_fan_t\n - condition: template\n value_template: '{{(as_timestamp(now()) - as_timestamp(states.button.d1mini_air_freshener_spray.last_changed)|int(0))\n > 60 }}'\n - action: button.press\n entity_id: button.d1mini_air_freshener_spray", "config": [ { "name": "esp32 node b fan b manual mode", "room": "bathroom", "type": "switch", "id": { "entity_id": "switch.esp32_node_b_fan_b_manual_mode", "device_id": null } }, { "name": "esp32 node b fan t", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.esp32_node_b_fan_t", "device_id": null } }, { "name": "timer fan t", "room": "bathroom", "type": "timer", "id": { "entity_id": "timer.fan_t", "device_id": null } }, { "name": "Contact Sensor 232ddd6", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d000232ddd6_contact", "device_id": null } }, { "name": "D1Mini Air Freshener Spray", "room": null, "type": "button", "id": { "entity_id": "button.d1mini_air_freshener_spray", "device_id": null } }, { "name": "Lights T Group", "room": null, "type": "group", "id": { "entity_id": "group.lights_t", "device_id": null } }, { "name": "Short Fan T Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.short_fan_t", "device_id": null } } ] }, { "id": "toilet_air_freshener_spray_manual", "automation": "- alias: toilet_air_freshener_spray_manual\n id: toilet_air_freshener_spray_manual\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0001b97111_action\n click_type: double\n actions:\n - action: button.press\n entity_id: button.d1mini_air_freshener_spray", "config": [ { "name": "D1Mini Air Freshener Spray", "room": null, "type": "button", "id": { "entity_id": "button.d1mini_air_freshener_spray", "device_id": null } }, { "name": "Action Sensor 1b97111", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x00158d0001b97111_action", "device_id": null } } ] }, { "id": "toilet_heater_control", "automation": "- alias: toilet_heater_control\n id: toilet_heater_control\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.heater_trigger_t\n to: null\n actions:\n - if:\n - condition: state\n entity_id: binary_sensor.heater_trigger_t\n state: 'on'\n then:\n - action: climate.turn_on\n entity_id: climate.sonoff_pow_r2_2_wall_heater\n else:\n - action: climate.turn_off\n entity_id: climate.sonoff_pow_r2_2_wall_heater", "config": [ { "name": "Heater Trigger T", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.heater_trigger_t", "device_id": null } }, { "name": "Sonoff Pow R2 2 Wall Heater", "room": null, "type": "climate", "id": { "entity_id": "climate.sonoff_pow_r2_2_wall_heater", "device_id": null } } ] }, { "id": "toilet_close_seat_notify", "automation": "- alias: toilet_close_seat_notify\n id: toilet_close_seat_notify\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.seat_not_closed\n from: 'off'\n to: 'on'\n conditions:\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'on'\n - condition: state\n entity_id: switch.system_dark_mode\n state: 'off'\n - condition: template\n value_template: '{{(as_timestamp(now())-as_timestamp(state_attr(''automation.toilet_close_seat_notify'',\n ''last_triggered''),0)|int(0)) > 15 }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - wait_for_trigger:\n - trigger: state\n entity_id: light.0x00158d0002a36f7f_channel_1\n to: 'off'\n for:\n seconds: 3\n - trigger: state\n entity_id: light.esp32_node_b_light\n to: 'off'\n for:\n seconds: 3\n - trigger: state\n entity_id: binary_sensor.0x00158d0001ef2ffc_contact\n to: 'on'\n for:\n seconds: 3\n - trigger: state\n entity_id: binary_sensor.0x00158d0001ef2ffc_contact\n to: 'off'\n timeout:\n minutes: 20\n continue_on_timeout: false\n - condition: state\n entity_id: binary_sensor.seat_not_closed\n state: 'on'\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id: media_player.yandex_k\n media_content_id: Пож+алуйста закр+ойте кр+ышку унит+аза!\n extra:\n volume_level: '{{states(\"input_number.main_volume\")|float(0) + 0.1}}'\n - wait_for_trigger:\n - trigger: state\n entity_id: binary_sensor.0x00158d000232ddd6_contact\n to: 'off'\n timeout:\n minutes: 5\n continue_on_timeout: false\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id: media_player.yandex_k\n media_content_id: Больш+ое спас+ибо!", "config": [ { "name": "yandex kitchen", "room": "kitchen", "type": "media_player", "id": { "entity_id": "media_player.yandex_k", "device_id": null } }, { "name": "system dark mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_dark_mode", "device_id": null } }, { "name": "main volume", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.main_volume", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "alice mode", "room": "system", "type": "input_select", "id": { "entity_id": "input_select.alice_mode", "device_id": null } }, { "name": "sasha door contact", "room": "hall_small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001ef2ffc_contact", "device_id": null } }, { "name": "Contact Sensor 232ddd6", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d000232ddd6_contact", "device_id": null } }, { "name": "Seat Not Closed", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.seat_not_closed", "device_id": null } }, { "name": "Light Channel 1 2a36f7f", "room": null, "type": "light", "id": { "entity_id": "light.0x00158d0002a36f7f_channel_1", "device_id": null } }, { "name": "ESP32 Node B Light", "room": "Bathroom", "type": "light", "id": { "entity_id": "light.esp32_node_b_light", "device_id": null } } ] }, { "id": "toilet_donedeal", "automation": "- alias: toilet_donedeal\n id: toilet_donedeal\n initial_state: true\n triggers:\n - trigger: event\n event_type: yandex_intent\n event_data:\n text: Я покакала\n actions:\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id: '{{ trigger.event.data.entity_id }}'\n media_content_id: '{{[''С облегчением!'',''Так держать!'',''Красава!'',''Красавелла!'',''Рада\n за тебя!'',''Давай еще!'']|random}}'\n extra:\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'\n - action: button.press\n entity_id: button.d1mini_air_freshener_spray\n - action: fan.turn_on\n entity_id: fan.esp32_node_b_fan_t\n - delay:\n seconds: 5\n - action: button.press\n entity_id: button.d1mini_air_freshener_spray", "config": [ { "name": "main volume", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.main_volume", "device_id": null } }, { "name": "alice mode", "room": "system", "type": "input_select", "id": { "entity_id": "input_select.alice_mode", "device_id": null } }, { "name": "esp32 node b fan t", "room": "bathroom", "type": "fan", "id": { "entity_id": "fan.esp32_node_b_fan_t", "device_id": null } }, { "name": "D1Mini Air Freshener Spray", "room": null, "type": "button", "id": { "entity_id": "button.d1mini_air_freshener_spray", "device_id": null } } ] }, { "id": "system_update_available_and_installed_notification", "automation": "- alias: system_update_available_and_installed_notification\n id: system_update_available_and_installed_notification\n initial_state: false\n mode: queued\n max: 10\n max_exceeded: silent\n triggers:\n - trigger: event\n event_type: state_changed\n conditions:\n - '{{ trigger.event.data.entity_id.startswith(''update.'') }}'\n - '{{ trigger.event.data.old_state is not none and trigger.event.data.new_state\n is not none }}'\n - or:\n - condition: template\n value_template: \"{{ \\n trigger.event.data.new_state.state == 'on' and\\n ((is_state_attr(trigger.event.data.entity_id,\\\n \\ 'device_class', 'firmware')\\n and version(trigger.event.data.new_state.attributes.latest_version)\\\n \\ != version(trigger.event.data.old_state.attributes.latest_version))\\n or\\\n \\ version(trigger.event.data.new_state.attributes.latest_version) > version(trigger.event.data.old_state.attributes.latest_version))\\\n \\ and\\n trigger.event.data.new_state.attributes.latest_version not in not_has_state\\\n \\ and\\n trigger.event.data.new_state.attributes.latest_version is not none\\n\\\n }}\\n\"\n - condition: template\n value_template: \"{{ \\n trigger.event.data.old_state.state == 'on' and trigger.event.data.new_state.state\\\n \\ == 'off' and\\n ((is_state_attr(trigger.event.data.entity_id, 'device_class',\\\n \\ 'firmware')\\n and version(trigger.event.data.new_state.attributes.installed_version)\\\n \\ != version(trigger.event.data.old_state.attributes.installed_version))\\n\\\n \\ or version(trigger.event.data.new_state.attributes.installed_version) >\\\n \\ version(trigger.event.data.old_state.attributes.installed_version)) and\\n\\\n \\ trigger.event.data.new_state.attributes.installed_version not in not_has_state\\\n \\ and\\n trigger.event.data.new_state.attributes.installed_version is not\\\n \\ none\\n}}\\n\"\n actions:\n - variables:\n latest_version: '{{ trigger.event.data.new_state.attributes.latest_version }}'\n installed_version: '{{ state_attr(trigger.event.data.entity_id, ''installed_version'')\n }}'\n old_installed_version: '{{ trigger.event.data.old_state.attributes.installed_version\n }}'\n friendlyname: '{{- trigger.event.data.new_state.name | replace('' Update'',\n '''') -}}'\n - if:\n - condition: template\n value_template: '{{ trigger.event.data.new_state.attributes.installed_version\n != trigger.event.data.old_state.attributes.installed_version }}'\n then:\n - action: notify.telegram\n data:\n message: 🎊 {{ friendlyname }} обновлен с {{ old_installed_version }} на {{\n latest_version }}\n else:\n - action: notify.telegram\n data:\n message: 🛠 {{ friendlyname }} доступна новая версия {{ latest_version }}.\n Текущая {{ installed_version }}", "config": [] }, { "id": "hall_big_main_power_turned_off", "automation": "- alias: hall_big_main_power_turned_off\n id: hall_big_main_power_turned_off\n initial_state: true\n triggers:\n - trigger: state\n entity_id: switch.0x00158d000230fc52_outlet\n to: 'off'\n from: 'on'\n actions:\n - action: notify.telegram\n data:\n message: 🔌 Внимание! Главная розетка отключена! Запущен UPS (1200)", "config": [ { "name": "Switch Outlet 230fc52", "room": null, "type": "switch", "id": { "entity_id": "switch.0x00158d000230fc52_outlet", "device_id": null } } ] }, { "id": "hall_big_main_plug_pulled_out", "automation": "- alias: hall_big_main_plug_pulled_out\n id: hall_big_main_plug_pulled_out\n initial_state: true\n triggers:\n - trigger: numeric_state\n entity_id: sensor.0x00158d000230fc52_power\n below: 10\n actions:\n - action: notify.telegram\n data:\n message: 🔌 Внимание! Нагрузка в главной розетке упала! Проверь кабель!", "config": [ { "name": "Power Sensor 230fc52", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x00158d000230fc52_power", "device_id": null } } ] }, { "id": "hall_big_main_power_overpower", "automation": "- alias: hall_big_main_power_overpower\n id: hall_big_main_power_overpower\n initial_state: true\n triggers:\n - trigger: numeric_state\n entity_id: sensor.0x00158d000230fc52_power\n above: 1700\n actions:\n - action: notify.telegram\n data:\n message: 🔌 Внимание! Перегрузка главной розетки! Отключите лишние потребители!", "config": [ { "name": "Power Sensor 230fc52", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x00158d000230fc52_power", "device_id": null } } ] }, { "id": "hall_big_main_power_turned_on", "automation": "- alias: hall_big_main_power_turned_on\n id: hall_big_main_power_turned_on\n initial_state: true\n triggers:\n - trigger: state\n entity_id: switch.0x00158d000230fc52_outlet\n to: 'on'\n from: 'off'\n actions:\n - action: notify.telegram\n data:\n message: 🔌 Электроснабжение восстановлено! Начинаем зарядку UPS(1200)!", "config": [ { "name": "Switch Outlet 230fc52", "room": null, "type": "switch", "id": { "entity_id": "switch.0x00158d000230fc52_outlet", "device_id": null } } ] }, { "id": "hall_big_ups_states", "automation": "- alias: hall_big_ups_states\n id: hall_big_ups_states\n initial_state: true\n triggers:\n - trigger: state\n entity_id: sensor.ippon_1500_status_data\n to: null\n conditions:\n - condition: template\n value_template: '{{ trigger.to_state.state != trigger.from_state.state }}'\n actions:\n - choose:\n - conditions:\n - condition: template\n value_template: '{{ trigger.to_state.state == ''OB DISCHRG'' or trigger.to_state.state\n == ''OB'' }}'\n sequence:\n - parallel:\n - action: notify.telegram\n data:\n message: 🔋 Внимание! Запущен UPS (1200)!\n - action: notify.mobile_app_iphone_16_pro_dima\n data:\n title: Внимание!\n message: Запущен UPS (1200)\n - conditions:\n - condition: template\n value_template: '{{ trigger.to_state.state == ''LB'' or trigger.to_state.state\n == ''FSD OB DISCHRG LB''}}'\n sequence:\n - parallel:\n - action: notify.telegram\n data:\n message: 🚨 Внимание! Заряд батареи (1200) критический! Завершение работы\n через 10сек!\n - action: notify.mobile_app_iphone_16_pro_dima\n data:\n title: Внимание!\n message: UPS полностью разряжен! Завершаем работу через 10сек!\n data:\n push:\n sound:\n name: default\n critical: 1\n volume: 1.0\n - delay:\n seconds: 10\n - action: hassio.host_shutdown\n - conditions:\n - condition: template\n value_template: '{{ trigger.to_state.state == ''OL CHRG'' or trigger.to_state.state\n == ''OL''}}'\n - condition: template\n value_template: '{{ trigger.from_state.state not in [''unknown'',''unavailable'',''none'']\n }}'\n sequence:\n - action: notify.telegram\n data:\n message: 🔋 Питание восстановлено! Начинаем заряд батареи (1200)!\n - conditions:\n - condition: template\n value_template: '{{ trigger.to_state.state in [''unknown'',''unavailable'']\n }}'\n - condition: template\n value_template: '{{ trigger.from_state.state not in [''unknown'',''unavailable'',''none'']\n }}'\n sequence:\n - action: notify.telegram\n data:\n message: 🚨 Внимание! Связь с UPS(1200) потеряна!\n - conditions:\n - condition: template\n value_template: '{{ trigger.from_state.state in [''unknown'',''unavailable'']\n }}'\n - condition: template\n value_template: '{{ trigger.to_state.state not in [''unknown'',''unavailable'',''none'']\n }}'\n sequence:\n - action: notify.telegram\n data:\n message: 🚨 Внимание! Связь с UPS(1200) восстановлена!", "config": [ { "name": "Ippon 1500 Status Data", "room": null, "type": "sensor", "id": { "entity_id": "sensor.ippon_1500_status_data", "device_id": null } } ] }, { "id": "system_water_cold_water_increase_counter", "automation": "- alias: system_water_cold_water_increase_counter\n id: system_water_cold_water_increase_counter\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x00158d0006d31d78_contact\n from: 'on'\n to: 'off'\n for:\n seconds: 5\n actions:\n - action: input_number.set_value\n data:\n entity_id: input_number.cold_water_meter\n value: '{{ (states(''input_number.cold_water_meter'')|float(0) + 0.01 ) | round(2,\n ''common'') }}'\n - action: input_number.set_value\n data:\n entity_id: input_number.cold_water_meter_month\n value: '{{ (states(''input_number.cold_water_meter_month'')|float(0) + 0.01\n ) | round(2, ''common'') }}'\n - action: mqtt.publish\n data:\n topic: utility/main/cold_water_meter\n payload: '{{states(''input_number.cold_water_meter'')|float(0)}}'\n retain: true\n - action: mqtt.publish\n data:\n topic: utility/main/cold_water_meter_month\n payload: '{{states(''input_number.cold_water_meter_month'')|float(0)}}'\n retain: true", "config": [ { "name": "Contact Sensor 6d31d78", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0006d31d78_contact", "device_id": null } }, { "name": "Cold Water Meter", "room": null, "type": "input_number", "id": { "entity_id": "input_number.cold_water_meter", "device_id": null } }, { "name": "Cold Water Meter Month", "room": null, "type": "input_number", "id": { "entity_id": "input_number.cold_water_meter_month", "device_id": null } } ] }, { "id": "system_water_hot_water_increase_counter", "automation": "- alias: system_water_hot_water_increase_counter\n id: system_water_hot_water_increase_counter\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x00158d000236fcd5_contact\n from: 'on'\n to: 'off'\n for:\n seconds: 5\n actions:\n - action: input_number.set_value\n data:\n entity_id: input_number.hot_water_meter\n value: '{{ (states(''input_number.hot_water_meter'')|float(0) + 0.01 ) | round(2,\n ''common'') }}'\n - action: input_number.set_value\n data:\n entity_id: input_number.hot_water_meter_month\n value: '{{ (states(''input_number.hot_water_meter_month'')|float(0) + 0.01 )\n | round(2, ''common'') }}'\n - action: mqtt.publish\n data:\n topic: utility/main/hot_water_meter\n payload: '{{states(''input_number.hot_water_meter'')|float(0)}}'\n retain: true\n - action: mqtt.publish\n data:\n topic: utility/main/hot_water_meter_month\n payload: '{{states(''input_number.hot_water_meter_month'')|float(0)}}'\n retain: true", "config": [ { "name": "Contact Sensor 236fcd5", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d000236fcd5_contact", "device_id": null } }, { "name": "Hot Water Meter", "room": null, "type": "input_number", "id": { "entity_id": "input_number.hot_water_meter", "device_id": null } }, { "name": "Hot Water Meter Month", "room": null, "type": "input_number", "id": { "entity_id": "input_number.hot_water_meter_month", "device_id": null } } ] }, { "id": "system_power_meter_daily", "automation": "- alias: system_power_meter_daily\n id: system_power_meter_daily\n initial_state: true\n triggers:\n - trigger: time\n at: '23:59:30'\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: binary_sensor.esp32_pzem_hb_status\n state: 'on'\n sequence:\n - action: input_number.set_value\n data:\n entity_id: input_number.power_meter_t1\n value: '{{ ((states(''input_number.power_meter_t1'')) | float(0) + states(''sensor.esp32_pzem_hb_energy_daily_day'')|float(0)/1\n )|round(2, ''common'') }}'\n - action: input_number.set_value\n data:\n entity_id: input_number.power_meter_t2\n value: '{{ ((states(''input_number.power_meter_t2'')) | float(0) + states(''sensor.esp32_pzem_hb_energy_daily_night'')|float(0)/1\n )|round(2, ''common'') }}'\n - action: mqtt.publish\n data:\n topic: utility/main/energy/day\n payload: '{{ states(''input_number.power_meter_t1'') }}'\n retain: true\n - action: mqtt.publish\n data:\n topic: utility/main/energy/night\n payload: '{{ states(''input_number.power_meter_t2'') }}'\n retain: true\n - action: notify.telegram\n data:\n message: 🔌 Данные счетчика электричества обновлены! D {{states('sensor.esp32_pzem_hb_energy_daily_day')|int(0)}},\n N {{states('sensor.esp32_pzem_hb_energy_daily_night')|int(0)}}\n - conditions:\n - condition: state\n entity_id: binary_sensor.esp32_pzem_hb_status\n state: 'off'\n sequence:\n - action: notify.telegram\n data:\n message: 🔌 PZEM недоступен! Ожидаем\n - wait_for_trigger:\n - trigger: state\n entity_id: binary_sensor.esp32_pzem_hb_status\n to: 'on'\n timeout:\n seconds: 28\n continue_on_timeout: false\n - action: notify.telegram\n data:\n message: 🔌 PZEM доступен!\n - action: input_number.set_value\n data:\n entity_id: input_number.power_meter_t1\n value: '{{ ((states(''input_number.power_meter_t1'')) | float(0) + states(''sensor.esp32_pzem_hb_energy_daily_day'')|float(0)/1\n )|round(2, ''common'') }}'\n - action: input_number.set_value\n data:\n entity_id: input_number.power_meter_t2\n value: '{{ ((states(''input_number.power_meter_t2'')) | float(0) + states(''sensor.esp32_pzem_hb_energy_daily_night'')|float(0)/1\n )|round(2, ''common'') }}'\n - action: mqtt.publish\n data:\n topic: utility/main/energy/day\n payload: '{{ states(''input_number.power_meter_t1'') }}'\n retain: true\n - action: mqtt.publish\n data:\n topic: utility/main/energy/night\n payload: '{{ states(''input_number.power_meter_t2'') }}'\n retain: true\n - action: notify.telegram\n data:\n message: 🔌 Данные счетчика электричества обновлены!", "config": [ { "name": "ESP32 PZEM HB Status", "room": "Hall Big", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_pzem_hb_status", "device_id": null } }, { "name": "Power Meter T1", "room": null, "type": "input_number", "id": { "entity_id": "input_number.power_meter_t1", "device_id": null } }, { "name": "Power Meter T2", "room": null, "type": "input_number", "id": { "entity_id": "input_number.power_meter_t2", "device_id": null } }, { "name": "ESP32 PZEM HB Energy Daily Day", "room": "Hall Big", "type": "sensor", "id": { "entity_id": "sensor.esp32_pzem_hb_energy_daily_day", "device_id": null } }, { "name": "ESP32 PZEM HB Energy Daily Night", "room": "Hall Big", "type": "sensor", "id": { "entity_id": "sensor.esp32_pzem_hb_energy_daily_night", "device_id": null } } ] }, { "id": "system_new_month_notification", "automation": "- alias: system_new_month_notification\n id: system_new_month_notification\n initial_state: true\n triggers:\n - trigger: time\n at: 00:00:10\n conditions:\n - '{{ now().timestamp() | timestamp_custom(''%d'') | int(0) == 21 }}'\n actions:\n - action: mqtt.publish\n data:\n topic: utility/main/{{now().year}}/{{now().month}}/hot_water_meter\n payload: '{{states(''input_number.hot_water_meter'')|float(0)}}'\n retain: true\n - action: mqtt.publish\n data:\n topic: utility/main/{{now().year}}/{{now().month}}/cold_water_meter\n payload: '{{states(''input_number.cold_water_meter'')|float(0)}}'\n retain: true\n - action: mqtt.publish\n data:\n topic: utility/main/{{now().year}}/{{now().month}}/power_meter_t1\n payload: '{{((states(''input_number.power_meter_t1''))|float(0))}}'\n retain: true\n - action: mqtt.publish\n data:\n topic: utility/main/{{now().year}}/{{now().month}}/power_meter_t2\n payload: '{{((states(''input_number.power_meter_t2''))|float(0))}}'\n retain: true\n - action: mqtt.publish\n data:\n topic: utility/main/{{now().year}}/{{now().month}}/timestamp\n payload: '{{as_timestamp(now()) | timestamp_custom(''%d-%m-%Y %H:%M:%S'',true,0)}}'\n retain: true\n - action: notify.telegram\n data:\n message: '{{ \"\\U0001f4a6\" }} Показания счетчиков: ХВС: {{ states(''input_number.cold_water_meter'')|float(0)\n }}м3 ГВС: {{ states(''input_number.hot_water_meter'')|float(0) }}м3\n\n За месяц: ХВС: {{ states(''input_number.cold_water_meter_month'')|float(0)\n }}м3 ГВС: {{ states(''input_number.hot_water_meter_month'')|float(0) }}м3\n Стоимость: {{ ((states(''sensor.water_cost''))|float(0))}}руб.\n\n '\n - action: notify.telegram\n data:\n message: '{{ \"\\U0001f50c\" }} Показания счетчика: Т1: {{ ((states(''input_number.power_meter_t1''))|float(0))}}\n кВт*ч Т2: {{ ((states(''input_number.power_meter_t2''))|float(0))}} кВт*ч\n\n За месяц: Т1: {{ ((states(''sensor.esp32_pzem_hb_energy_monthly_day'')|float(0)))|round(0,\n ''common'')}} кВт*ч Т2: {{ ((states(''sensor.esp32_pzem_hb_energy_monthly_night'')|float(0)))|round(0,\n ''common'')}} кВт*ч Стоимость: {{ ((states(''sensor.power_cost''))|float(0))\n }} руб.\n\n '\n - action: input_number.set_value\n data:\n entity_id: input_number.power_meter_last_month_t1\n value: '{{ states(''input_number.power_meter_t1'')|float(0)}}'\n - action: input_number.set_value\n data:\n entity_id: input_number.power_meter_last_month_t2\n value: '{{ states(''input_number.power_meter_t2'')|float(0)}}'\n - action: switch.turn_on\n entity_id: switch.esp32_pzem_hb_energy_reset_all\n - delay:\n seconds: 10\n - action: switch.turn_on\n entity_id: switch.esp32_pzem_hb_energy_reset_uart\n - action: input_number.set_value\n data:\n entity_id: input_number.hot_water_meter_last_month\n value: '{{ states(''input_number.hot_water_meter'')|float(0) }}'\n - action: input_number.set_value\n data:\n entity_id: input_number.cold_water_meter_last_month\n value: '{{ states(''input_number.cold_water_meter'')|float(0) }}'\n - action: input_number.set_value\n data:\n entity_id:\n - input_number.hot_water_meter_month\n - input_number.cold_water_meter_month\n value: 0", "config": [ { "name": "Cold Water Meter", "room": null, "type": "input_number", "id": { "entity_id": "input_number.cold_water_meter", "device_id": null } }, { "name": "Cold Water Meter Last Month", "room": null, "type": "input_number", "id": { "entity_id": "input_number.cold_water_meter_last_month", "device_id": null } }, { "name": "Cold Water Meter Month", "room": null, "type": "input_number", "id": { "entity_id": "input_number.cold_water_meter_month", "device_id": null } }, { "name": "Hot Water Meter", "room": null, "type": "input_number", "id": { "entity_id": "input_number.hot_water_meter", "device_id": null } }, { "name": "Hot Water Meter Last Month", "room": null, "type": "input_number", "id": { "entity_id": "input_number.hot_water_meter_last_month", "device_id": null } }, { "name": "Hot Water Meter Month", "room": null, "type": "input_number", "id": { "entity_id": "input_number.hot_water_meter_month", "device_id": null } }, { "name": "Power Meter Last Month T1", "room": null, "type": "input_number", "id": { "entity_id": "input_number.power_meter_last_month_t1", "device_id": null } }, { "name": "Power Meter Last Month T2", "room": null, "type": "input_number", "id": { "entity_id": "input_number.power_meter_last_month_t2", "device_id": null } }, { "name": "Power Meter T1", "room": null, "type": "input_number", "id": { "entity_id": "input_number.power_meter_t1", "device_id": null } }, { "name": "Power Meter T2", "room": null, "type": "input_number", "id": { "entity_id": "input_number.power_meter_t2", "device_id": null } }, { "name": "ESP32 PZEM HB Energy Monthly Day", "room": "Hall Big", "type": "sensor", "id": { "entity_id": "sensor.esp32_pzem_hb_energy_monthly_day", "device_id": null } }, { "name": "ESP32 PZEM HB Energy Monthly Night", "room": "Hall Big", "type": "sensor", "id": { "entity_id": "sensor.esp32_pzem_hb_energy_monthly_night", "device_id": null } }, { "name": "Power Cost", "room": null, "type": "sensor", "id": { "entity_id": "sensor.power_cost", "device_id": null } }, { "name": "Water Cost", "room": null, "type": "sensor", "id": { "entity_id": "sensor.water_cost", "device_id": null } }, { "name": "ESP32 PZEM HB Energy Reset All", "room": "Hall Big", "type": "switch", "id": { "entity_id": "switch.esp32_pzem_hb_energy_reset_all", "device_id": null } }, { "name": "ESP32 PZEM HB Energy Reset UART", "room": "Hall Big", "type": "switch", "id": { "entity_id": "switch.esp32_pzem_hb_energy_reset_uart", "device_id": null } } ] }, { "id": "system_power_15A_current", "automation": "- alias: system_power_15A_current\n id: system_power_15A_current\n initial_state: true\n triggers:\n - trigger: numeric_state\n entity_id: sensor.esp32_pzem_hb_current\n above: 15\n below: 20\n conditions:\n - condition: template\n value_template: '{{ (as_timestamp(now())|int(0) - as_timestamp(state_attr(''automation.system_power_15A_current'',\n ''last_triggered''),0)|int(0)) > 10*60 }}'\n actions:\n - action: notify.telegram\n data:\n message: 🚨 Внимание! Общий ток более 15А!", "config": [ { "name": "ESP32 PZEM HB Current", "room": "Hall Big", "type": "sensor", "id": { "entity_id": "sensor.esp32_pzem_hb_current", "device_id": null } } ] }, { "id": "system_power_20A_current", "automation": "- alias: system_power_20A_current\n id: system_power_20A_current\n initial_state: true\n triggers:\n - trigger: numeric_state\n entity_id: sensor.esp32_pzem_hb_current\n above: 20\n below: 30\n conditions:\n - condition: template\n value_template: '{{ (as_timestamp(now())|int(0) - as_timestamp(state_attr(''automation.system_power_20A_current'',\n ''last_triggered''),0)|int(0)) > 10*60 }}'\n actions:\n - action: notify.telegram\n data:\n message: 🚨 Внимание! Общий ток более 20А!", "config": [ { "name": "ESP32 PZEM HB Current", "room": "Hall Big", "type": "sensor", "id": { "entity_id": "sensor.esp32_pzem_hb_current", "device_id": null } } ] }, { "id": "system_power_30A_current", "automation": "- alias: system_power_30A_current\n id: system_power_30A_current\n initial_state: true\n triggers:\n - trigger: numeric_state\n entity_id: sensor.esp32_pzem_hb_current\n above: 30\n below: 40\n conditions:\n - condition: template\n value_template: '{{ (as_timestamp(now())|int(0) - as_timestamp(state_attr(''automation.system_power_30A_current'',\n ''last_triggered''),0)|int(0)) > 10*60 }}'\n actions:\n - parallel:\n - action: notify.telegram\n data:\n message: 🚨 Внимание! Общий ток более 30А!\n data:\n push:\n sound:\n name: default\n critical: 1\n volume: 1.0\n - action: notify.mobile_app_iphone_16_pro_dima\n data:\n title: Внимание!\n message: Внимание! Общий ток более 30А", "config": [ { "name": "ESP32 PZEM HB Current", "room": "Hall Big", "type": "sensor", "id": { "entity_id": "sensor.esp32_pzem_hb_current", "device_id": null } } ] }, { "id": "system_high_power_while_not_home", "automation": "- alias: system_high_power_while_not_home\n id: system_high_power_while_not_home\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /10\n conditions:\n - condition: template\n value_template: '{{ is_state(''switch.system_security_mode'',''on'') }}'\n - condition: numeric_state\n entity_id: sensor.esp32_pzem_hb_power\n above: 1200\n actions:\n - parallel:\n - action: notify.telegram\n data:\n message: 🚨 Внимание! Охрана Вкл! Высокое потребление электричества {{states('sensor.esp32_pzem_hb_power')|int(0)}}Вт!\n - action: notify.mobile_app_iphone_16_pro_dima\n data:\n title: Внимание!\n message: Охрана Вкл! Высокое потребление электричества {{states('sensor.esp32_pzem_hb_power')|int(0)}}Вт!\n data:\n push:\n sound:\n name: default\n critical: 1\n volume: 1.0", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "ESP32 PZEM HB Power", "room": "Hall Big", "type": "sensor", "id": { "entity_id": "sensor.esp32_pzem_hb_power", "device_id": null } } ] }, { "id": "system_water_consumption_not_home", "automation": "- alias: system_water_consumption_not_home\n id: system_water_consumption_not_home\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.0x00158d0006d31d78_contact\n from: 'on'\n to: 'off'\n for:\n seconds: 5\n - trigger: state\n entity_id: binary_sensor.0x00158d000236fcd5_contact\n from: 'on'\n to: 'off'\n for:\n seconds: 5\n conditions:\n - condition: template\n value_template: '{{ is_state(''switch.system_security_mode'',''on'') }}'\n actions:\n - parallel:\n - action: notify.telegram\n data:\n message: 🚨 Внимание! Охрана Вкл! Потребление {% if 'Hot' in trigger.to_state.attributes.friendly_name\n %}горячей{%else%}холодной{%endif%} воды!\n - action: notify.mobile_app_iphone_16_pro_dima\n data:\n title: Внимание!\n message: Охрана Вкл! Потребление {% if 'Hot' in trigger.to_state.attributes.friendly_name\n %}горячей{%else%}холодной{%endif%} воды!\n data:\n push:\n sound:\n name: default\n critical: 1\n volume: 1.0", "config": [ { "name": "system security mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_security_mode", "device_id": null } }, { "name": "Contact Sensor 236fcd5", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d000236fcd5_contact", "device_id": null } }, { "name": "Contact Sensor 6d31d78", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0006d31d78_contact", "device_id": null } } ] }, { "id": "system_water_sensor_outage", "automation": "- alias: system_water_sensor_outage\n id: system_water_sensor_outage\n initial_state: true\n triggers:\n - trigger: time_pattern\n minutes: /30\n conditions:\n - condition: template\n value_template: '{{ as_timestamp(now())- as_timestamp(states.sensor[''0x00158d0006d31d78_zigbee''].last_updated)\n > 2*60*60 or as_timestamp(now())- as_timestamp(states.sensor[''0x00158d000236fcd5_zigbee''].last_updated)\n > 2*60*60 }}\n\n '\n actions:\n - action: notify.telegram\n data:\n message: ❌ Внимание! Нет данных от счетчика {% if as_timestamp(now())- as_timestamp(states.binary_sensor['0x00158d0006d31d78_contact'].last_updated)\n > 2*60*60 %}холодной{%else%}горячей{%endif%} воды!", "config": [] }, { "id": "bathroom_water_valves_test", "automation": "- alias: bathroom_water_valves_test\n id: bathroom_water_valves_test\n initial_state: true\n triggers:\n - trigger: time\n at: 00:01:00\n conditions:\n - '{{ now().timestamp() | timestamp_custom(''%d'') | int(0) == 15 }}'\n actions:\n - action: notify.telegram\n data:\n message: 🚰 Проверка кранов - закрываем!\n - action: button.press\n entity_id: button.esp32_node_b_close_valve\n - delay: 00:00:25\n - action: switch.turn_off\n entity_id: switch.esp32_node_b_relay_1\n - delay: 00:00:05\n - action: notify.telegram\n data:\n message: 🚰 Проверка кранов - открываем!\n - action: button.press\n entity_id: button.esp32_node_b_open_valve\n - delay: 00:00:25\n - action: switch.turn_off\n entity_id: switch.esp32_node_b_relay_2\n - action: notify.telegram\n data:\n message: ✅ Проверка кранов завершена!", "config": [ { "name": "ESP32 Node B Close Valve", "room": "Bathroom", "type": "button", "id": { "entity_id": "button.esp32_node_b_close_valve", "device_id": null } }, { "name": "ESP32 Node B Open Valve", "room": "Bathroom", "type": "button", "id": { "entity_id": "button.esp32_node_b_open_valve", "device_id": null } }, { "name": "ESP32 Node B Relay 1", "room": "Bathroom", "type": "switch", "id": { "entity_id": "switch.esp32_node_b_relay_1", "device_id": null } }, { "name": "ESP32 Node B Relay 2", "room": "Bathroom", "type": "switch", "id": { "entity_id": "switch.esp32_node_b_relay_2", "device_id": null } } ] }, { "id": "vova_tv_control", "automation": "- alias: vova_tv_control\n id: vova_tv_control\n initial_state: true\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.tv_delay_off\n id: timer_tv_off\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.tv_delay_on\n id: timer_tv_on\n - trigger: time\n at: '22:00:00'\n id: time_trigger_night\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d00023d3206_action\n click_type: single\n id: button_single_click\n actions:\n - choose:\n - conditions:\n - condition: trigger\n id: timer_tv_off\n sequence:\n - action: media_player.turn_off\n entity_id: media_player.tv_v\n - action: switch.turn_off\n entity_id: switch.0x00158d000290a093_plug\n - action: timer.start\n entity_id: timer.tv_delay_on\n - conditions:\n - condition: trigger\n id: timer_tv_on\n sequence:\n - not:\n - condition: time\n after: '21:00:00'\n - action: switch.turn_on\n entity_id: switch.0x00158d000290a093_plug\n - conditions:\n - condition: trigger\n id: time_trigger_night\n sequence:\n - action: switch.turn_off\n entity_id: switch.0x00158d000290a093_plug\n - conditions:\n - condition: trigger\n id: button_single_click\n sequence:\n - action: switch.toggle\n entity_id: switch.0x00158d000290a093_plug", "config": [ { "name": "TV V", "room": "Vova Room", "type": "media_player", "id": { "entity_id": "media_player.tv_v", "device_id": null } }, { "name": "Action Sensor 23d3206", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x00158d00023d3206_action", "device_id": null } }, { "name": "Switch Plug 290a093", "room": null, "type": "switch", "id": { "entity_id": "switch.0x00158d000290a093_plug", "device_id": null } }, { "name": "TV Delay Off Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.tv_delay_off", "device_id": null } }, { "name": "TV Delay On Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.tv_delay_on", "device_id": null } } ] }, { "id": "vova_purifier_breather_toggle", "automation": "- alias: vova_purifier_breather_toggle\n id: vova_purifier_breather_toggle\n initial_state: true\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: person.sandra\n to: home\n - trigger: state\n entity_id: person.sandra\n from: home\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: template\n value_template: \"{% set ignore = ['unknown', 'unavailable', 'none','0'] %} {{\\\n \\ trigger.from_state.state not in ignore and\\n trigger.to_state.state not in\\\n \\ ignore and\\n trigger.to_state.state != trigger.from_state.state }}\\n\"\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: person.sandra\n state: home\n sequence:\n - action: fan.turn_on\n entity_id: fan.purifier2s\n - action: switch.turn_off\n entity_id: switch.system_breather_auto_v\n - conditions:\n - condition: not\n conditions:\n - condition: state\n entity_id: person.sandra\n state: home\n sequence:\n - action: fan.turn_off\n entity_id: fan.purifier2s\n - action: switch.turn_off\n entity_id: switch.system_hourly_mode_breather_v\n - action: switch.turn_on\n entity_id: switch.system_breather_auto_v", "config": [ { "name": "person sandra", "room": "system", "type": "person", "id": { "entity_id": "person.sandra", "device_id": null } }, { "name": "Purifier2s Fan", "room": null, "type": "fan", "id": { "entity_id": "fan.purifier2s", "device_id": null } }, { "name": "System Breather Auto V", "room": null, "type": "switch", "id": { "entity_id": "switch.system_breather_auto_v", "device_id": null } }, { "name": "System Hourly Mode Breather V", "room": null, "type": "switch", "id": { "entity_id": "switch.system_hourly_mode_breather_v", "device_id": null } } ] }, { "id": "vova_purifier_favorite_mode", "automation": "- alias: vova_purifier_favorite_mode\n id: vova_purifier_favorite_mode\n initial_state: false\n mode: single\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: fan.purifier2s\n for:\n minutes: 1\n conditions:\n - condition: state\n entity_id: fan.purifier2s\n state: 'on'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'off'\n - condition: not\n conditions:\n - condition: state\n entity_id: fan.purifier2s\n attribute: preset_mode\n state: Favorite\n actions:\n - action: fan.set_preset_mode\n data:\n entity_id: fan.purifier2s\n preset_mode: Favorite", "config": [ { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "Purifier2s Fan", "room": null, "type": "fan", "id": { "entity_id": "fan.purifier2s", "device_id": null } } ] }, { "id": "vova_sleep_time", "automation": "- alias: vova_sleep_time\n id: vova_sleep_time\n initial_state: true\n triggers:\n - trigger: event\n event_type: yandex_intent\n event_data:\n text: Пора спать\n conditions:\n - condition: template\n value_template: '{{ trigger.event.data.entity_id == ''media_player.yandex_v''\n }}'\n actions:\n - action: switch.turn_off\n entity_id: switch.0x00158d000290a093_plug\n - action: media_player.turn_off\n entity_id: media_player.apple_tv_v\n - parallel:\n - action: light.turn_off\n entity_id: light.square_led_v\n data:\n transition: 15\n - action: light.turn_off\n entity_id: light.square_led_v_nightlight\n data:\n transition: 15\n - action: light.turn_off\n entity_id: light.0x54ef441000d4e7fd_light\n data:\n transition: 15\n - if:\n - condition: not\n conditions:\n - condition: state\n entity_id: media_player.yandex_v\n state: playing\n then:\n - action: media_player.play_media\n entity_id: media_player.yandex_v\n data:\n media_content_id: Включи спят усталые игрушки на повтор\n media_content_type: command", "config": [ { "name": "yandex vova room", "room": "vova_room", "type": "media_player", "id": { "entity_id": "media_player.yandex_v", "device_id": null } }, { "name": "Light 54ef441000d4e7fd", "room": null, "type": "light", "id": { "entity_id": "light.0x54ef441000d4e7fd_light", "device_id": null } }, { "name": "Square LED V", "room": "Vova Room", "type": "light", "id": { "entity_id": "light.square_led_v", "device_id": null } }, { "name": "Square LED V Nightlight", "room": "Vova Room", "type": "light", "id": { "entity_id": "light.square_led_v_nightlight", "device_id": null } }, { "name": "Apple TV V", "room": "Vova Room", "type": "media_player", "id": { "entity_id": "media_player.apple_tv_v", "device_id": null } }, { "name": "Switch Plug 290a093", "room": null, "type": "switch", "id": { "entity_id": "switch.0x00158d000290a093_plug", "device_id": null } } ] }, { "id": "bathroom_washing_machine_washing", "automation": "- alias: bathroom_washing_machine_washing\n id: bathroom_washing_machine_washing\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.washer_b\n from: 'off'\n to: 'on'\n conditions:\n - condition: numeric_state\n entity_id: sensor.ha_uptime\n above: 0\n - condition: state\n entity_id: input_select.washer_state\n state:\n - Idle\n - Drying\n actions:\n - action: input_number.set_value\n data:\n entity_id: input_number.washer_start\n value: '{{as_timestamp (now())|int(0)}}'\n - action: timer.cancel\n entity_id: timer.washer_working\n - action: timer.start\n entity_id: timer.washer_working\n - action: input_select.select_option\n data:\n entity_id: input_select.washer_state\n option: Washing\n - action: notify.telegram\n data:\n message: ⏳ Стирка начата!", "config": [ { "name": "ha uptime", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.ha_uptime", "device_id": null } }, { "name": "Washer B", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.washer_b", "device_id": null } }, { "name": "Washer Start", "room": null, "type": "input_number", "id": { "entity_id": "input_number.washer_start", "device_id": null } }, { "name": "Washer State", "room": null, "type": "input_select", "id": { "entity_id": "input_select.washer_state", "device_id": null } }, { "name": "Washer Working Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.washer_working", "device_id": null } } ] }, { "id": "bathroom_washing_machine_sensors_issue", "automation": "- alias: bathroom_washing_machine_sensors_issue\n id: bathroom_washing_machine_sensors_issue\n initial_state: true\n triggers:\n platform: state\n entity_id: binary_sensor.washer_b\n to: 'on'\n from: 'off'\n for:\n seconds: 5\n conditions:\n - condition: state\n entity_id: binary_sensor.a4c138833042_contact\n state: 'on'\n actions:\n - action: input_boolean.turn_on\n entity_id: input_boolean.washer_door_issue\n - action: notify.telegram\n data:\n message: ❌ Внимание! Обнаружена ошибка сенсора двери стиральной машины!", "config": [ { "name": "Contact Sensor a4c138833042", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.a4c138833042_contact", "device_id": null } }, { "name": "Washer B", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.washer_b", "device_id": null } }, { "name": "Washer Door Issue", "room": null, "type": "input_boolean", "id": { "entity_id": "input_boolean.washer_door_issue", "device_id": null } } ] }, { "id": "bathroom_washing_machine_hatch_open", "automation": "- alias: bathroom_washing_machine_pause_hatch_open\n id: bathroom_washing_machine_hatch_open\n triggers:\n - trigger: state\n entity_id: binary_sensor.a4c138833042_contact\n to: 'on'\n conditions:\n - condition: state\n entity_id: input_select.washer_state\n state:\n - Washing\n - condition: numeric_state\n entity_id: sensor.washing_machine_stopwatch\n below: 21\n actions:\n - action: input_select.select_option\n data:\n entity_id: input_select.washer_state\n option: Pause\n - action: input_boolean.turn_off\n data:\n entity_id: input_boolean.washer_drying\n - action: timer.cancel\n entity_id: timer.washer_working\n - action: notify.telegram\n data_template:\n message: ⏳ Стирка приостановлена", "config": [ { "name": "Contact Sensor a4c138833042", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.a4c138833042_contact", "device_id": null } }, { "name": "Washer Drying", "room": null, "type": "input_boolean", "id": { "entity_id": "input_boolean.washer_drying", "device_id": null } }, { "name": "Washer State", "room": null, "type": "input_select", "id": { "entity_id": "input_select.washer_state", "device_id": null } }, { "name": "Washing Machine Stopwatch", "room": null, "type": "sensor", "id": { "entity_id": "sensor.washing_machine_stopwatch", "device_id": null } }, { "name": "Washer Working Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.washer_working", "device_id": null } } ] }, { "id": "bathroom_washing_machine_hatch_close", "automation": "- alias: bathroom_washing_machine_pause_hatch_close\n id: bathroom_washing_machine_hatch_close\n triggers:\n - trigger: state\n entity_id: binary_sensor.a4c138833042_contact\n to: 'off'\n conditions:\n - condition: state\n entity_id: input_select.washer_state\n state: Pause\n actions:\n - action: input_select.select_option\n data:\n entity_id: input_select.washer_state\n option: Washing\n - action: timer.cancel\n entity_id: timer.washer_working\n - action: timer.start\n entity_id: timer.washer_working\n - action: notify.telegram\n data_template:\n message: ⏳ Стирка продолжена", "config": [ { "name": "Contact Sensor a4c138833042", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.a4c138833042_contact", "device_id": null } }, { "name": "Washer State", "room": null, "type": "input_select", "id": { "entity_id": "input_select.washer_state", "device_id": null } }, { "name": "Washer Working Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.washer_working", "device_id": null } } ] }, { "id": "bathroom_washing_machine_drying", "automation": "- alias: bathroom_washing_machine_drying\n id: bathroom_washing_machine_drying\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.washer_b\n to: 'off'\n from: 'on'\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: binary_sensor.a4c138833042_contact\n state: 'off'\n - condition: state\n entity_id: input_select.washer_state\n state:\n - Washing\n - Pause\n - condition: state\n entity_id: input_boolean.washer_door_issue\n state: 'off'\n sequence:\n - action: timer.cancel\n entity_id: timer.washing_machine_door, timer.washer_working\n - action: timer.start\n entity_id: timer.washing_machine_door\n - action: input_select.select_option\n data:\n entity_id: input_select.washer_state\n option: Drying\n - action: counter.increment\n entity_id: counter.washing_machine_runs\n - action: input_number.set_value\n data:\n entity_id: input_number.washer_b_run_time\n value: '{{ (states(''input_number.washer_b_run_time'') | float(0) + (((as_timestamp(now())|\n int(0) - states(''input_number.washer_start'')| int(0)) / 60 )| round(0,\n ''common'') / 60))|round(2, ''common'') }}'\n - action: input_number.set_value\n data:\n entity_id: input_number.washing_gel_usage\n value: '{% set a = ((as_timestamp(now())| int(0) - states(''input_number.washer_start'')|\n int(0)) / 60 )| round(0, ''common'')|int(0) %} {% set k = (0.02 if 20\n < a < 35 else 0.04) | float(0) %} {{ states(''input_number.washing_gel_usage'')|float(0)\n + (0 if a <20 else k)|float(0) }}\n\n '\n - action: notify.telegram\n data:\n message: ⌛ Стирка завершена! Время стирки составило {{((as_timestamp(now())|\n int(0) - states('input_number.washer_start')| int(0)) / 60 )| round(0,\n 'common') }}мин.\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'on'\n - condition: state\n entity_id: switch.system_dark_mode\n state: 'off'\n - action: media_player.volume_set\n data:\n entity_id: media_player.yandex_k\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id: media_player.yandex_k\n media_content_id: Ст+ирка завершен+а! В+ытащите бель+ё пож+алуста!\n - conditions:\n - condition: state\n entity_id: input_boolean.washer_door_issue\n state: 'on'\n sequence:\n - action: input_select.select_option\n data:\n entity_id: input_select.washer_state\n option: Drying\n - action: timer.cancel\n entity_id: timer.washing_machine_door\n - action: timer.start\n entity_id: timer.washing_machine_door", "config": [ { "name": "yandex kitchen", "room": "kitchen", "type": "media_player", "id": { "entity_id": "media_player.yandex_k", "device_id": null } }, { "name": "system dark mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_dark_mode", "device_id": null } }, { "name": "main volume", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.main_volume", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "alice mode", "room": "system", "type": "input_select", "id": { "entity_id": "input_select.alice_mode", "device_id": null } }, { "name": "Contact Sensor a4c138833042", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.a4c138833042_contact", "device_id": null } }, { "name": "Washer B", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.washer_b", "device_id": null } }, { "name": "Washing Machine Runs", "room": null, "type": "counter", "id": { "entity_id": "counter.washing_machine_runs", "device_id": null } }, { "name": "Washer Door Issue", "room": null, "type": "input_boolean", "id": { "entity_id": "input_boolean.washer_door_issue", "device_id": null } }, { "name": "Washer B Run Time", "room": null, "type": "input_number", "id": { "entity_id": "input_number.washer_b_run_time", "device_id": null } }, { "name": "Washer Start", "room": null, "type": "input_number", "id": { "entity_id": "input_number.washer_start", "device_id": null } }, { "name": "Washing Gel Usage", "room": null, "type": "input_number", "id": { "entity_id": "input_number.washing_gel_usage", "device_id": null } }, { "name": "Washer State", "room": null, "type": "input_select", "id": { "entity_id": "input_select.washer_state", "device_id": null } }, { "name": "Washer Working Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.washer_working", "device_id": null } }, { "name": "Washing Machine Door Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.washing_machine_door", "device_id": null } } ] }, { "id": "bathroom_washing_machine_open_door_after_washing", "automation": "- alias: bathroom_washing_machine_open_door_after_washing\n id: bathroom_washing_machine_open_door_after_washing\n initial_state: true\n triggers:\n - trigger: event\n event_type: timer.finished\n event_data:\n entity_id: timer.washing_machine_door\n conditions:\n - condition: numeric_state\n entity_id: sensor.ha_uptime\n above: 0\n - condition: state\n entity_id: input_select.washer_state\n state: Drying\n - condition: state\n entity_id: binary_sensor.a4c138833042_contact\n state: 'off'\n actions:\n - action: notify.telegram\n data:\n message: '{{''💨''}} Откройте дверцу стиральной машины!'\n - action: timer.cancel\n entity_id: timer.washing_machine_door\n - action: timer.start\n entity_id: timer.washing_machine_door", "config": [ { "name": "ha uptime", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.ha_uptime", "device_id": null } }, { "name": "Contact Sensor a4c138833042", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.a4c138833042_contact", "device_id": null } }, { "name": "Washer State", "room": null, "type": "input_select", "id": { "entity_id": "input_select.washer_state", "device_id": null } }, { "name": "Washing Machine Door Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.washing_machine_door", "device_id": null } } ] }, { "id": "bathroom_washing_machine_ready_notification", "automation": "- alias: bathroom_washing_machine_ready_notification\n id: bathroom_washing_machine_ready_notification\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0002b43ad4_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0001ae9f61_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0002b48381_motion\n - trigger: event\n event_type: xiaomi_aqara.motion\n event_data:\n entity_id: binary_sensor.0x00158d0002b4729d_motion\n conditions:\n - condition: numeric_state\n entity_id: sensor.ha_uptime\n above: 5\n - condition: state\n entity_id: binary_sensor.tod_day\n state: 'on'\n - condition: state\n entity_id: switch.system_dark_mode\n state: 'off'\n - condition: state\n entity_id: input_select.washer_state\n state: Drying\n - condition: state\n entity_id: binary_sensor.a4c138833042_contact\n state: 'off'\n - condition: template\n value_template: '{{(as_timestamp(now())-as_timestamp(state_attr(''automation.bathroom_washing_machine_ready_notification'',\n ''last_triggered''),0)|int(0)) > 30*60 }}'\n - condition: template\n value_template: '{{(as_timestamp(now())-as_timestamp(state_attr(''automation.bathroom_washing_machine_drying'',\n ''last_triggered''),0)|int(0)) > 30*60 }}'\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: media_player.volume_set\n data:\n entity_id: media_player.yandex_k\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id: media_player.yandex_k\n media_content_id: Ст+ирка завершен+а! В+ытащите бель+ё пож+алуста!", "config": [ { "name": "yandex kitchen", "room": "kitchen", "type": "media_player", "id": { "entity_id": "media_player.yandex_k", "device_id": null } }, { "name": "system dark mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_dark_mode", "device_id": null } }, { "name": "main volume", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.main_volume", "device_id": null } }, { "name": "motion sensor kitchen 1", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b4729d_motion", "device_id": null } }, { "name": "motion sensor kitchen 2", "room": "kitchen", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b48381_motion", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } }, { "name": "alice mode", "room": "system", "type": "input_select", "id": { "entity_id": "input_select.alice_mode", "device_id": null } }, { "name": "ha uptime", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.ha_uptime", "device_id": null } }, { "name": "hall small motion sensor 1", "room": "hall_small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0001ae9f61_motion", "device_id": null } }, { "name": "hall small motion sensor 2", "room": "hall_small", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002b43ad4_motion", "device_id": null } }, { "name": "Contact Sensor a4c138833042", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.a4c138833042_contact", "device_id": null } }, { "name": "Washer State", "room": null, "type": "input_select", "id": { "entity_id": "input_select.washer_state", "device_id": null } } ] }, { "id": "bathroom_washing_machine_open_door_after_washing_stop", "automation": "- alias: bathroom_washing_machine_open_door_after_washing_stop\n id: bathroom_washing_machine_open_door_after_washing_stop\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.a4c138833042_contact\n to: 'on'\n from: 'off'\n conditions:\n - condition: numeric_state\n entity_id: sensor.ha_uptime\n above: 0\n - condition: state\n entity_id: input_select.washer_state\n state: Drying\n actions:\n - action: notify.telegram\n data:\n message: '{{''✅''}} Дверца стиральной машинки открыта!'\n - action: timer.cancel\n entity_id: timer.washing_machine_door, timer.washing_machine_door\n - action: input_boolean.turn_off\n entity_id: input_boolean.washer_door_issue\n - action: input_select.select_option\n data:\n entity_id: input_select.washer_state\n option: Idle", "config": [ { "name": "ha uptime", "room": "system", "type": "sensor", "id": { "entity_id": "sensor.ha_uptime", "device_id": null } }, { "name": "Contact Sensor a4c138833042", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.a4c138833042_contact", "device_id": null } }, { "name": "Washer Door Issue", "room": null, "type": "input_boolean", "id": { "entity_id": "input_boolean.washer_door_issue", "device_id": null } }, { "name": "Washer State", "room": null, "type": "input_select", "id": { "entity_id": "input_select.washer_state", "device_id": null } }, { "name": "Washing Machine Door Timer", "room": null, "type": "timer", "id": { "entity_id": "timer.washing_machine_door", "device_id": null } } ] }, { "id": "bathroom_washing_machine_open_door_issue_flag_reset", "automation": "- alias: bathroom_washing_machine_open_door_issue_flag_reset\n id: bathroom_washing_machine_open_door_issue_flag_reset\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.a4c138833042_contact\n to:\n - 'on'\n - 'off'\n conditions:\n - condition: state\n entity_id: input_boolean.washer_door_issue\n state: 'on'\n actions:\n - action: input_boolean.turn_off\n entity_id: input_boolean.washer_door_issue", "config": [ { "name": "Contact Sensor a4c138833042", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.a4c138833042_contact", "device_id": null } }, { "name": "Washer Door Issue", "room": null, "type": "input_boolean", "id": { "entity_id": "input_boolean.washer_door_issue", "device_id": null } } ] }, { "id": "bathroom_washing_machine_idle_door_open_10m", "automation": "- alias: bathroom_washing_machine_idle_door_open_10m\n id: bathroom_washing_machine_idle_door_open_10m\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.a4c138833042_contact\n from: 'off'\n to: 'on'\n for:\n minutes: 30\n actions:\n - action: input_select.select_option\n data:\n entity_id: input_select.washer_state\n option: Idle", "config": [ { "name": "Contact Sensor a4c138833042", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.a4c138833042_contact", "device_id": null } }, { "name": "Washer State", "room": null, "type": "input_select", "id": { "entity_id": "input_select.washer_state", "device_id": null } } ] }, { "id": "system_water_leak_detected", "automation": "- alias: system_water_leak_detected\n id: system_water_leak_detected\n initial_state: true\n mode: queued\n max: 10\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id:\n - binary_sensor.0x00158d00023297e7_moisture\n - binary_sensor.0x00158d00023684c2_moisture\n - binary_sensor.0x00158d0002373a67_moisture\n - binary_sensor.0x00158d0002349f5b_moisture\n - binary_sensor.54ef44c335f4_water_leak\n to: 'on'\n for:\n seconds: 5\n actions:\n - action: light.turn_on\n data:\n entity_id: '{% if trigger.entity_id==\"binary_sensor.0x00158d00023297e7_moisture\"\n or trigger.entity_id==\"binary_sensor.54ef44c335f4_water_leak\" %}light.esp32_node_k_led\n {%elif trigger.entity_id==\"binary_sensor.0x00158d00023684c2_moisture\"%}light.esp32_node_hs_toilet\n {%else%}light.esp32_node_hs_bathroom {%endif%}\n\n '\n effect: Red_Alarm\n brightness: 255\n - action: media_player.volume_set\n data:\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'\n - parallel:\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n media_content_id: Вним+ание! Вним+ание! Обнар+ужена ут+ечка вод+ы {% if trigger.entity_id==\"binary_sensor.0x00158d00023297e7_moisture\"%}н+а\n к+ухне{%elif trigger.entity_id==\"binary_sensor.54ef44c335f4_water_leak\"%}под\n кухонной мебелью{%elif trigger.entity_id==\"binary_sensor.0x00158d00023684c2_moisture\"%}в\n туал+ете{%else%}в ванне{%if trigger.entity_id==\"binary_sensor.0x00158d0002349f5b_moisture\"%}\n за машинкой{%endif%}{%endif%}! Обнар+ужена ут+ечка вод+ы {% if trigger.entity_id==\"binary_sensor.0x00158d00023297e7_moisture\"%}н+а\n к+ухне{%elif trigger.entity_id==\"binary_sensor.0x00158d00023684c2_moisture\"%}в\n туал+ете{%else%}в ванне{%if trigger.entity_id==\"binary_sensor.0x00158d0002349f5b_moisture\"%}\n за машинкой{%endif%}{%endif%}! Вод+а перекрыв+ается!'\n - action: notify.telegram\n data:\n message: '{{''\\U000026d4''}}Внимание! Обнаружена утечка воды {% if trigger.entity_id==\"binary_sensor.0x00158d00023297e7_moisture\"%}на\n кухне{%elif trigger.entity_id==\"binary_sensor.54ef44c335f4_water_leak\"%}под\n кухонной мебелью{%elif trigger.entity_id==\"binary_sensor.0x00158d00023684c2_moisture\"%}в\n туалете{%else%}в ванне{%if trigger.entity_id==\"binary_sensor.0x00158d0002349f5b_moisture\"%}\n за машинкой{%endif%}{%endif%}! Вода перекрывается!'\n - action: notify.mobile_app_iphone_16_pro_dima\n data:\n message: '{{''\\U000026d4''}}Внимание! Обнаружена утечка воды {% if trigger.entity_id==\"binary_sensor.0x00158d00023297e7_moisture\"%}на\n кухне{%elif trigger.entity_id==\"binary_sensor.54ef44c335f4_water_leak\"%}под\n кухонной мебелью{%elif trigger.entity_id==\"binary_sensor.0x00158d00023684c2_moisture\"%}в\n туалете{%else%}в ванне{%if trigger.entity_id==\"binary_sensor.0x00158d0002349f5b_moisture\"%}\n за машинкой{%endif%}{%endif%}! Вода перекрывается!'\n data:\n push:\n sound:\n name: default\n critical: 1\n volume: 1.0\n - action: button.press\n entity_id: button.esp32_node_b_close_valve\n - delay: 00:00:25\n - action: switch.turn_off\n entity_id: switch.esp32_node_b_relay_1\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n media_content_id: '''Вним+ание! Вод+а перекр+ыта! Устран+ите прот+ечку вод+ы\n {% if trigger.entity_id==\"binary_sensor.0x00158d00023297e7_moisture\"%}н+а\n к+ухне{%elif trigger.entity_id==\"binary_sensor.54ef44c335f4_water_leak\"%}под\n кухонной мебелью{%elif trigger.entity_id==\"binary_sensor.0x00158d00023684c2_moisture\"%}в\n туал+ете{%else%}в ванне{%if trigger.entity_id==\"binary_sensor.0x00158d0002349f5b_moisture\"%}\n за машинкой{%endif%}{%endif%}!'''\n - action: notify.telegram\n data:\n message: '{{''\\U000026d4''}} Внимание! Вода перекрыта! Устраните протечку воды\n {% if trigger.entity_id==\"binary_sensor.0x00158d00023297e7_moisture\"%}на кухне{%elif\n trigger.entity_id==\"binary_sensor.54ef44c335f4_water_leak\"%}под кухонной мебелью{%elif\n trigger.entity_id==\"binary_sensor.0x00158d00023684c2_moisture\"%}в туалете{%else%}в\n ванне{%if trigger.entity_id==\"binary_sensor.0x00158d0002349f5b_moisture\"%}\n за машинкой{%endif%}{%endif%} для включения воды!\n\n '", "config": [ { "name": "yandex kitchen", "room": "kitchen", "type": "media_player", "id": { "entity_id": "media_player.yandex_k", "device_id": null } }, { "name": "esp32 node k led", "room": "kitchen", "type": "light", "id": { "entity_id": "light.esp32_node_k_led", "device_id": null } }, { "name": "main volume", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.main_volume", "device_id": null } }, { "name": "alice mode", "room": "system", "type": "input_select", "id": { "entity_id": "input_select.alice_mode", "device_id": null } }, { "name": "esp32 node hs bathroom", "room": "bathroom", "type": "light", "id": { "entity_id": "light.esp32_node_hs_bathroom", "device_id": null } }, { "name": "Moisture Sensor 23297e7", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d00023297e7_moisture", "device_id": null } }, { "name": "Moisture Sensor 2349f5b", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002349f5b_moisture", "device_id": null } }, { "name": "Moisture Sensor 23684c2", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d00023684c2_moisture", "device_id": null } }, { "name": "Moisture Sensor 2373a67", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002373a67_moisture", "device_id": null } }, { "name": "Water Leak Sensor 54ef44c335f4", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.54ef44c335f4_water_leak", "device_id": null } }, { "name": "ESP32 Node B Close Valve", "room": "Bathroom", "type": "button", "id": { "entity_id": "button.esp32_node_b_close_valve", "device_id": null } }, { "name": "Main Audio Out", "room": null, "type": "input_select", "id": { "entity_id": "input_select.main_audio_out", "device_id": null } }, { "name": "ESP32 Node HS Toilet", "room": "Hall Small", "type": "light", "id": { "entity_id": "light.esp32_node_hs_toilet", "device_id": null } }, { "name": "ESP32 Node B Relay 1", "room": "Bathroom", "type": "switch", "id": { "entity_id": "switch.esp32_node_b_relay_1", "device_id": null } } ] }, { "id": "system_water_leak_resolved", "automation": "- alias: system_water_leak_resolved\n id: system_water_leak_resolved\n initial_state: true\n mode: queued\n max: 10\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id:\n - binary_sensor.0x00158d00023297e7_moisture\n - binary_sensor.0x00158d00023684c2_moisture\n - binary_sensor.0x00158d0002373a67_moisture\n - binary_sensor.0x00158d0002349f5b_moisture\n - binary_sensor.54ef44c335f4_water_leak\n to: 'off'\n from: 'on'\n for:\n seconds: 3\n actions:\n - action: homeassistant.turn_off\n data:\n entity_id: \"{% if trigger.entity_id==\\\"binary_sensor.0x00158d00023297e7_moisture\\\"\\\n %}light.esp32_node_k_led {%elif trigger.entity_id==\\\"binary_sensor.0x00158d00023684c2_moisture\\\"\\\n %}light.esp32_node_hs_toilet {%else%}light.esp32_node_hs_bathroom {%endif%}\\\n \\ \\n\"\n - action: media_player.volume_set\n data:\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n media_content_id: '''Прот+ечка вод+ы {% if trigger.entity_id==\"binary_sensor.0x00158d00023297e7_moisture\"%}н+а\n к+ухне{%elif trigger.entity_id==\"binary_sensor.54ef44c335f4_water_leak\"%}под\n кухонной мебелью{%elif trigger.entity_id==\"binary_sensor.0x00158d00023684c2_moisture\"%}в\n туал+ете{%else%}в ванне{%if trigger.entity_id==\"binary_sensor.0x00158d0002349f5b_moisture\"%}\n за машинкой{%endif%}{%endif%} устранен+а! Спас+ибо!'''\n - action: notify.telegram\n data:\n message: '{{''\\U00002705''}} Протечка воды {% if trigger.entity_id==\"binary_sensor.0x00158d00023297e7_moisture\"%}на\n кухне{%elif trigger.entity_id==\"binary_sensor.54ef44c335f4_water_leak\"%}под\n кухонной мебелью{%elif trigger.entity_id==\"binary_sensor.0x00158d00023684c2_moisture\"%}в\n туалете{%else%}в ванне{%if trigger.entity_id==\"binary_sensor.0x00158d0002349f5b_moisture\"%}\n за машинкой{%endif%}{%endif%} устранена!\n\n '", "config": [ { "name": "yandex kitchen", "room": "kitchen", "type": "media_player", "id": { "entity_id": "media_player.yandex_k", "device_id": null } }, { "name": "esp32 node k led", "room": "kitchen", "type": "light", "id": { "entity_id": "light.esp32_node_k_led", "device_id": null } }, { "name": "main volume", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.main_volume", "device_id": null } }, { "name": "alice mode", "room": "system", "type": "input_select", "id": { "entity_id": "input_select.alice_mode", "device_id": null } }, { "name": "esp32 node hs bathroom", "room": "bathroom", "type": "light", "id": { "entity_id": "light.esp32_node_hs_bathroom", "device_id": null } }, { "name": "Moisture Sensor 23297e7", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d00023297e7_moisture", "device_id": null } }, { "name": "Moisture Sensor 2349f5b", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002349f5b_moisture", "device_id": null } }, { "name": "Moisture Sensor 23684c2", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d00023684c2_moisture", "device_id": null } }, { "name": "Moisture Sensor 2373a67", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.0x00158d0002373a67_moisture", "device_id": null } }, { "name": "Water Leak Sensor 54ef44c335f4", "room": null, "type": "binary_sensor", "id": { "entity_id": "binary_sensor.54ef44c335f4_water_leak", "device_id": null } }, { "name": "Main Audio Out", "room": null, "type": "input_select", "id": { "entity_id": "input_select.main_audio_out", "device_id": null } }, { "name": "ESP32 Node HS Toilet", "room": "Hall Small", "type": "light", "id": { "entity_id": "light.esp32_node_hs_toilet", "device_id": null } } ] }, { "id": "system_water_leak_turn_water_off", "automation": "- alias: system_water_leak_turn_water_off\n id: system_water_leak_turn_water_off\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0001ef609b_action\n click_type: single\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: binary_sensor.esp32_node_b_valve_status\n state: 'off'\n sequence:\n - action: media_player.volume_set\n data:\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n media_content_id: '''Действие не трубуется - краны уже закрыты!'''\n - conditions:\n - not:\n - condition: state\n entity_id: binary_sensor.esp32_node_b_valve_status\n state: 'off'\n sequence:\n - action: media_player.volume_set\n data:\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n media_content_id: '''Вним+ание! Зап+ущена процедура выключ+ения вод+ы!'''\n - action: notify.telegram\n data:\n message: Внимание! Запущена процедура принудительного закрытия воды!\n - action: button.press\n entity_id: button.esp32_node_b_close_valve\n - delay: 00:00:25\n - action: switch.turn_off\n entity_id: switch.esp32_node_b_relay_1\n - action: media_player.volume_set\n data:\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n media_content_id: '''Внимание! Вода выключена!'''\n - action: notify.telegram\n data:\n message: Внимание! Вода принидительно закрыта!", "config": [ { "name": "yandex kitchen", "room": "kitchen", "type": "media_player", "id": { "entity_id": "media_player.yandex_k", "device_id": null } }, { "name": "main volume", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.main_volume", "device_id": null } }, { "name": "alice mode", "room": "system", "type": "input_select", "id": { "entity_id": "input_select.alice_mode", "device_id": null } }, { "name": "ESP32 Node B Valve Status", "room": "Bathroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_node_b_valve_status", "device_id": null } }, { "name": "ESP32 Node B Close Valve", "room": "Bathroom", "type": "button", "id": { "entity_id": "button.esp32_node_b_close_valve", "device_id": null } }, { "name": "Main Audio Out", "room": null, "type": "input_select", "id": { "entity_id": "input_select.main_audio_out", "device_id": null } }, { "name": "Action Sensor 1ef609b", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x00158d0001ef609b_action", "device_id": null } }, { "name": "ESP32 Node B Relay 1", "room": "Bathroom", "type": "switch", "id": { "entity_id": "switch.esp32_node_b_relay_1", "device_id": null } } ] }, { "id": "system_water_leak_turn_water_on", "automation": "- alias: system_water_leak_turn_water_on\n id: system_water_leak_turn_water_on\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0001ef609b_action\n click_type: double\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: state\n entity_id: group.leak_detected\n state: 'off'\n actions:\n - choose:\n - conditions:\n - condition: state\n entity_id: binary_sensor.esp32_node_b_valve_status\n state: 'on'\n sequence:\n - action: media_player.volume_set\n data:\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n media_content_id: '''Действие не трубуется - краны уже открыты!'''\n - conditions:\n - not:\n - condition: state\n entity_id: binary_sensor.esp32_node_b_valve_status\n state: 'on'\n sequence:\n - action: media_player.volume_set\n data:\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n media_content_id: '''Вним+ание! Запущена процедура включ+ения вод+ы!'''\n - action: notify.telegram\n data:\n message: Внимание! Запущена процедура принудительного включения воды!\n - action: button.press\n entity_id: button.esp32_node_b_open_valve\n - delay: 00:00:25\n - action: switch.turn_off\n entity_id: switch.esp32_node_b_relay_2\n - action: media_player.volume_set\n data:\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n media_content_id: '''Вним+ание! Вода включена!'''\n - action: notify.telegram\n data:\n message: Внимание! Вода принидительно открыта!", "config": [ { "name": "yandex kitchen", "room": "kitchen", "type": "media_player", "id": { "entity_id": "media_player.yandex_k", "device_id": null } }, { "name": "main volume", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.main_volume", "device_id": null } }, { "name": "alice mode", "room": "system", "type": "input_select", "id": { "entity_id": "input_select.alice_mode", "device_id": null } }, { "name": "ESP32 Node B Valve Status", "room": "Bathroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_node_b_valve_status", "device_id": null } }, { "name": "ESP32 Node B Open Valve", "room": "Bathroom", "type": "button", "id": { "entity_id": "button.esp32_node_b_open_valve", "device_id": null } }, { "name": "Leak Detected Group", "room": null, "type": "group", "id": { "entity_id": "group.leak_detected", "device_id": null } }, { "name": "Main Audio Out", "room": null, "type": "input_select", "id": { "entity_id": "input_select.main_audio_out", "device_id": null } }, { "name": "Action Sensor 1ef609b", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x00158d0001ef609b_action", "device_id": null } }, { "name": "ESP32 Node B Relay 2", "room": "Bathroom", "type": "switch", "id": { "entity_id": "switch.esp32_node_b_relay_2", "device_id": null } } ] }, { "id": "system_water_leak_turn_water_on_leak_detected", "automation": "- alias: system_water_leak_turn_water_on_leak_detected\n id: system_water_leak_turn_water_on_leak_detected\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0001ef609b_action\n click_type: double\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n - condition: state\n entity_id: group.leak_detected\n state: 'on'\n actions:\n - action: media_player.volume_set\n data:\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n media_content_id: '''Вним+ание! Включ+ение вод+ы невозм+ожно! Прот+ечка н+е\n устранен+а! Дл+я принуд+ительного включ+ения вод+ы нажм+ите и удерживайте\n кнопку!'''\n - action: notify.telegram\n data:\n message: Внимание! Попытка открыть воду, протечка НЕ устранена!", "config": [ { "name": "yandex kitchen", "room": "kitchen", "type": "media_player", "id": { "entity_id": "media_player.yandex_k", "device_id": null } }, { "name": "main volume", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.main_volume", "device_id": null } }, { "name": "alice mode", "room": "system", "type": "input_select", "id": { "entity_id": "input_select.alice_mode", "device_id": null } }, { "name": "Leak Detected Group", "room": null, "type": "group", "id": { "entity_id": "group.leak_detected", "device_id": null } }, { "name": "Main Audio Out", "room": null, "type": "input_select", "id": { "entity_id": "input_select.main_audio_out", "device_id": null } }, { "name": "Action Sensor 1ef609b", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x00158d0001ef609b_action", "device_id": null } } ] }, { "id": "system_water_leak_turn_water_on_force", "automation": "- alias: system_water_leak_turn_water_on_force\n id: system_water_leak_turn_water_on_force\n initial_state: true\n triggers:\n - trigger: event\n event_type: xiaomi_aqara.click\n event_data:\n entity_id: sensor.0x00158d0001ef609b_action\n click_type: hold\n conditions:\n - condition: template\n value_template: '{{ is_state_attr(this.entity_id, ''current'',0) }}'\n actions:\n - action: media_player.volume_set\n data:\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n media_content_id: '''Вним+ание! {{ iif(is_state(\"group.leak_detected\", \"on\"),\n \"Прот+ечка вод+ы н+е устранен+а! \", \"\") }}Зап+ущена процедура принуд+ительного\n включ+ения вод+ы!'''\n - action: notify.telegram\n data:\n message: Внимание! {{ iif(is_state(\"group.leak_detected\", \"on\"), \"Протечка воды\n не устранена! \", \"\") }}Запущена процедура принудительного включения воды!\n - action: button.press\n entity_id: button.esp32_node_b_open_valve\n - delay: 00:00:25\n - action: switch.turn_off\n entity_id: switch.esp32_node_b_relay_2\n - action: media_player.volume_set\n data:\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id:\n - media_player.{{states('input_select.main_audio_out')|lower}}\n - media_player.yandex_k\n media_content_id: '''Вним+ание! Вод+а включен+а! {{ iif(is_state(\"group.leak_detected\",\n \"on\"), \"Прот+ечка н+е устранен+а! \", \"\") }}'''\n - action: notify.telegram\n data:\n message: Внимание! Вода включена! {{ iif(is_state(\"group.leak_detected\", \"on\"),\n \"Протечка НЕ устранена!\", \"\") }}", "config": [ { "name": "yandex kitchen", "room": "kitchen", "type": "media_player", "id": { "entity_id": "media_player.yandex_k", "device_id": null } }, { "name": "main volume", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.main_volume", "device_id": null } }, { "name": "alice mode", "room": "system", "type": "input_select", "id": { "entity_id": "input_select.alice_mode", "device_id": null } }, { "name": "ESP32 Node B Open Valve", "room": "Bathroom", "type": "button", "id": { "entity_id": "button.esp32_node_b_open_valve", "device_id": null } }, { "name": "Leak Detected Group", "room": null, "type": "group", "id": { "entity_id": "group.leak_detected", "device_id": null } }, { "name": "Main Audio Out", "room": null, "type": "input_select", "id": { "entity_id": "input_select.main_audio_out", "device_id": null } }, { "name": "Action Sensor 1ef609b", "room": null, "type": "sensor", "id": { "entity_id": "sensor.0x00158d0001ef609b_action", "device_id": null } }, { "name": "ESP32 Node B Relay 2", "room": "Bathroom", "type": "switch", "id": { "entity_id": "switch.esp32_node_b_relay_2", "device_id": null } } ] }, { "id": "system_water_valves_action", "automation": "- alias: system_water_valves_action\n id: system_water_valves_action\n initial_state: true\n triggers:\n - trigger: state\n entity_id: binary_sensor.esp32_node_b_valve_active\n to: null\n conditions:\n - condition: template\n value_template: \"{% set ignore = ['unknown', 'unavailable', 'none','0'] %} {{\\\n \\ trigger.from_state.state not in ignore and\\n trigger.to_state.state not in\\\n \\ ignore and\\n trigger.to_state.state != trigger.from_state.state }}\\n\"\n actions:\n - action: notify.telegram\n data:\n message: '{%- set current_state = states(''binary_sensor.esp32_node_b_valve_status'')\n %} {%- set current_status = states(''binary_sensor.esp32_node_b_valve_active'')\n %} {%- if current_state == ''on'' and current_status == ''on'' %}{{''\\U000026d4''}}\n Внимание! Закрытие кранов! {%- elif current_state == ''off'' and current_status\n == ''off'' %}{{''\\U00002705''}} Краны закрыты! {%- elif current_state == ''off''\n and current_status == ''on'' %}{{''\\U000026d4''}} Внимание! Открытие кранов!\n {%- elif current_state == ''on'' and current_status == ''off'' %}{{''\\U00002705''}}\n Краны открыты! {%- endif %}'", "config": [ { "name": "ESP32 Node B Valve Active", "room": "Bathroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_node_b_valve_active", "device_id": null } }, { "name": "ESP32 Node B Valve Status", "room": "Bathroom", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.esp32_node_b_valve_status", "device_id": null } } ] }, { "id": "system_critical_wifi_devices_unavailable", "automation": "- alias: system_critical_wifi_devices_unavailable\n id: system_critical_wifi_devices_unavailable\n initial_state: true\n mode: queued\n max_exceeded: silent\n max: 25\n triggers:\n - trigger: state\n entity_id:\n - light.square_led_v\n - light.square_led_s\n - light.round_led_mb\n - light.round_led_k\n - light.round_led_hs\n - switch.shelly_1_led_mb\n - switch.shelly_1pm_led_v\n - fan.purifier2s\n - switch.ms01a_plug_hb\n - switch.ms01b_plug_hb\n - switch.pbs100_plug_st\n - switch.shelly_1_led_s\n - light.light_bar_s\n to: unavailable\n for:\n minutes: 1\n actions:\n - action: notify.telegram\n data:\n message: '❌ {{trigger.to_state.name|title}}: {{trigger.from_state.state}} ->\n {{trigger.to_state.state}}'", "config": [ { "name": "round led k", "room": "kitchen", "type": "light", "id": { "entity_id": "light.round_led_k", "device_id": null } }, { "name": "round led hs", "room": "hall_small", "type": "light", "id": { "entity_id": "light.round_led_hs", "device_id": null } }, { "name": "round led mb", "room": "master_bedroom", "type": "light", "id": { "entity_id": "light.round_led_mb", "device_id": null } }, { "name": "shelly 1 led mb", "room": "master_bedroom", "type": "switch", "id": { "entity_id": "switch.shelly_1_led_mb", "device_id": null } }, { "name": "square led s", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.square_led_s", "device_id": null } }, { "name": "shelly 1 led s", "room": "sasha_room", "type": "switch", "id": { "entity_id": "switch.shelly_1_led_s", "device_id": null } }, { "name": "Purifier2s Fan", "room": null, "type": "fan", "id": { "entity_id": "fan.purifier2s", "device_id": null } }, { "name": "Light Bar S", "room": "Sasha Room", "type": "light", "id": { "entity_id": "light.light_bar_s", "device_id": null } }, { "name": "Square LED V", "room": "Vova Room", "type": "light", "id": { "entity_id": "light.square_led_v", "device_id": null } }, { "name": "MS01A Plug HB", "room": "Hall Big", "type": "switch", "id": { "entity_id": "switch.ms01a_plug_hb", "device_id": null } }, { "name": "MS01B Plug HB", "room": "Hall Big", "type": "switch", "id": { "entity_id": "switch.ms01b_plug_hb", "device_id": null } }, { "name": "PBS100 Plug St", "room": null, "type": "switch", "id": { "entity_id": "switch.pbs100_plug_st", "device_id": null } }, { "name": "Shelly 1PM LED V", "room": "Vova Room", "type": "switch", "id": { "entity_id": "switch.shelly_1pm_led_v", "device_id": null } } ] }, { "id": "system_critical_wifi_devices_available", "automation": "- alias: system_critical_wifi_devices_available\n id: system_critical_wifi_devices_available\n initial_state: true\n max_exceeded: silent\n max: 25\n triggers:\n - trigger: state\n entity_id:\n - light.square_led_v\n - light.square_led_s\n - light.round_led_mb\n - light.round_led_k\n - light.round_led_hs\n - switch.shelly_1_led_mb\n - switch.shelly_1pm_led_v\n - fan.purifier2s\n - switch.ms01a_plug_hb\n - switch.ms01b_plug_hb\n - switch.pbs100_plug_st\n - switch.shelly_1_led_s\n - light.light_bar_s\n from: unavailable\n conditions:\n - condition: template\n value_template: '{{(trigger.to_state.last_changed - trigger.from_state.last_changed).total_seconds()\n > 60 }}'\n actions:\n - action: notify.telegram\n data:\n message: '✅ {{trigger.to_state.name|title}}: {{trigger.from_state.state}} ->\n {{trigger.to_state.state}}'", "config": [ { "name": "round led k", "room": "kitchen", "type": "light", "id": { "entity_id": "light.round_led_k", "device_id": null } }, { "name": "round led hs", "room": "hall_small", "type": "light", "id": { "entity_id": "light.round_led_hs", "device_id": null } }, { "name": "round led mb", "room": "master_bedroom", "type": "light", "id": { "entity_id": "light.round_led_mb", "device_id": null } }, { "name": "shelly 1 led mb", "room": "master_bedroom", "type": "switch", "id": { "entity_id": "switch.shelly_1_led_mb", "device_id": null } }, { "name": "square led s", "room": "sasha_room", "type": "light", "id": { "entity_id": "light.square_led_s", "device_id": null } }, { "name": "shelly 1 led s", "room": "sasha_room", "type": "switch", "id": { "entity_id": "switch.shelly_1_led_s", "device_id": null } }, { "name": "Purifier2s Fan", "room": null, "type": "fan", "id": { "entity_id": "fan.purifier2s", "device_id": null } }, { "name": "Light Bar S", "room": "Sasha Room", "type": "light", "id": { "entity_id": "light.light_bar_s", "device_id": null } }, { "name": "Square LED V", "room": "Vova Room", "type": "light", "id": { "entity_id": "light.square_led_v", "device_id": null } }, { "name": "MS01A Plug HB", "room": "Hall Big", "type": "switch", "id": { "entity_id": "switch.ms01a_plug_hb", "device_id": null } }, { "name": "MS01B Plug HB", "room": "Hall Big", "type": "switch", "id": { "entity_id": "switch.ms01b_plug_hb", "device_id": null } }, { "name": "PBS100 Plug St", "room": null, "type": "switch", "id": { "entity_id": "switch.pbs100_plug_st", "device_id": null } }, { "name": "Shelly 1PM LED V", "room": "Vova Room", "type": "switch", "id": { "entity_id": "switch.shelly_1pm_led_v", "device_id": null } } ] }, { "id": "system_critical_switches_toggle", "automation": "- alias: system_critical_switches_toggle\n id: system_critical_switches_toggle\n initial_state: true\n max_exceeded: silent\n mode: queued\n max: 10\n triggers:\n - trigger: state\n entity_id:\n - switch.0x00158d00023e5812_outlet\n - switch.esp32_node_b_relay_5\n - switch.shelly_1_led_s\n - switch.digma_strip_hb_relay1\n - switch.digma_strip_hb_relay2\n - switch.digma_strip_hb_relay3\n - switch.digma_strip_hb_relay4\n - switch.0x00158d00039bd56d_plug\n - switch.0x00158d0002a36433_channel_1\n - switch.0x00158d0002a36f7f_channel_2\n - switch.shelly_1_led_mb\n - switch.shelly_1pm_led_v\n - switch.0x00158d0001a248e3_channel_2\n - switch.0x00158d0001f26071_outlet\n to: 'off'\n for:\n seconds: 30\n actions:\n - action: switch.turn_on\n data:\n entity_id: '{{ trigger.entity_id }}'\n - action: notify.telegram\n data:\n message: ✅ Включение - {{trigger.to_state.name|title}}", "config": [ { "name": "esp32 node b relay 5", "room": "bathroom", "type": "switch", "id": { "entity_id": "switch.esp32_node_b_relay_5", "device_id": null } }, { "name": "zigbee outlet led strip", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.0x00158d00023e5812_outlet", "device_id": null } }, { "name": "digma strip hb relay1", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.digma_strip_hb_relay1", "device_id": null } }, { "name": "bedside plug", "room": "hall_big", "type": "switch", "id": { "entity_id": "switch.0x00158d00039bd56d_plug", "device_id": null } }, { "name": "round led hs channel 1", "room": "hall_small", "type": "switch", "id": { "entity_id": "switch.0x00158d0002a36433_channel_1", "device_id": null } }, { "name": "round led k channel 2", "room": "kitchen", "type": "switch", "id": { "entity_id": "switch.0x00158d0002a36f7f_channel_2", "device_id": null } }, { "name": "shelly 1 led mb", "room": "master_bedroom", "type": "switch", "id": { "entity_id": "switch.shelly_1_led_mb", "device_id": null } }, { "name": "shelly 1 led s", "room": "sasha_room", "type": "switch", "id": { "entity_id": "switch.shelly_1_led_s", "device_id": null } }, { "name": "Switch Channel 2 1a248e3", "room": null, "type": "switch", "id": { "entity_id": "switch.0x00158d0001a248e3_channel_2", "device_id": null } }, { "name": "Switch Outlet 1f26071", "room": null, "type": "switch", "id": { "entity_id": "switch.0x00158d0001f26071_outlet", "device_id": null } }, { "name": "Digma Strip HB Relay2", "room": "Hall Big", "type": "switch", "id": { "entity_id": "switch.digma_strip_hb_relay2", "device_id": null } }, { "name": "Digma Strip HB Relay3", "room": "Hall Big", "type": "switch", "id": { "entity_id": "switch.digma_strip_hb_relay3", "device_id": null } }, { "name": "Digma Strip HB Relay4", "room": "Hall Big", "type": "switch", "id": { "entity_id": "switch.digma_strip_hb_relay4", "device_id": null } }, { "name": "Shelly 1PM LED V", "room": "Vova Room", "type": "switch", "id": { "entity_id": "switch.shelly_1pm_led_v", "device_id": null } } ] }, { "id": "system_ya_speakers_volume_set", "automation": "- alias: system_ya_speakers_volume_set\n id: system_ya_speakers_volume_set\n initial_state: true\n max_exceeded: silent\n triggers:\n - trigger: state\n entity_id: binary_sensor.tod_day\n to: 'on'\n for:\n seconds: 30\n - trigger: state\n entity_id: switch.system_dark_mode\n to: 'off'\n for:\n seconds: 30\n actions:\n - repeat:\n for_each:\n - media_player.yandex_k\n - media_player.yandex_hb\n - media_player.yandex_v\n - media_player.yandex_s\n - media_player.yandex_mb\n sequence:\n - action: media_player.volume_set\n data:\n entity_id: '{{ repeat.item }}'\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'\n - action: media_player.volume_set\n data:\n entity_id: media_player.yandex_hb\n volume_level: '{{(states(\"input_number.main_volume\")|float(0) + 0.2)|round(2)\n }}'", "config": [ { "name": "yandex kitchen", "room": "kitchen", "type": "media_player", "id": { "entity_id": "media_player.yandex_k", "device_id": null } }, { "name": "yandex vova room", "room": "vova_room", "type": "media_player", "id": { "entity_id": "media_player.yandex_v", "device_id": null } }, { "name": "yandex sasha room", "room": "sasha_room", "type": "media_player", "id": { "entity_id": "media_player.yandex_s", "device_id": null } }, { "name": "yandex master bedroom", "room": "master_bedroom", "type": "media_player", "id": { "entity_id": "media_player.yandex_mb", "device_id": null } }, { "name": "yandex hall big", "room": "hall_big", "type": "media_player", "id": { "entity_id": "media_player.yandex_hb", "device_id": null } }, { "name": "system dark mode", "room": "system", "type": "switch", "id": { "entity_id": "switch.system_dark_mode", "device_id": null } }, { "name": "main volume", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.main_volume", "device_id": null } }, { "name": "tod day", "room": "system", "type": "binary_sensor", "id": { "entity_id": "binary_sensor.tod_day", "device_id": null } } ] }, { "id": "system_when_daddy_get_back_home", "automation": "- alias: system_when_daddy_get_back_home\n id: system_when_daddy_get_back_home\n initial_state: true\n triggers:\n - trigger: event\n event_type: yandex_intent\n event_data:\n text: Когда папа вернется\n actions:\n - if:\n - condition: state\n entity_id: input_boolean.dima_business_trip\n state: 'off'\n then:\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id: '{{ trigger.event.data.entity_id }}'\n media_content_id: Папа дома и пока не уезжает в командировку\n extra:\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'\n else:\n - action: media_player.play_media\n data:\n media_content_type: '{{ states(''input_select.alice_mode'') }}'\n entity_id: '{{ trigger.event.data.entity_id }}'\n media_content_id: '{{[''Папа вернется через'',''Папа приедет через'',''Через'',''Папа\n вернется из командировки через'']|random}} {{ (states(''input_datetime.dima_return_date'')\n | as_datetime | as_local - today_at()).days|format(morph=''день'', as_text=false)\n }}'\n extra:\n volume_level: '{{states(\"input_number.main_volume\")|float(0)}}'", "config": [ { "name": "main volume", "room": "system", "type": "input_number", "id": { "entity_id": "input_number.main_volume", "device_id": null } }, { "name": "alice mode", "room": "system", "type": "input_select", "id": { "entity_id": "input_select.alice_mode", "device_id": null } }, { "name": "Dima Business Trip", "room": null, "type": "input_boolean", "id": { "entity_id": "input_boolean.dima_business_trip", "device_id": null } }, { "name": "Dima Return Date", "room": null, "type": "input_datetime", "id": { "entity_id": "input_datetime.dima_return_date", "device_id": null } } ] }, { "id": "system_ya_speaker_k_volume_set", "automation": "- alias: system_ya_speaker_k_volume_set\n id: system_ya_speaker_k_volume_set\n initial_state: true\n max_exceeded: silent\n triggers:\n - trigger: time\n at: 06:25:00\n actions:\n - action: media_player.volume_set\n data:\n entity_id: media_player.yandex_k\n volume_level: '0.2'\n - action: media_player.volume_set\n data:\n entity_id: media_player.yandex_k\n volume_level: '0.2'", "config": [ { "name": "yandex kitchen", "room": "kitchen", "type": "media_player", "id": { "entity_id": "media_player.yandex_k", "device_id": null } } ] } ]