forked from barrenechea/esphome-config-files
-
Notifications
You must be signed in to change notification settings - Fork 0
/
nexxt-mod-test.yaml
127 lines (116 loc) · 2.79 KB
/
nexxt-mod-test.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
121
122
123
124
125
126
127
substitutions:
devicename: NEXXT Device
esphome:
name: nexxt-mod-test
platformio_options:
board_build.flash_mode: dio
esp32:
board: esp32-c3-devkitm-1
variant: ESP32C3
framework:
type: esp-idf
sdkconfig_options:
CONFIG_FREERTOS_UNICORE: y
CONFIG_COMPILER_OPTIMIZATION_SIZE: y
# Enable WPA3 support
CONFIG_WPA_SUITE_B_192: y
# Specific to Bluetooth usage
CONFIG_BT_BLE_50_FEATURES_SUPPORTED: y
CONFIG_BT_BLE_42_FEATURES_SUPPORTED: y
# Payload size fix - Extend Watchdog timeout
CONFIG_ESP_TASK_WDT_TIMEOUT_S: "10"
wifi:
ssid: !secret wifi_ssid
password: !secret wifi_password
fast_connect: true
# Sets up provisioning Wi-Fi credentials to the device over BLE
esp32_improv:
authorizer: none
# Make sure logging is not using the serial port
logger:
baud_rate: 0
# Enable Home Assistant API
api:
encryption:
key: !secret api_encryption_key
ota:
password: !secret ota_password
binary_sensor:
- platform: gpio
internal: true
name: ${devicename} Button
pin:
number: GPIO1
mode: INPUT_PULLUP
inverted: true
on_press:
- light.toggle: red_led
- light.toggle: blue_led
- switch.toggle: plug_top_left
output:
- platform: gpio
id: red_led_gpio
pin:
number: GPIO9
inverted: true
light:
- platform: status_led
internal: true
id: blue_led
name: ${devicename} Blue LED
pin:
number: GPIO20
inverted: True
- platform: binary
internal: true
id: red_led
name: ${devicename} Red LED
output: red_led_gpio
switch:
# Platform controls
- platform: restart
name: ${devicename} Restart
- platform: safe_mode
name: ${devicename} Restart (Safe Mode)
# Plugs
- platform: gpio
id: plug_top_left
name: ${devicename} Plug - Top Left
icon: mdi:power-socket-it
pin: GPIO2
- platform: gpio
id: plug_top_right
name: ${devicename} Plug - Top Right
icon: mdi:power-socket-it
pin: GPIO3
- platform: gpio
id: plug_bottom_left
name: ${devicename} Plug - Bottom Left
icon: mdi:power-socket-it
pin: GPIO4
- platform: gpio
id: plug_bottom_right
name: ${devicename} Plug - Bottom Right
icon: mdi:power-socket-it
pin: GPIO5
# USB
- platform: gpio
id: usb_top_left
name: ${devicename} USB - Top Left
icon: mdi:usb-port
pin: GPIO8
- platform: gpio
id: usb_top_right
name: ${devicename} USB - Top Right
icon: mdi:usb-port
pin: GPIO18
- platform: gpio
id: usb_bottom_left
name: ${devicename} USB - Bottom Left
icon: mdi:usb-port
pin: GPIO19
- platform: gpio
id: usb_bottom_right
name: ${devicename} USB - Bottom Right
icon: mdi:usb-port
pin: GPIO21 # Not working --- TX pin, always on? - ON 2.4v, OFF 0.99v