-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathM5Stack-AtomS3-Lite.yaml
101 lines (88 loc) · 1.92 KB
/
M5Stack-AtomS3-Lite.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
#https://docs.m5stack.com/en/core/AtomS3%20Lite
substitutions:
device_name: "M5Stack-AtomS3-Lite"
device_friendly_name: "M5Stack AtomS3 Lite"
device_description: "M5Stack AtomS3 Lite"
time_timezone: "Europe/Amsterdam"
esphome:
name: ${device_name}
friendly_name: $device_friendly_name
comment: "${device_description}"
name_add_mac_suffix: false
esp32:
board: esp32-s3-devkitc-1
framework:
type: arduino
wifi:
networks:
- ssid: !secret wifi_ssid
password: !secret wifi_password
# Enable fallback hotspot (captive portal) in case wifi connection fails
ap:
ssid: ${device_name}
password: !secret wifi_fallback_password
ap_timeout: 15s
captive_portal:
# Enable logging
logger:
baud_rate: 0
level: WARN
# Enable Home Assistant API
api:
encryption:
key: !secret home_assistant_key
ota:
password: !secret ota_password
# Output that blinks the LED
output:
- platform: template
id: status_output
type: binary
write_action:
- if:
condition:
lambda: return (state);
then:
- light.turn_on:
id: led
brightness: 70%
red: 100%
green: 0%
blue: 0%
else:
- light.turn_off: led
#G4=IR
remote_transmitter:
pin: GPIO4
carrier_duty_percent: 50%
light:
# Enable status LED
- platform: status_led
output: status_output
name: "Status Led"
internal: True
#G35=RGB WS2812C-2020
- platform: esp32_rmt_led_strip
rgb_order: GRB
pin: 35
num_leds: 4
# RMT 0 channels will be occupied by IR
rmt_channel: 1
chipset: ws2812
id: led
name: "Led"
#G41=Button
binary_sensor:
- platform: gpio
name: Button
pin:
number: GPIO41
inverted: true
mode:
input: true
pullup: true
filters:
- delayed_off: 10ms
on_press:
then:
- logger.log: Button Pressed