RGBW 灯
rgbw 灯光平台从 4 个浮点输出组件创建一个 RGBW 灯(每个通道一个)。
# 配置示例light: - platform: rgbw name: "Livingroom Lights" red: output_component1 green: output_component2 blue: output_component3 white: output_component4校准/校正 LED 灯带产生的颜色通常是有利的,因为不同颜色的感知强度通常会有所不同。这可以通过在各个输出通道上使用 max_power 来实现:
# 配置示例light: - platform: rgbw name: "Livingroom Lights" red: output_component1 green: output_component2 blue: output_component3 white: output_component4
# 输出配置示例output: - platform: ... id: output_component1 max_power: 80%NOTE
请记住,gamma_correct 默认启用(γ=2.8),在校准时可能需要考虑这一点。例如,如果你将灯设置为 50% 亮度并希望这成为新的最大值:max_PWM_power = max_light_power^2.8 = 0.5^2.8 = 0.144,那么你应该将 max_power 设置为 14.4%。
对于某些 LED 灯泡,无法同时启用 RGB LED 和白色 LED,或者在希望获得白光时将 RGB 通道设置为最大值会产生不理想的色调效果。针对这些情况,提供了一个配置变量来防止 RGB LED 和白色 LED 同时点亮:color_interlock。
将此选项设置为 true 将使灯光具有两种可用的颜色模式:RGB 和 WHITE。当 RGB 颜色模式激活时,白色 LED 关闭;当 WHITE 颜色模式激活时,RGB LED 关闭。可以从 Home Assistant 界面切换这些模式,或使用灯光控制动作的 color_mode 选项。