LoRaWAN™ Application Configuration

Application Configuration

This section provides you with information on how to configure the SAM R34-based LoRaWAN™ application examples on Advanced Software Framework 3 (ASF3) to be able to join the network server/join server based on the provisioning parameters used to register/enroll a device.

Every application example on ASF3 pertaining to the SAM R34 device/WLR089U0 module has an application configuration file called conf_app.h, which is available at PACKAGE_ROOT/src/config.

AppConfig.png

1

This application provides the method of end-device activation.

#define DEMO_APP_ACTIVATION_TYPE OVER_THE_AIR_ACTIVATION
 //#define DEMO_APP_ACTIVATION_TYPE ACTIVATION_BY_PERSONALIZATION

2

This application provides the message type for sending data from the end-device.

#define DEMO_APP_TRANSMISSION_TYPE UNCNF
 //#define DEMO_APP_TRANSMISSION_TYPE CNF

3

This application mentions the port for uplink data.

#define DEMO_APP_FPORT 1

4

This application can modify or set the DevEUI (64-bit) to be used with OTAA. The SAMR34 Xplained Pro board has the DevEUI stored in its EDBG controller; the user has to define EDBG_EUI_READ as 1 to read the DevEUI from edbg and to set it. Otherwise, the value DEMO_DEVICE_EUI configured in conf_app.h will be used as a DevEUI.

By default, EDBG_EUI_READ is defined in the project properties as symbols.

The WLR089 Xplained Pro board has the DevEUI stored in its internal flash; the user has to define MODULE_EUI_READ as 1 to read the DevEUI from flash and to set it. Otherwise, the value DEMO_DEVICE_EUI configured in conf_app.h will be used as a DevEUI.

By default, MODULE_EUI_READ is defined in the project properties as symbols.

#define DEMO_DEVICE_EUI {0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07}

5

The application can modify or set the AppEUI (64-bit) to be used with OTAA.

#define DEMO_APPLICATION_EUI {0xDA, 0xBB, 0xAD, 0x00, 0xDA, 0xBB, 0xAD, 0x00}

6

This application can modify or set the AppKey (128-bit) to be used with OTAA.

#define DEMO_APPLICATION_KEY {0xBA, 0xAD, 0xF0, 0x0D, 0xBA, 0xAD, 0xF0, 0x0D, 0xBA, 0xAD, 0xF0, 0x0D, 0xBA, 0xAD, 0xF0,0x0D}

7

Ensure class A device is defined.

#define DEMO_APP_ENDDEVICE_CLASS CLASS_A

8

Gateways usually only support 8+1 channels (also known as a SUBBAND). The NA/AU Regional band has 64+8 channels. Therefore, there are eight SUBBANDs in the case of NA/AU region. The application by default is configured to work in SUBBAND 1. Change the SUBBAND value according to the gateway/NS configuration.

© 2024 Microchip Technology, Inc.
Notice: ARM and Cortex are the registered trademarks of ARM Limited in the EU and other countries.
Information contained on this site regarding device applications and the like is provided only for your convenience and may be superseded by updates. It is your responsibility to ensure that your application meets with your specifications. MICROCHIP MAKES NO REPRESENTATIONS OR WARRANTIES OF ANY KIND WHETHER EXPRESS OR IMPLIED, WRITTEN OR ORAL, STATUTORY OR OTHERWISE, RELATED TO THE INFORMATION, INCLUDING BUT NOT LIMITED TO ITS CONDITION, QUALITY, PERFORMANCE, MERCHANTABILITY OR FITNESS FOR PURPOSE. Microchip disclaims all liability arising from this information and its use. Use of Microchip devices in life support and/or safety applications is entirely at the buyer's risk, and the buyer agrees to defend, indemnify and hold harmless Microchip from any and all damages, claims, suits, or expenses resulting from such use. No licenses are conveyed, implicitly or otherwise, under any Microchip intellectual property rights.