What's new

News Headlines

How to Combine BUTTONS and AUTOMATIONS in Home Assistant - Tutorial

Description

This Home Assistant tutorial is about triggering automations using a custom button and making sure that the button shows the status of the result of the automation. I will show you how to create an automation that turns the power in a specific room on and off at a specific time. Next to that, I will create a button that does the exact same thing while the power status is shown on that button even when the power is switched by the automation. Difficult? No, it's not. I will show you my best practice on how to set this up!

⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐
I cannot create these videos without your support!
If my videos save you time, you can support me in the following ways:

* Join this channel to get access to perks: 📺 https://www.youtube.com/c/smarthomejunkie/join
* Please consider becoming my patron 🏅 at https://www.patreon.com/join/smarthomejunkie
* Or support me by buying me a ☕ at https://www.buymeacoffee.com/smarthomejunkie
⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐

You can hire me for Home Assistant consultancy. Contact me at [email protected] for services and prices.

The code for the button in this tutorial is:
type: custom:button-card
entity: input_boolean.power_room
show_state: false
name: Room
icon: mdi:power
state:
- value: 'on'
color: lawngreen
- value: 'off'
color: grey

* The HACS video is here: https://youtu.be/Q8Gj0LiklRE
* The Trigger IDs video is here: https://youtu.be/fE_MYcXYwMI

If you have any requests for Home Assistant topics, please leave a comment and I will try to create a tutorial for you.

* See the list of Smart Home devices that I use and recommend here:
https://github.com/smarthomejunkie/MyDevices
* Follow me on Instagram @smarthomejunkie: https://www.instagram.com/smarthomejunkie/
* Follow me on Twitter 🐦: https://www.twitter.com/smarth0mejunkie
* Like my page on Facebook 📘: https://www.facebook.com/smarthomejunkie/

Check my channel for more awesome Smart Home tutorials: @Smart Home Junkie

If you got enthusiastic about Home Assistant, you can watch these videos too:
* What is Home Assistant?: https://youtu.be/Frd-C7ZeZAo
* How to install Home Assistant: https://youtu.be/ZhGjd22Ux_M
* Set up automations in Home Assistant: https://youtu.be/KXTs5_x_T5c
* How to set up lights and light groups in Home Assistant: https://youtu.be/YRcOadzMX2Q
* Create your own professional alarm system in Home Assistant: https://youtu.be/JPSDAszlII4
* and many more in this playlist: https://www.youtube.com/playlist?list=PLKuGrHcHLKMi6CiV8YQ3oigZMkxyLJKmE

Contents:
0:00 Introduction
0:57 Explain How buttons and Automations work together with Helpers
3:40 Create the helper
4:32 Show how to install the Custom Button Card
5:34 Create the button
6:31 Connect the button to the helper
7:28 Show that the button responds on the helper
8:06 Create the trigger automation: Automation 1: Power: Turn on Room on weekdays
10:25 Show that the trigger automation activates the helper
11:18 Create the action automation: Automation 2: Power: Toggle Livingroom
14:56 Show that the action automation gets triggered by the switch

#homeassistant #homeautomation #iot #smarthome #automations #smarthomejunkie
Back
Top Bottom