Cellular: Fix AT URC handler not to dismiss incoming chars

pull/7033/head
Ari Parkkila 2018-05-16 14:14:37 +03:00
parent 9c62ea311d
commit c8287e5470
1 changed files with 2 additions and 4 deletions

View File

@ -282,21 +282,19 @@ void ATHandler::process_oob()
if (!(_fileHandle->readable() || (_recv_pos < _recv_len))) {
break; // we have nothing to read anymore
}
_start_time = rtos::Kernel::get_ms_count(); // time to process next (potential) URC
} else if (mem_str(_recv_buff, _recv_len, CRLF, CRLF_LENGTH)) { // If no match found, look for CRLF and consume everything up to CRLF
consume_to_tag(CRLF, true);
} else {
if (!fill_buffer()) {
reset_buffer(); // consume anything that could not be handled
break;
}
_start_time = rtos::Kernel::get_ms_count();
}
}
_at_timeout = timeout;
}
tr_debug("process_oob exit");
flush(); // consume anything that could not be handled
unlock();
}