forked from jodur/ESPHOME-ITHO
-
Notifications
You must be signed in to change notification settings - Fork 0
/
itho.yaml
120 lines (94 loc) · 2.46 KB
/
itho.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
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
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
esphome:
name: fancontrol
platform: ESP8266
board: nodemcuv2
includes:
- itho.h
libraries:
- https://github.com/jodur/ITHO-Lib.git
#Set ID from remotes that are used, so you can identify the root of the last State change
on_boot:
then:
- lambda: |-
Idlist[0]={"69:9a:aa:bb:cc:dd:ee:ff","Badkamer"};
Idlist[1]={"65:59:aa:bb:cc:dd:ee:ff","Toilet"};
Idlist[2]={"ID3","ID3"};
Mydeviceid="MY_ESPHOME";
id(swfan_low).turn_on(); //This ensures fan is at low-speed at boot
wifi:
ssid: <YOURSSID>
password: <YOURPASSWORD>
# Enable fallback hotspot (captive portal) in case wifi connection fails
ap:
ssid: "FALLBACK AP"
password: "jdsh348201"
captive_portal:
# Enable logging
logger:
# level: VERBOSE #Enable this line to find out the ID of youre remote
# Enable Home Assistant API
api:
ota:
switch:
- platform: custom
lambda: |-
auto fansendlow = new FanSendLow();
App.register_component(fansendlow);
return {fansendlow};
switches:
name: "FanSendLow"
id: swfan_low
- platform: custom
lambda: |-
auto fansendmedium = new FanSendMedium();
App.register_component(fansendmedium);
return {fansendmedium};
switches:
name: "FanSendMedium"
- platform: custom
lambda: |-
auto fansendhigh = new FanSendHigh();
App.register_component(fansendhigh);
return {fansendhigh};
switches:
name: "FanSendHigh"
- platform: custom
lambda: |-
auto fansendt1 = new FanSendIthoTimer1();
App.register_component(fansendt1);
return {fansendt1};
switches:
name: "FanSendTimer1"
- platform: custom
lambda: |-
auto fansendt2 = new FanSendIthoTimer2();
App.register_component(fansendt2);
return {fansendt2};
switches:
name: "FanSendTimer2"
- platform: custom
lambda: |-
auto fansendt3 = new FanSendIthoTimer3();
App.register_component(fansendt3);
return {fansendt3};
switches:
name: "FanSendTimer3"
- platform: custom
lambda: |-
auto fansendjoin = new FanSendIthoJoin();
App.register_component(fansendjoin);
return {fansendjoin};
switches:
name: "FanSendJoin"
text_sensor:
- platform: custom
lambda: |-
auto fanrecv = new FanRecv();
App.register_component(fanrecv);
return {fanrecv->fanspeed,fanrecv->fantimer,fanrecv->Lastid};
text_sensors:
- name: "fanspeed"
icon: "mdi:transfer"
- name: "fantimer"
icon: "mdi:timer"
- name: "lastid"