-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathShelly_1
95 lines (78 loc) · 1.63 KB
/
Shelly_1
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
substitutions:
name: "{{name of the device}}"
friendly_name: "{{friendly name}}"
esphome:
name: "${name}"
friendly_name: "${friendly_name}"
project:
name: esphome.shelly_one_light-template
version: "1.0"
esp8266:
board: esp01_1m
restore_from_flash: true
preferences:
flash_write_interval: 0s
logger:
api:
encryption:
key: !secret api_encryption_key
ota:
password: !secret ota_password
wifi:
ssid: !secret wifi_ssid
password: !secret wifi_password
ap:
password: !secret ap_password
captive_portal:
web_server:
port: 80
auth:
username: !secret web_server_username
password: !secret web_server_password
version: 2
local: true
text_sensor:
- platform: wifi_info
ip_address:
name: WiFi - IP-address
ssid:
name: WiFi - Connected SSID
bssid:
name: WiFi - Connected BSSID
mac_address:
name: WiFi - MAC-address
scan_results:
name: WiFi - Latest Scan Results
dns_address:
name: WiFi - DNS Address
sensor:
- platform: wifi_signal
name: "WiFi - Signal"
update_interval: 60s
entity_category: "diagnostic"
### EDIT BELOW THIS LINE ###
switch:
- platform: restart
name: "Device - Restart"
output:
- platform: gpio
pin: GPIO4
id: shelly_1_relay
light:
- platform: binary
name: "Device - Relay"
output: shelly_1_relay
id: lightid
restore_mode: RESTORE_DEFAULT_OFF
binary_sensor:
- platform: gpio
pin:
number: GPIO5
#mode: INPUT_PULLUP
#inverted: True
name: "Device - Button"
on_state:
then:
- light.toggle: lightid
internal: true
id: switchid