From 6b8589440f47a1fb933c0930d7069faa78a22b78 Mon Sep 17 00:00:00 2001 From: DerFetzer Date: Sat, 13 Mar 2021 20:00:42 +0100 Subject: [PATCH] [WLED] Zero out MSB as it will be treated as white (#10252) Signed-off-by: Matthias Fetzer --- .../java/org/openhab/binding/wled/internal/WLedHandler.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bundles/org.openhab.binding.wled/src/main/java/org/openhab/binding/wled/internal/WLedHandler.java b/bundles/org.openhab.binding.wled/src/main/java/org/openhab/binding/wled/internal/WLedHandler.java index a3991d3649a..78269444207 100644 --- a/bundles/org.openhab.binding.wled/src/main/java/org/openhab/binding/wled/internal/WLedHandler.java +++ b/bundles/org.openhab.binding.wled/src/main/java/org/openhab/binding/wled/internal/WLedHandler.java @@ -256,7 +256,7 @@ public class WLedHandler extends BaseThingHandler { * @return WLED needs the letter h followed by 2 digit HEX code for RRGGBB */ private String createColorHex(HSBType hsb) { - return String.format("h%06X", hsb.getRGB()); + return String.format("h%06X", hsb.getRGB() & 0x00FFFFFF); } @Override