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

Have HA Voice announce when a door sensor is below 20%

$
0
0

Below is the YAML I made but I can’t really test it until a battery is actually below 20% but I have a few questions. First, is the most efficient way to be doing this?

Second, when I run test it says, “The door sensor battery is below 20 percent.” and skips over the trigger.entity_id part which I guess makes sense since an entity didn’t actually trigger the automation but when it does run, will it say a friendly name of the device/event or read out the actual ID of the code like, “7basdfasdfasdf0e” ?

Blockquote
alias: Door sensor (any) below 20%
description: “”
triggers:

  • trigger: sun
    event: sunset
    offset: “00:05:00”
    conditions:
  • type: is_battery_level
    condition: device
    device_id: 16asdfasdfasdf59
    entity_id: 09asdfasdfasdff7
    domain: sensor
    below: 20
  • type: is_battery_level
    condition: device
    device_id: b1asdfasdfasdfd
    entity_id: 2asdfasdfasdf30
    domain: sensor
    below: 20
  • type: is_battery_level
    condition: device
    device_id: 9fasdfasdfasdf34
    entity_id: 97asdfasdfasdf4d
    domain: sensor
    below: 20
  • type: is_battery_level
    condition: device
    device_id: f0asdfasdfasdf04
    entity_id: 7basdfasdfasdf0e
    domain: sensor
    below: 20
    actions:
  • action: tts.cloud_say
    metadata: {}
    data:
    cache: false
    entity_id: media_player.home_assistant_voice_12a345_media_player
    message: The door sensor {{ trigger.entity_id }} battery is below 20 percent.
    mode: single

Blockquote

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 106595

Trending Articles



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