mirror of
https://github.com/Show-maket/IR-protocol.git
synced 2025-05-04 07:10:16 +00:00
isSubOverflow fix
This commit is contained in:
parent
960b3064cb
commit
af6041c5ae
@ -26,6 +26,7 @@ void IR_DecoderRaw::isr() {
|
|||||||
if (firstUnHandledFront == &subBuffer[currentSubBufferIndex]) { // Если контроллер не успел обработать новый сигнал, принудительно пропускаем его
|
if (firstUnHandledFront == &subBuffer[currentSubBufferIndex]) { // Если контроллер не успел обработать новый сигнал, принудительно пропускаем его
|
||||||
firstUnHandledFront = firstUnHandledFront->next;
|
firstUnHandledFront = firstUnHandledFront->next;
|
||||||
isSubBufferOverflow = true;
|
isSubBufferOverflow = true;
|
||||||
|
|
||||||
#ifdef IRDEBUG_INFO
|
#ifdef IRDEBUG_INFO
|
||||||
// Serial.println();
|
// Serial.println();
|
||||||
Serial.println(" ISR BUFFER OVERFLOW ");
|
Serial.println(" ISR BUFFER OVERFLOW ");
|
||||||
|
@ -46,7 +46,7 @@ public:
|
|||||||
bool isSubOverflow() {
|
bool isSubOverflow() {
|
||||||
uint8_t oldSREG = SREG;
|
uint8_t oldSREG = SREG;
|
||||||
cli();
|
cli();
|
||||||
bool ret = isSubBufferOverflow;
|
volatile bool ret = isSubBufferOverflow;
|
||||||
SREG = oldSREG;
|
SREG = oldSREG;
|
||||||
return ret;
|
return ret;
|
||||||
};
|
};
|
||||||
|
Loading…
x
Reference in New Issue
Block a user