Merge pull request #11241 from aabadie/pr/pkg/loramac_duty_cycle
pkg/semtech-loramac: provide a way to disable dutycycle
This commit is contained in:
commit
61d7b205b8
@ -40,6 +40,7 @@
|
||||
|
||||
#include "semtech_loramac.h"
|
||||
#include "LoRaMac.h"
|
||||
#include "LoRaMacTest.h"
|
||||
#include "region/Region.h"
|
||||
|
||||
#ifdef MODULE_PERIPH_EEPROM
|
||||
@ -427,6 +428,9 @@ void _init_loramac(semtech_loramac_t *mac,
|
||||
primitives->MacMlmeIndication = mlme_indication;
|
||||
LoRaMacInitialization(&semtech_loramac_radio_events, primitives, callbacks,
|
||||
LORAMAC_ACTIVE_REGION);
|
||||
#ifdef DISABLE_LORAMAC_DUTYCYCLE
|
||||
LoRaMacTestSetDutyCycleOn(false);
|
||||
#endif
|
||||
mutex_unlock(&mac->lock);
|
||||
|
||||
semtech_loramac_set_dr(mac, LORAMAC_DEFAULT_DR);
|
||||
|
||||
@ -66,6 +66,11 @@ for US915 region.
|
||||
|
||||
The default region is `EU868`.
|
||||
|
||||
**For testing purpose**, it is possible to disable the duty-cycle restriction
|
||||
implemented in the MAC layer with the `DISABLE_LORAMAC_DUTYCYCLE` macro:
|
||||
|
||||
CFLAGS=-DDISABLE_LORAMAC_DUTYCYCLE LORA_REGION=US915 LORA_DRIVER=sx1272 make ...
|
||||
|
||||
## Using the shell
|
||||
|
||||
This application provides the `loramac` command for configuring the MAC,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user