本帖最后由 user1075 于 2024-6-8 12:40 编辑
esphome:
name: template-sensor
esp32:
board: fm-devkit
framework:
type: arduino
# Enable logging
logger:
# Enable Home Assistant API
api:
encryption:
key: "dPWf0/LJwPeLK06Jy+ZW53LIssuE9LVuw6y3qrGkdbE="
ota:
password: "e6acb6b233944557ce812b58ef82ac38"
wifi:
ssid: !secret wifi_ssid
password: !secret wifi_password
# Enable fallback hotspot (captive portal) in case wifi connection fails
ap:
ssid: "Template-Sensor Fallback Hotspot"
password: "eyJFnKFAjuiG"
captive_portal:
sensor:
- platform: dht
pin: D2
temperature:
name: "Living Room Temperature"
humidity:
name: "Living Room Humidity"
update_interval: 60s
|