Skip to content

Commit

Permalink
Increase ADR ACK Counter only, if:
Browse files Browse the repository at this point in the history
- no frame reception
- frame reception not in RX1 and not in RX2
  • Loading branch information
mluis1 committed Jun 17, 2019
1 parent 6b6ca90 commit 6231a5d
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/mac/LoRaMac.c
Original file line number Diff line number Diff line change
Expand Up @@ -2985,10 +2985,11 @@ static bool CheckRetransConfirmedUplink( void )
return false;
}


static bool StopRetransmission( void )
{
if( MacCtx.MacFlags.Bits.McpsInd == 0 )
if( ( MacCtx.MacFlags.Bits.McpsInd == 0 ) ||
( ( MacCtx.McpsIndication.RxSlot != RX_SLOT_WIN_1 ) &&
( MacCtx.McpsIndication.RxSlot != RX_SLOT_WIN_2 ) ) )
{ // Maximum repetitions without downlink. Increase ADR Ack counter.
// Only process the case when the MAC did not receive a downlink.
if( MacCtx.NvmCtx->AdrCtrlOn == true )
Expand Down

0 comments on commit 6231a5d

Please sign in to comment.