Fix sx126x error log logic

This commit is contained in:
Jonathan Bennett 2024-04-14 14:36:11 -05:00
parent 1447148811
commit 00d4c011c7

View File

@ -287,7 +287,7 @@ template <typename T> bool SX126xInterface<T>::isChannelActive()
result = lora.scanChannel();
if (result == RADIOLIB_LORA_DETECTED)
return true;
if (result != RADIOLIB_ERR_WRONG_MODEM)
if (result != RADIOLIB_CHANNEL_FREE)
LOG_ERROR("Radiolib error %d when attempting SX126X scanChannel!\n", result);
assert(result != RADIOLIB_ERR_WRONG_MODEM);