diff --git a/platformio_override.ini.example b/platformio_override.ini.example index cf9da268..d486dff0 100644 --- a/platformio_override.ini.example +++ b/platformio_override.ini.example @@ -29,7 +29,7 @@ build_flags = ${common.build_flags_esp8266} ; -D LEDPIN=2 ; -D BTNPIN=0 ; -D TOUCHPIN=T0 -; -D IR_PIN=4 +; -D IRPIN=4 ; -D RLYPIN=12 ; -D RLYMDE=1 ; digital LED strip types - uncomment only one ! - this will disable WS281x / SK681x support diff --git a/usermods/TTGO-T-Display/platformio_override.ini b/usermods/TTGO-T-Display/platformio_override.ini index 4b176096..7e42d9a5 100644 --- a/usermods/TTGO-T-Display/platformio_override.ini +++ b/usermods/TTGO-T-Display/platformio_override.ini @@ -3,6 +3,6 @@ build_flags = ${common.build_flags_esp32} ; PIN defines - uncomment and change, if needed: ; -D LEDPIN=2 -D BTNPIN=35 -; -D IR_PIN=4 +; -D IRPIN=4 ; -D RLYPIN=12 ; -D RLYMDE=1 diff --git a/usermods/esp32_multistrip/NpbWrapper.h b/usermods/esp32_multistrip/NpbWrapper.h index 1058e514..b93242cf 100644 --- a/usermods/esp32_multistrip/NpbWrapper.h +++ b/usermods/esp32_multistrip/NpbWrapper.h @@ -24,8 +24,8 @@ #define LEDPIN 1 // Legacy pin def required by some other portions of code. This pin is not used do drive LEDs. #endif -#ifndef IR_PIN - #define IR_PIN -1 //infrared pin (-1 to disable) MagicHome: 4, H801 Wifi: 0 +#ifndef IRPIN + #define IRPIN -1 //infrared pin (-1 to disable) MagicHome: 4, H801 Wifi: 0 #endif #ifndef RLYPIN diff --git a/wled00/NpbWrapper.h b/wled00/NpbWrapper.h index 6316dcf8..6e56efe5 100644 --- a/wled00/NpbWrapper.h +++ b/wled00/NpbWrapper.h @@ -25,8 +25,8 @@ //#define TOUCHPIN T0 //touch pin. Behaves the same as button. ESP32 only. #endif -#ifndef IR_PIN -#define IR_PIN 4 //infrared pin (-1 to disable) MagicHome: 4, H801 Wifi: 0 +#ifndef IRPIN +#define IRPIN 4 //infrared pin (-1 to disable) MagicHome: 4, H801 Wifi: 0 #endif #ifndef RLYPIN @@ -71,8 +71,8 @@ #define WPIN 14 //W pin for analog LED strip #define W2PIN 04 //W2 pin for analog LED strip #undef BTNPIN - #undef IR_PIN - #define IR_PIN 0 //infrared pin (-1 to disable) MagicHome: 4, H801 Wifi: 0 + #undef IRPIN + #define IRPIN 0 //infrared pin (-1 to disable) MagicHome: 4, H801 Wifi: 0 #elif defined(WLED_USE_BWLT11) //PWM pins - to use with BW-LT11 #define RPIN 12 //R pin for analog LED strip @@ -93,7 +93,7 @@ #define BPIN 14 //B pin for analog LED strip #define WPIN 4 //W pin for analog LED strip #define W2PIN 5 //W2 pin for analog LED strip - #undef IR_PIN + #undef IRPIN #else //Enable override of Pins by using the platformio_override.ini file //PWM pins - PINs 5,12,13,15 are used with Magic Home LED Controller diff --git a/wled00/cfg.cpp b/wled00/cfg.cpp index c12f8848..5a58f2c2 100644 --- a/wled00/cfg.cpp +++ b/wled00/cfg.cpp @@ -434,7 +434,7 @@ void serializeConfig() { #if defined(IRPIN) && IRPIN > -1 JsonObject hw_ir = hw.createNestedObject("ir"); - hw_ir[F("pin")] = IR_PIN; + hw_ir[F("pin")] = IRPIN; hw_ir[F("type")] = 0; #endif diff --git a/wled00/ir.cpp b/wled00/ir.cpp index 1405187e..70c920e0 100644 --- a/wled00/ir.cpp +++ b/wled00/ir.cpp @@ -488,7 +488,7 @@ void initIR() { if (irEnabled > 0) { - irrecv = new IRrecv(IR_PIN); + irrecv = new IRrecv(IRPIN); irrecv->enableIRIn(); } } diff --git a/wled00/wled.h b/wled00/wled.h index 7c2b032f..6a9048a5 100644 --- a/wled00/wled.h +++ b/wled00/wled.h @@ -129,7 +129,7 @@ Comment out this error message to build regardless. #endif -#if IR_PIN < 0 +#if IRPIN < 0 #ifndef WLED_DISABLE_INFRARED #define WLED_DISABLE_INFRARED #endif