-
Notifications
You must be signed in to change notification settings - Fork 11
/
esp8266.yaml
36 lines (34 loc) · 859 Bytes
/
esp8266.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
# Configuration for the RGB LED on the ESP8266
#
# Used substitutions:
#
# - led_pin_red: pin connected to the red LED
# - led_pin_green: pin connected to the green LED
# - led_pin_blue: pin connected to the blue LED
#
# IDs used outside this file:
#
# - led_rgb: the RGB light
# The red, green and blue components don't have the same brightness.
# This takes into account:
# - the different current through each component
# - the common gamma correction (2.8)
output:
- platform: esp8266_pwm
id: led_red
pin: ${led_pin_red}
max_power: 1
- platform: esp8266_pwm
id: led_green
pin: ${led_pin_green}
max_power: 0.011 # = 0.2^2.8
- platform: esp8266_pwm
id: led_blue
pin: ${led_pin_blue}
max_power: 0.722 # = 0.89^2.8
light:
- platform: rgb
id: led_rgb
red: led_red
green: led_green
blue: led_blue