-
Notifications
You must be signed in to change notification settings - Fork 2
/
alarma-x28.yaml
69 lines (55 loc) · 1.21 KB
/
alarma-x28.yaml
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
esphome:
name: alarma-x28
includes:
- alarma-x28/x28.h
custom_component:
- lambda: |-
auto alarma_x28 = new AlarmaX28();
return {alarma_x28};
components:
- id: alarma_x28_id
button:
- platform: template
name: PANICO
id: panic_button
on_press:
- lambda: |-
((AlarmaX28*)id(alarma_x28_id))->sendPanic();
switch:
- platform: custom
lambda: |-
auto x28_activada = new X28Activada();
App.register_component(x28_activada);
return {x28_activada};
switches:
name: "Alarma Activada"
id: x28_activada
- platform: custom
lambda: |-
auto x28_estoy = new X28Estoy();
App.register_component(x28_estoy);
return {x28_estoy};
switches:
name: "Estoy"
id: x28_estoy
esp32:
board: nodemcu-32s
logger:
# Enable Home Assistant API
api:
encryption:
key: !secret apiencryptionkey
ota:
password: !secret apikey
wifi:
ssid: !secret devices-ssid
password: !secret devices-password
fast_connect: false
power_save_mode: light
# Enable fallback hotspot (captive portal) in case wifi connection fails
ap:
ssid: "ALARMA"
password: "w1iEbzypTowm"
captive_portal:
web_server:
port: 80