程序
sensor:
- platform: dht
pin: D5
temperature:
name: "Living Room Temperature"
humidity:
name: "Living Room Humidity"
update_interval: 60s
model: DHT11
spi:
clk_pin: D0
mosi_pin: D1
display:
- platform: ssd1306_spi
model: "SSD1306 128x64"
cs_pin: D2
dc_pin: D3
reset_pin: D4
lambda: |-
# it.print(0, 0, id(font), "Hello World!");
# hongwai
web_server:
port: 80
remote_receiver:
pin:
number: D6
inverted: True
dump: all
remote_transmitter:
pin:
number: D7
carrier_duty_percent: 50%
switch:
- platform: template
name:"TV Power RAW"
turn_on_action:
remote_transmitter.transmit_raw:
code: [9044, -4486, 582, -1668, 581, -1668, 580, -547, 579, -1665, 583, -1666, 585, -1668, 581, -546, 578, -546, 581, -545, 581, -546, 579, -1669, 581, -546, 579, -547, 579, -547, 579, -1668, 581, -1666, 581, -546, 580, -547, 579, -1667, 582, -1668, 581, -1669, 579, -548, 578, -1668, 582, -1666, 581, -1668, 581, -1668, 580, -550, 576, -546, 580, -546, 579, -1669, 580, -574, 552, -547, 580]
repeat:
times: 10
wait_time: 50ms
carrier_frequency: 38kHz
turn_off_action:
remote_transmitter.transmit_raw:
code: [9044, -4486, 582, -1668, 581, -1668, 580, -547, 579, -1665, 583, -1666, 585, -1668, 581, -546, 578, -546, 581, -545, 581, -546, 579, -1669, 581, -546, 579, -547, 579, -547, 579, -1668, 581, -1666, 581, -546, 580, -547, 579, -1667, 582, -1668, 581, -1669, 579, -548, 578, -1668, 582, -1666, 581, -1668, 581, -1668, 580, -550, 576, -546, 580, -546, 579, -1669, 580, -574, 552, -547, 580]
repeat:
times: 10
wait_time: 50ms
carrier_frequency: 38kHz
报错
INFO Reading configuration...
ERROR Error while reading config: mapping values are not allowed here
in "/config/tep.yaml", line 68, column 20
68那行是turn_on_action: 其他什么都没有了 |