GrumpyOldPizza/ArduinoCore-stm32l0

Handling network server mac commands

SloMusti opened this issue · 3 comments

Using this library, I have observed issues and device hangs on receiving mac commands from the network server, for example receiving something similar to this: https://lorawan-packet-decoder-0ta6puiniaut.runkit.sh/?data=0708f80084500709c8088450070a98108450070b68188450&nwkskey=&appskey=

How is this handled in this library. It appears like ti should be implemented at low level. Anyone has experience by using various public networks?

Requirement from a network provider provider:
The “Data rate ACK” and “Power Ack” can be set to 0. The network server is only retrying the message because the Channel Mask Ack bit is set to 0
So a proper response will be with ADR OFF
Data rate ACK 0
Channel Mask ACK 1
Power ACK 0

There appears to be necessary support here

static LoRaMacStatus_t AddMacCommand( uint8_t cmd, uint8_t p1, uint8_t p2 )
, investigating if this works or what must be done for it.

Downlink messages are handled here and mac commands processed:

ProcessMacCommands( LoRaMacRxPayload, 0, frameLen, snr );