60 lines
1.0 KiB
YAML
60 lines
1.0 KiB
YAML
esphome:
|
|
name: uptime-heart
|
|
friendly_name: uptime-heart
|
|
|
|
esp32:
|
|
board: esp32dev
|
|
framework:
|
|
type: esp-idf
|
|
|
|
# Enable logging
|
|
logger:
|
|
|
|
# Enable Home Assistant API
|
|
api:
|
|
encryption:
|
|
key: "YOUR_ENCRYPTION_KEY_HERE"
|
|
|
|
web_server:
|
|
port: 80
|
|
|
|
ota:
|
|
- platform: esphome
|
|
password: "YOUR_OTA_PASSWORD_HERE"
|
|
|
|
wifi:
|
|
ssid: !secret wifi_ssid
|
|
password: !secret wifi_password
|
|
|
|
# Enable fallback hotspot (captive portal) in case wifi connection fails
|
|
ap:
|
|
ssid: "Uptime-Heart Fallback Hotspot"
|
|
password: "fallback_password"
|
|
|
|
captive_portal:
|
|
|
|
output:
|
|
- platform: ledc
|
|
pin: GPIO17
|
|
id: output_red
|
|
- platform: ledc
|
|
pin: GPIO18
|
|
id: output_green
|
|
|
|
light:
|
|
- platform: monochromatic
|
|
name: "Rote LED"
|
|
output: output_red
|
|
id: led_red
|
|
restore_mode: ALWAYS_OFF
|
|
on_turn_on:
|
|
- light.turn_off: led_green
|
|
|
|
- platform: monochromatic
|
|
name: "Grüne LED"
|
|
output: output_green
|
|
id: led_green
|
|
restore_mode: ALWAYS_OFF
|
|
on_turn_on:
|
|
- light.turn_off: led_red
|