IoT – exploration of LoRaWAN – part 2

At IoT – exploration of LoRaWAN – part 1 details were given of first steps in a LoRaWAN project.

This article documents some MCU boards used for prototyping solutions.

The Arduino Zero concept was chosen for a modern module supported by the Arduino IDE and with ample memory resources for the LoRaWAN protocol stack and application code and memory requirements.

The boards tested are ‘basic’ Zero boards using the Atmel SAMD21G18 MCU. None of the three boards discussed here had the ‘PRO’ EDBG chip / ‘Programming USB’ port, they had only the ‘Native USB’ port.

Wemos SAMD21 Arduino form

Above is the module under test.

As received, the module was defective, the ‘Native USB’ port was not recognised by Windows and cycled repetitively trying to enumerate. The problem was solved by rewriting the user row of the NVM (the fuses if you like) and rewriting the Arduino boot loader.

The board does not contain a USB serial console port, an ordinary 3V FTDI adapter was wired to the TX and GND pins on the module for Serial1 in the Arduino code.

The module was tested with a Modtronix Wireless SX1276 LoRa Module, 868MHz and 915MHz, +20dBm, 3.3V, U.FL Connector .

The serial console sketch output was logged over sufficient time to demonstrate reliability.

Wemos SAMD21 mini

Above is the module.

As received, the module was defective, the ‘Native USB’ port was not recognised by Windows. The problem was solved by rewriting the user row of the NVM (the fuses if you like) and rewriting the Arduino boot loader.

The board does not contain a USB serial console port, an ordinary 3V FTDI adapter was wired to the TX and GND pins on the module for Serial1 in the Arduino code.

The module was tested with a Modtronix Wireless SX1276 LoRa Module, 868MHz and 915MHz, +20dBm, 3.3V, U.FL Connector .

The serial console sketch output was logged over sufficient time to demonstrate reliability.

SparkFun Pro RF – LoRa, 915MHz (SAMD21)

 

Above is the module. It contains an integral RF95W LoRa radio module on the board underside.

The module worked properly out of the box.

The board does not contain a USB serial console port, an ordinary 3V FTDI adapter was wired to the TX and GND pins on the module for Serial1 in the Arduino code.

The serial console sketch output was logged over sufficient time to demonstrate reliability.

LoRaWAN

The same basic Arduino sketch was run on all devices, and two were run simultaneously (with different DEVID etc) and all worked reliably. The RSSI obtained with the Modtronix radio was about 10dB higher than the Sparkfun, the Modtronix has a power amplifier after the SX1276 chip.

Conclusions

The Sparkfun module worked out of the box with no problems, and is an obviously good choice with the integrated radio reducing wiring complexity.

The Wemos modules were not usable as supplied, and may present a challenge to newbies to rewrite the boot loader and NVM record if they are supplied as these ones were. Having rewritten the boot loader and properly protecting it, they have been reliable so far. They are cheap but they may not be good value, especially if you do not have the knowledge and equipment to repair badly configured product.

The Native USB port can be used for console output (SerialUSB), but unfortunately the USB port disconnects on reset, so for logging purposes Serial 1 and a separate USB adapter was used.