Mercurial > code > home > repos > homeauto
comparison espNode/rf_switch_desk.yaml @ 1701:33747dcf57ea
rf_switch_desk update
author | drewp@bigasterisk.com |
---|---|
date | Tue, 19 Oct 2021 22:29:26 -0700 |
parents | espNode/rfsetup.yaml@771f19d632f6 |
children | 250f4c27d56f |
comparison
equal
deleted
inserted
replaced
1700:11bd81eda1ef | 1701:33747dcf57ea |
---|---|
1 # facing the receiver board, | |
2 # pins: 3v3 | (cs) | D15 | gnd | |
3 | |
4 | |
5 esphome: | |
6 name: rf_switch_desk | |
7 platform: esp32 | |
8 board: lolin32 | |
9 | |
10 | |
11 logger: | |
12 baud_rate: 115200 | |
13 level: VERBOSE | |
14 logs: | |
15 out: VERBOSE | |
16 | |
17 | |
18 wifi: | |
19 networks: | |
20 - ssid: !secret wifi_ssid | |
21 password: !secret wifi_password | |
22 | |
23 | |
24 ota: | |
25 | |
26 | |
27 mqtt: | |
28 broker: '10.2.0.1' | |
29 port: 1883 | |
30 username: '' | |
31 password: '' | |
32 | |
33 | |
34 remote_receiver: | |
35 - id: rf_in | |
36 pin: | |
37 number: GPIO15 | |
38 tolerance: 20% | |
39 filter: 250us | |
40 idle: 8ms | |
41 dump: rc_switch | |
42 on_rc_switch: | |
43 then: | |
44 # - logger.log: | |
45 # level: INFO | |
46 # tag: out | |
47 # format: "RF read; proto %d; code %08llx" | |
48 # args: [x.protocol, x.code] | |
49 - mqtt.publish_json: | |
50 topic: rf_switch_desk/rf_received | |
51 payload: !lambda |- | |
52 root["protocol"] = x.protocol; | |
53 root["code0"] = static_cast<unsigned long>(x.code >> 32); | |
54 root["code1"] = static_cast<unsigned long>(x.code & 0xffff); |