diff --git a/TNC/SerialPort.cpp b/TNC/SerialPort.cpp index a2ce989..36685bd 100644 --- a/TNC/SerialPort.cpp +++ b/TNC/SerialPort.cpp @@ -81,7 +81,6 @@ extern "C" void startSerialTask(void const* arg) } uint8_t c = evt.value.v; - INFO("%02x - %c", c, c); switch (state) { case WAIT_FBEGIN: if (c == FEND) state = WAIT_FRAME_TYPE; @@ -107,6 +106,7 @@ extern "C" void startSerialTask(void const* arg) uint32_t delay = (last_sent_time + 50) - current_sent_time; osDelay(delay); } + last_sent_time = current_sent_time; frame = hdlc::acquire_wait(); state = WAIT_FBEGIN; break; @@ -132,7 +132,7 @@ extern "C" void startSerialTask(void const* arg) if (not frame->push_back(FEND)) { hdlc::release(frame); state = WAIT_FBEGIN; // Drop frame; - frame = hdlc::acquire(); + frame = hdlc::acquire_wait(); } break; default: