72 lines
1.5 KiB
YAML
Executable File
72 lines
1.5 KiB
YAML
Executable File
|
|
# Enable Home Assistant API
|
|
api:
|
|
encryption:
|
|
key: ${api_password}
|
|
on_client_connected:
|
|
- lambda: |-
|
|
id(api_connection) = true;
|
|
- component.update: s3_box_lcd
|
|
- script.execute: saver_enabled
|
|
on_client_disconnected:
|
|
- lambda: |-
|
|
id(api_connection) = false;
|
|
|
|
ota:
|
|
password: ${ota_password}
|
|
platform: esphome
|
|
|
|
wifi:
|
|
ssid: ${wifi_ssid}
|
|
password: ${wifi_password}
|
|
fast_connect: True
|
|
manual_ip:
|
|
static_ip: ${ip}
|
|
gateway: ${gateway}
|
|
subnet: ${subnet}
|
|
dns1: 192.169.2.15
|
|
dns2: 1.1.1.1
|
|
# use_address: 192.168.2.63 #when changing fixed IP
|
|
|
|
# Enable fallback hotspot (captive portal) in case wifi connection fails
|
|
ap:
|
|
ssid: ${device_name}
|
|
password: ${wifi_password}
|
|
|
|
on_connect:
|
|
- lambda: |-
|
|
id(wifi_connection) = true;
|
|
- display.page.show: idle_page
|
|
- component.update: s3_box_lcd
|
|
on_disconnect:
|
|
- lambda: |-
|
|
id(wifi_connection) = false;
|
|
|
|
sensor:
|
|
- platform: wifi_signal
|
|
name: "WiFi Signal "
|
|
update_interval: 10s
|
|
|
|
text_sensor:
|
|
- platform: wifi_info
|
|
ip_address:
|
|
name: IP Address
|
|
icon: mdi:wifi-strength-2
|
|
id: ipaddr
|
|
ssid:
|
|
name: "Connected SSID"
|
|
id: ssid
|
|
icon: mdi:wifi-strength-2
|
|
entity_category: diagnostic
|
|
|
|
bssid:
|
|
name: "Connected BSSID"
|
|
id: bssid
|
|
icon: mdi:wifi-strength-2
|
|
entity_category: diagnostic
|
|
|
|
mac_address:
|
|
name: "WiFi Mac Address"
|
|
id: macaddress
|
|
icon: mdi:wifi-strength-2
|
|
entity_category: diagnostic |