From 4e139d7c0ab1ff7a82a9c386626a0461af27025c Mon Sep 17 00:00:00 2001 From: Artacus <40248830+scottrbailey@users.noreply.github.com> Date: Tue, 18 May 2021 12:57:20 -0700 Subject: [PATCH] Update ir.cpp Handle both 24-key and 24-key old in decodeIR switch statement --- wled00/ir.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/wled00/ir.cpp b/wled00/ir.cpp index d0805eb28..ac921fb4c 100644 --- a/wled00/ir.cpp +++ b/wled00/ir.cpp @@ -163,7 +163,13 @@ void decodeIR(uint32_t code) if (decodeIRCustom(code)) return; if (code > 0xFFFFFF) return; //invalid code switch (irEnabled) { - case 1: decodeIR24OLD(code); break; // white 24-key remote (old) - it sends 0xFF0000 values + case 1: + if (code > 0xF80000) { + decodeIR24OLD(code); // white 24-key remote (old) - it sends 0xFF0000 values + } else { + decodeIR24(code); // 24-key remote - 0xF70000 to 0xF80000 + } + break; case 2: decodeIR24CT(code); break; // white 24-key remote with CW, WW, CT+ and CT- keys case 3: decodeIR40(code); break; // blue 40-key remote with 25%, 50%, 75% and 100% keys case 4: decodeIR44(code); break; // white 44-key remote with color-up/down keys and DIY1 to 6 keys