Fix wrong type of tEnableLEDFeedback in IRSend.hpp (#1177)
tEnableLEDFeedback should not be a bool, because it's used as a bitmask with different states (Send/Receive/...). Even though a bool should be a byte anyways, this is apprently optimized with the current platformio toolchain for ESP8266 and causes the feedback LED to not work correctly.
This commit is contained in:
parent
b1941ff470
commit
c6aa13e443
|
@ -95,7 +95,7 @@ void IRsend::begin(){
|
|||
*/
|
||||
void IRsend::begin(bool aEnableLEDFeedback, uint_fast8_t aFeedbackLEDPin) {
|
||||
#if !defined(NO_LED_FEEDBACK_CODE)
|
||||
bool tEnableLEDFeedback = DO_NOT_ENABLE_LED_FEEDBACK;
|
||||
uint_fast8_t tEnableLEDFeedback = DO_NOT_ENABLE_LED_FEEDBACK;
|
||||
if(aEnableLEDFeedback) {
|
||||
tEnableLEDFeedback = LED_FEEDBACK_ENABLED_FOR_SEND;
|
||||
}
|
||||
|
@ -143,7 +143,7 @@ void IRsend::begin(uint_fast8_t aSendPin, bool aEnableLEDFeedback, uint_fast8_t
|
|||
#endif
|
||||
|
||||
#if !defined(NO_LED_FEEDBACK_CODE)
|
||||
bool tEnableLEDFeedback = DO_NOT_ENABLE_LED_FEEDBACK;
|
||||
uint_fast8_t tEnableLEDFeedback = DO_NOT_ENABLE_LED_FEEDBACK;
|
||||
if (aEnableLEDFeedback) {
|
||||
tEnableLEDFeedback = LED_FEEDBACK_ENABLED_FOR_SEND;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue