Skip to content

"IoT Made Easy!" - Microchip LoRaWAN Stack Opened for SAM R34 IC and WLR089U0 Module running on Microchip Studio IDE

License

Notifications You must be signed in to change notification settings

MicrochipTech/ATSAMR34_LORAWAN_ASFv3

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 

Repository files navigation

ATSAMR34_LORAWAN_ASFv3

"Wireless Made Easy!" - Microchip LoRaWAN Stack Opened for SAM R34 IC and WLR089U0 Module running on Microchip Studio IDE

Devices: | ATSAMR34 | WLR089U0

⚠ Disclaimer

THE SOFTWARE ARE PROVIDED "AS IS" AND GIVE A PATH FOR SELF-SUPPORT AND SELF-MAINTENANCE.

This repository contains unsupported example code intended to help accelerate client product development. It is not validated for production nor audited for security best-practices.

Note that while this repository is unsupported, Microchip welcome community contributions, and all pull-requests will be considered for inclusion into the repository.

Interact with peers in the community at LoRa Forum.

Resources

Clone/Download the current repo to get the package.

A la carte

  1. Introduction
  2. Hardware Platforms
  3. Software Requirements
  4. LoRaWAN Certification Test Tool
  5. Package Overview
  6. Sample Applications
    1. LoRaWAN Mote Application
    2. LoRaWAN Mote Application + ATECC608B_TNG
    3. RN Command Parser
    4. RN Command Parser + ATECC608B_TNG

Introduction

The Microchip LoRaWAN™ Stack (MLS) provides a solution for the LoRaWAN end-device that is used for Internet of Things (IoT) applications.

LoRa® is a wireless modulation technique designed to allow low-power end-devices to communicate over long range and at low data rates.

LoRaWAN is a wireless networking protocol which operates over LoRa communication layer and acts as Medium Access Control (MAC) layer.

LoRaWAN specification and its development is overseen by LoRa Alliance™. The specification is meant for secure communication of end-devices and ensures inter-operability within the LoRa network.

Microchip LoRaWAN Stack is Opened for SAM R34 IC and WLR089U0 Module where MAC and Radio layers are both provided as source code for self-support and self-maintenance.

MLS v1_0_P_6 release is pre-tested against LoRaWAN 1.0.4 Class A using official LoRa Alliance Test Tool (LCTT).

Hardware Platforms

Software Requirements

Note: The following Atmel Studio tools needs to be uninstalled before installation of Microchip Studio 7.0.2542 version. Otherwise, you may face error while loading the projects.
- Atmel Driver Files
- Atmel LibUSB0 Driver(x64)
- Atmel Segger USB Drivers(501e)
- Atmel WinUSB

  • A LoRa Network Server access

LoRaWAN Certification Test Tool

The LoRa Alliance® has developed a LoRaWAN® Certification Test Tool (LCTT) for all LoRa Alliance® device manufacturers to pre-test their devices before sending them to the Authorised Test Houses (ATHs) for formal LoRaWAN® Certification testing.

The LoRaWAN® certification tests for end node functionality, in other words it tests that node’s LoRaWAN protocol stack and application are compliant with the LoRaWAN specification.

Checkout the LoRa Alliance for more details.

The present software has been PRE-TESTED against the LoRaWAN® L2 Specification 1.0.4 (Class A only) for the following regions:

  • EU863-870
  • US902-928

And using the following setup:
  • LCTT version: LCTT v3.1.0_D1 | GUI v1.10.0
  • Gateway(s) used for EU campaign (OTAA, ABP): Picocell GW and Semtech GW (Picocell GW for all tests except SF12 steps)
  • Gateway(s) used for NA campaign (OTAA, ABP): Picocell GW
  • SAMR34 Xplained Pro Rev 4
  • WLR089U0 Xplained Pro Rev A/01
  • All testing have been done in Application mode using the LoRaWAN Mote Application since the LoRaWAN 1.0.4 test specification elaborated and standardised the command communication between the test Network Server and the test End Device.

For reference, checkout the folder MLS_SDK_1_0_P_6_Release/LCTT_TestReports and get access to the test reports.

Package Overview

The Microchip LoRaWAN Stack contains:

  • A Microchip Studio 7.0 project, which provides a reference application
  • The LoRaWAN stack components in a source code
  • Drivers, software timer, PDS, PMM and radio drivers for the LoRaWAN stack
  • The facility to support dynamic regional band switching within the supported bands

The package also contains the Migration Guide which provide all the information requested to migrate the MLS LoRaWAN applications implemented on MLS_SDK_1_0_P_5 available in SAM platforms (SAMR34, WLR) to MLS_SDK_1_0_P_6. The improvements and bugfixes are listed as well as the MLS API changes.

MLS provides APIs for following software modules:

  • LoRaWAN MAC Layer (MAC)
  • LoRaWAN Radio Layer (TAL)
  • Persistent Data Server (PDS)
  • Power Manager Module (PMM)
  • Hardware Abstraction Layer (HAL)

The APIs and the stack attributes are described in the SAM R34-R35 Microchip LoRaWAN Stack Software API Reference Manual.

LoRaWAN Stack Directory Structure

The following table provides the directory structure of the LoRaWAN stack code base (src/ASF/thirdparty/wireless/lorawan).

Directory Description
/hal Contains the implementation for the radio hardware interface, timers, etc
/mac Contains the headers and sources of the LoRaWAN MAC layer specification independent of regional parameters
/pmm Contains the Power Management Module (PMM)
/regparams Contains the implementation of the MAC layer functionality specific to the regional bands
/sal Contains the Security Abstraction Layer (SAL)
/services Contains modules scuh as software timer, PDS and AES
/sys Contains system modules such as task manager, power management and initialization
/tal Contains transceiver related headers and sources, drivers for supported transceivers

Sample Applications

LoRaWAN Mote Application

Application Target Location
EndDevice_Demo SAMR34 Xplained Pro MLS_SDK_1_0_P_6_Release/Enddevice_Demo/enddevice_demo_src_multiband_samr34_xpro
EndDevice_Demo WLR089U0 Xplained Pro MLS_SDK_1_0_P_6_Release/Enddevice_Demo/enddevice_demo_src_multiband_wlr089_xpro

The EndDevice_Demo application provides configuration for the application in src/config/conf_app.h where it is possible to configure the following parameters:

  • Sub band number
  • Activation methods (OTAA or ABP)
  • Type of transmission (confirmed or unconfirmed message)
  • Application port number (Fport 1-255)
  • Device Class (A or C)
  • Type of join Nonce (incremental or random)
  • Join parameters (OTAA or ABP)
  • Multicast parameters
  • Sleep duration in milliseconds
  • Periodic timer duration in milliseconds (used for periodic transmission option)

Note #1: In SAM R34 project, the macro EDBG_EUI_READ=1 is set by default in the symbols definition. This configuration can be use with SAM R34 Xplained Pro evaluation kit in order to use the EDBG EUI as DEVEUI key for Over-The-Air Join process. With a custom board which embed the SAM R34 IC, disable the macro EDBG_EUI_READ=0 and fill your own DEVEUI key in the definition of DEMO_DEVICE_EUI located in the file src/config/conf_app.h.

Note #2: In WLR089U0 project, the macro MODULE_EUI_READ=1 is set by default in the symbols definition. This configuration can be use either with WLR089U0 Xplained Pro evaluation kit or with custom board.

Checkout the SAM R34 MLS Getting Started Guide to get details on the application configuration and how to flash and run the project.

LoRaWAN Mote Application + ATECC608B_TNG

Application Target Location
EndDevice_Demo_ecc608 SAMR34 Xplained Pro MLS_SDK_1_0_P_6_Release/Enddevice_Demo/enddevice_demo_src_multiband_ecc608_samr34_xpro
EndDevice_Demo_ecc608 WLR089U0 Xplained Pro MLS_SDK_1_0_P_6_Release/Enddevice_Demo/enddevice_demo_src_multiband_ecc608_wlr089_xpro

Use the present software and refer to the following resources to get more details :

RN Command Parser

Application Target Location
Parser SAMR34 Xplained Pro RN Command Parser
Parser WLR089U0 Xplained Pro RN Command Parser

Checkout the instructions and get the latest software from the RN Command Parser repository.

RN Command Parser + ATECC608B_TNG

Application Target Location
Parser_ECC608 SAMR34 Xplained Pro RN Command Parser + ATECC608B_TNG
Parser_ECC608 WLR089U0 Xplained Pro RN Command Parser + ATECC608B_TNG

Checkout the instructions and get the latest software from the RN Command Parser repository.

About

"IoT Made Easy!" - Microchip LoRaWAN Stack Opened for SAM R34 IC and WLR089U0 Module running on Microchip Studio IDE

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages