· last year · Aug 10, 2024, 06:35 PM
1substitutions:
2 device_name: quinled3
3 device_id: Q3
4 device_ip: 192.168.4.83
5
6esphome:
7 name: $device_name
8
9esp32:
10 board: mhetesp32devkit
11 framework:
12 type: arduino
13
14# Enable logging
15logger:
16
17# Enable Home Assistant API
18api:
19 encryption:
20 key: "2y/a9FICElMEaYSTMq3st+reXdyg61vfh4uE5uk5Koo="
21
22ota:
23 platform: esphome
24 password: "d937836e24d3cb477dc158f891538095"
25
26wifi:
27 ssid: !secret wifi_ssid
28 password: !secret wifi_password
29
30 # Optional manual IP
31 manual_ip:
32 static_ip: ${device_ip}
33 gateway: 192.168.4.1
34 subnet: 255.255.255.0
35
36 # Enable fallback hotspot (captive portal) in case wifi connection fails
37 ap:
38 ssid: ${device_id} ${device_name} Fallback Hotspot
39 password: "hh56TXaMBsVw"
40
41captive_portal:
42
43web_server:
44 port: 80
45
46#one_wire:
47# - platform: gpio
48# pin: GPIO18
49
50# Text sensors with general information.
51text_sensor:
52 - platform: wifi_info
53 ip_address:
54 name: ${device_name}_ip
55
56
57switch:
58 - platform: gpio
59 name: ${device_id} Onboard light
60 pin: 2
61 inverted: true
62
63output:
64 - platform: ledc
65 pin: 16
66 frequency: 19531Hz
67 id: LED_gpio_16
68 #min_power: 0.0009
69 min_power: 0.0009
70 max_power: 0.50
71 zero_means_zero: true
72
73 - platform: ledc
74 pin: 17
75 frequency: 19531Hz
76 id: LED_gpio_17
77 #min_power: 0.0009
78 min_power: 0.002
79 max_power: 0.50
80 zero_means_zero: true
81
82 - platform: ledc
83 pin: 5
84 frequency: 20000Hz
85 id: LED_gpio_5
86
87 - platform: ledc
88 pin: 19
89 frequency: 20000Hz
90 id: LED_gpio_19
91
92light:
93 - platform: monochromatic
94 name: ${device_id} LED light ouput1
95 default_transition_length: 0s
96 output: LED_gpio_16
97 restore_mode: RESTORE_DEFAULT_OFF
98
99 - platform: monochromatic
100 name: ${device_id} LED light ouput2
101 default_transition_length: 0s
102 output: LED_gpio_17
103 restore_mode: RESTORE_DEFAULT_OFF
104
105 - platform: monochromatic
106 name: ${device_id} LED light ouput3
107 default_transition_length: 1s
108 output: LED_gpio_5
109 restore_mode: RESTORE_DEFAULT_OFF
110
111 - platform: monochromatic
112 name: ${device_id} LED light ouput4
113 default_transition_length: 1s
114 output: LED_gpio_19
115 restore_mode: RESTORE_DEFAULT_OFF
116
117#sensor:
118# - platform: dallas
119# index: 0
120# name: ${device_id} Temperature