diff --git a/libraries/AP_Frsky_Telem/AP_Frsky_SPort.cpp b/libraries/AP_Frsky_Telem/AP_Frsky_SPort.cpp index c4dd68e481..ee22bc40de 100644 --- a/libraries/AP_Frsky_Telem/AP_Frsky_SPort.cpp +++ b/libraries/AP_Frsky_Telem/AP_Frsky_SPort.cpp @@ -43,7 +43,10 @@ void AP_Frsky_SPort::send(void) } for (int16_t i = 0; i < numc; i++) { - int16_t readbyte = _port->read(); + uint8_t readbyte; + if (!_port->read(readbyte)) { + break; + } if (_SPort.sport_status == false) { if (readbyte == FRAME_HEAD) { _SPort.sport_status = true;