2022-05-27 06:10:20 +00:00
|
|
|
esphome:
|
|
|
|
name: sonoffstecker1
|
|
|
|
platform: ESP8266
|
|
|
|
board: sonoff_basic
|
|
|
|
|
|
|
|
# Enable logging
|
|
|
|
logger:
|
|
|
|
|
|
|
|
# Enable Home Assistant API
|
|
|
|
api:
|
2024-04-30 08:45:14 +00:00
|
|
|
# password: !secret ss1password
|
2022-05-27 06:10:20 +00:00
|
|
|
encryption:
|
2024-04-30 08:45:14 +00:00
|
|
|
key: !secret ss1key
|
2022-05-27 06:10:20 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ota:
|
|
|
|
password: !secret ss1password
|
|
|
|
|
|
|
|
wifi:
|
|
|
|
ssid: !secret wifi_ssid
|
|
|
|
password: !secret wifi_password
|
|
|
|
fast_connect: true
|
2024-05-29 08:49:54 +00:00
|
|
|
ap:
|
|
|
|
ssid: sonoff_stecker_1_rescue
|
|
|
|
password: !secret rescue_ap_password
|
|
|
|
|
|
|
|
captive_portal:
|
|
|
|
|
2022-05-27 06:10:20 +00:00
|
|
|
|
|
|
|
switch:
|
|
|
|
- platform: gpio
|
|
|
|
name: "Sonoff Stecker 1"
|
|
|
|
pin: GPIO12
|
|
|
|
id: relay
|
|
|
|
|
|
|
|
binary_sensor:
|
|
|
|
- platform: gpio
|
|
|
|
pin:
|
|
|
|
number: GPIO0
|
|
|
|
mode:
|
|
|
|
input: true
|
|
|
|
pullup: true
|
|
|
|
inverted: true
|
|
|
|
id: "sonoff_power"
|
|
|
|
on_press:
|
|
|
|
- switch.toggle: relay
|