Add additional check for full duplex mode

This commit is contained in:
Andy CA6JAU 2018-02-22 00:03:27 -03:00
parent 48d61d2721
commit a12d757ff2
2 changed files with 8 additions and 1 deletions

View file

@ -206,6 +206,13 @@ uint8_t CSerialPort::setConfig(const uint8_t* data, uint8_t length)
bool ysfLoDev = (data[0U] & 0x08U) == 0x08U;
bool simplex = (data[0U] & 0x80U) == 0x80U;
#if !defined(DUPLEX)
if (!simplex) {
DEBUG1("Full duplex not supported with this firmware");
return 6U;
}
#endif
m_debug = (data[0U] & 0x10U) == 0x10U;