Created
January 13, 2024 18:32
-
-
Save letsautomatenet/0a15009c19222f9db8de256277675f29 to your computer and use it in GitHub Desktop.
ESPHome YAML Template - ESP32
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### START - Update this section with relevant details ### | |
substitutions: | |
device_name: "device-name-here" | |
friendly_name: Device Name Here | |
board_type: esp32dev | |
framework: esp-idf # arduino or esp-idf (recommended for ESP32) | |
# ESPHome API used by Home Assistant, etc | |
# If you go to this page it generates one for you automatically! | |
# https://esphome.io/components/api.html#configuration-variables | |
api_key: "Generate a key and put it here" | |
ap_password: "randomsecurepassword" # Fallback WiFi Access Point password | |
ota_password: "differentrandomsecurepassword" # Password used to remotely flash firmware | |
### END ### | |
esphome: | |
name: ${device_name} | |
friendly_name: ${friendly_name} | |
esp32: | |
board: ${board_type} | |
framework: | |
type: ${framework} | |
# Enable logging | |
logger: | |
# Enable Home Assistant API | |
api: | |
encryption: | |
key: ${api_key} | |
ota: | |
password: ${ota_password} | |
wifi: | |
ssid: !secret wifi_ssid | |
password: !secret wifi_password | |
# Enable fallback hotspot (captive portal) in case wifi connection fails | |
ap: | |
ssid: ${device_name} | |
password: ${ap_password} | |
captive_portal: | |
# Restart & Safe Mode Buttons | |
button: | |
- platform: restart | |
name: "Restart Device" | |
- platform: safe_mode | |
name: "Restart in Safe Mode" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment