@@ -183,10 +183,21 @@ bool canUseSerial(void); // WLEDMM (wled_serial.cpp) returns true if Serial ca
183183#define B_8266_BB_UCS_4 NeoPixelBusLg<NeoRgbwUcs8904Feature, NeoEsp8266BitBang800KbpsMethod, NeoGammaNullMethod> // 4 chan, esp8266, bb (any pin)
184184#endif
185185
186+
187+ // RMT driver selection
188+ #if !defined(WLED_USE_SHARED_RMT) && !defined(__riscv) && defined(ARDUINO_ARCH_ESP32) && (ESP_IDF_VERSION_MAJOR >= 4)
189+
190+ #include < NeoEsp32RmtHIMethod.h>
191+ #define NeoEsp32RmtMethod (x ) NeoEsp32RmtHIN ## x ## Method
192+ #else
193+ #define NeoEsp32RmtMethod (x ) NeoEsp32RmtN ## x ## Method
194+ #endif
195+
196+
186197/* ** ESP32 Neopixel methods ***/
187198#ifdef ARDUINO_ARCH_ESP32
188199// RGB
189- #define B_32_RN_NEO_3 NeoPixelBusLg<NeoGrbFeature, NeoEsp32RmtNWs2812xMethod , NeoGammaNullMethod>
200+ #define B_32_RN_NEO_3 NeoPixelBusLg<NeoGrbFeature, NeoEsp32RmtMethod(Ws2812x) , NeoGammaNullMethod>
190201#ifndef WLED_NO_I2S0_PIXELBUS
191202#define B_32_I0_NEO_3 NeoPixelBusLg<NeoGrbFeature, NeoEsp32I2s0800KbpsMethod, NeoGammaNullMethod>
192203#endif
@@ -195,7 +206,7 @@ bool canUseSerial(void); // WLEDMM (wled_serial.cpp) returns true if Serial ca
195206#endif
196207// #define B_32_BB_NEO_3 NeoPixelBrightnessBus<NeoGrbFeature, NeoEsp32BitBang800KbpsMethod> // NeoEsp8266BitBang800KbpsMethod
197208// RGBW
198- #define B_32_RN_NEO_4 NeoPixelBusLg<NeoGrbwFeature, NeoEsp32RmtNWs2812xMethod , NeoGammaNullMethod>
209+ #define B_32_RN_NEO_4 NeoPixelBusLg<NeoGrbwFeature, NeoEsp32RmtMethod(Ws2812x) , NeoGammaNullMethod>
199210#ifndef WLED_NO_I2S0_PIXELBUS
200211#define B_32_I0_NEO_4 NeoPixelBusLg<NeoGrbwFeature, NeoEsp32I2s0800KbpsMethod, NeoGammaNullMethod>
201212#endif
@@ -204,7 +215,7 @@ bool canUseSerial(void); // WLEDMM (wled_serial.cpp) returns true if Serial ca
204215#endif
205216// #define B_32_BB_NEO_4 NeoPixelBrightnessBus<NeoGrbwFeature, NeoEsp32BitBang800KbpsMethod> // NeoEsp8266BitBang800KbpsMethod
206217// 400Kbps
207- #define B_32_RN_400_3 NeoPixelBusLg<NeoGrbFeature, NeoEsp32RmtN400KbpsMethod , NeoGammaNullMethod>
218+ #define B_32_RN_400_3 NeoPixelBusLg<NeoGrbFeature, NeoEsp32RmtMethod(400Kbps) , NeoGammaNullMethod>
208219#ifndef WLED_NO_I2S0_PIXELBUS
209220#define B_32_I0_400_3 NeoPixelBusLg<NeoGrbFeature, NeoEsp32I2s0400KbpsMethod, NeoGammaNullMethod>
210221#endif
@@ -213,7 +224,7 @@ bool canUseSerial(void); // WLEDMM (wled_serial.cpp) returns true if Serial ca
213224#endif
214225// #define B_32_BB_400_3 NeoPixelBrightnessBus<NeoGrbFeature, NeoEsp32BitBang400KbpsMethod> // NeoEsp8266BitBang400KbpsMethod
215226// TM1814 (RGBW)
216- #define B_32_RN_TM1_4 NeoPixelBusLg<NeoWrgbTm1814Feature, NeoEsp32RmtNTm1814Method , NeoGammaNullMethod>
227+ #define B_32_RN_TM1_4 NeoPixelBusLg<NeoWrgbTm1814Feature, NeoEsp32RmtMethod(Tm1814) , NeoGammaNullMethod>
217228#ifndef WLED_NO_I2S0_PIXELBUS
218229#define B_32_I0_TM1_4 NeoPixelBusLg<NeoWrgbTm1814Feature, NeoEsp32I2s0Tm1814Method, NeoGammaNullMethod>
219230#endif
@@ -222,7 +233,7 @@ bool canUseSerial(void); // WLEDMM (wled_serial.cpp) returns true if Serial ca
222233#endif
223234// Bit Bang theoratically possible, but very undesirable and not needed (no pin restrictions on RMT and I2S)
224235// TM1829 (RGB)
225- #define B_32_RN_TM2_3 NeoPixelBusLg<NeoBrgFeature, NeoEsp32RmtNTm1829Method , NeoGammaNullMethod>
236+ #define B_32_RN_TM2_3 NeoPixelBusLg<NeoBrgFeature, NeoEsp32RmtMethod(Tm1829) , NeoGammaNullMethod>
226237#ifndef WLED_NO_I2S0_PIXELBUS
227238#define B_32_I0_TM2_3 NeoPixelBusLg<NeoBrgFeature, NeoEsp32I2s0Tm1829Method, NeoGammaNullMethod>
228239#endif
@@ -231,7 +242,7 @@ bool canUseSerial(void); // WLEDMM (wled_serial.cpp) returns true if Serial ca
231242#endif
232243// Bit Bang theoratically possible, but very undesirable and not needed (no pin restrictions on RMT and I2S)
233244// UCS8903
234- #define B_32_RN_UCS_3 NeoPixelBusLg<NeoRgbUcs8903Feature, NeoEsp32RmtNWs2812xMethod , NeoGammaNullMethod>
245+ #define B_32_RN_UCS_3 NeoPixelBusLg<NeoRgbUcs8903Feature, NeoEsp32RmtMethod(Ws2812x) , NeoGammaNullMethod>
235246#ifndef WLED_NO_I2S0_PIXELBUS
236247#define B_32_I0_UCS_3 NeoPixelBusLg<NeoRgbUcs8903Feature, NeoEsp32I2s0800KbpsMethod, NeoGammaNullMethod>
237248#endif
@@ -240,7 +251,7 @@ bool canUseSerial(void); // WLEDMM (wled_serial.cpp) returns true if Serial ca
240251#endif
241252// Bit Bang theoratically possible, but very undesirable and not needed (no pin restrictions on RMT and I2S)
242253// UCS8904
243- #define B_32_RN_UCS_4 NeoPixelBusLg<NeoRgbwUcs8904Feature, NeoEsp32RmtNWs2812xMethod , NeoGammaNullMethod>
254+ #define B_32_RN_UCS_4 NeoPixelBusLg<NeoRgbwUcs8904Feature, NeoEsp32RmtMethod(Ws2812x) , NeoGammaNullMethod>
244255#ifndef WLED_NO_I2S0_PIXELBUS
245256#define B_32_I0_UCS_4 NeoPixelBusLg<NeoRgbwUcs8904Feature, NeoEsp32I2s0800KbpsMethod, NeoGammaNullMethod>
246257#endif
0 commit comments