[LoRaWAN] Move to generalized IRQ check (PHY)

This commit is contained in:
StevenCellist 2024-08-16 00:05:55 +02:00
parent b401d11127
commit 32dc5babd4

View file

@ -1226,7 +1226,7 @@ int16_t LoRaWANNode::downlinkCommon() {
RADIOLIB_DEBUG_PROTOCOL_PRINTLN("Closing Rx%d window", i+1);
// check if the IRQ bit for Rx Timeout is set
if(!this->phyLayer->isRxTimeout()) {
if(!this->phyLayer->isIrqSet(RADIOLIB_IRQ_TIMEOUT)) {
break;
} else if(i == 0) {
@ -1248,7 +1248,7 @@ int16_t LoRaWANNode::downlinkCommon() {
this->rxDelayEnd = mod->hal->millis();
// if we got here due to a timeout, stop ongoing activities
if(this->phyLayer->isRxTimeout()) {
if(this->phyLayer->isIrqSet(RADIOLIB_IRQ_TIMEOUT)) {
this->phyLayer->standby(); // TODO check: this should be done automagically due to RxSingle?
if(this->modulation == RADIOLIB_LORAWAN_MODULATION_LORA) {
this->phyLayer->invertIQ(false);