substitutions: name: home-assistant-voice-097b44 devicename: home-assistant-voice-097b44 friendly_name: Home Assistant Voice 097b44 comment: Clever Voice static_ip: !secret clints-home-assistant-voice power_switch_pin: GPIO3 packages: base: !include common/device_base.yaml network: !include common/wifi.yaml Nabu Casa.Home Assistant Voice PE: github://esphome/home-assistant-voice-pe/home-assistant-voice.yaml #power_buttons: !include common/media_player.yaml esphome: name: ${name} name_add_mac_suffix: false friendly_name: ${friendly_name} button: - id: !remove local_restart_button # forget all of this extending bullshit and implement this: # https://www.home-assistant.io/integrations/universal/ switch: - platform: template name: "External Power Switch" id: external_power_switch turn_on_action: - logger.log: "External Power Switch turned on" - media_player.turn_on: id: external_media_player # - lambda: return; turn_off_action: - logger.log: "External Power Switch turned off" - media_player.turn_off: id: external_media_player # - lambda: return; media_player: - id: !extend external_media_player # Define the actions Home Assistant will call on_turn_on: - logger.log: "Media Player Turned On via on_turn_on action" # - lambda: |- # // No action needed, Home Assistant can call this service # return; on_turn_off: - logger.log: "Media Player Turned Off via on_turn_off action" # - lambda: |- # // No action needed, Home Assistant can call this service # return;