How to connect the ULPLORA device with ChirpStack



Introduction

In this tutorial, we are going to send temperature data to the ChipStack platform. To do this project you first need to install the ChipStack and set up a communication gateway. Here we use the device called ULPLORA which was developed by the ICFOSS community. ULPLORA is a modified version of Arduino pro mini with Lora connectivity. DHT22 sensor is used to measure temperature and humidity. The sensor data will send through Lora and it will be captured by the near gateways then it will send to the ChipStack platform. We need to decode the data in the ChipStack platform. The live data can be viewed in ChipStack itself while the whole data further accessible from influxdb.


Create a device profile

The first step to this communication is a creation of a device profile. In the ChipStack platform, you need to select the device profile option and fill in all the required fields carefully. Make sure the lorawan mac version is set to 1.0.3.

Create an application
Now you may proceed with the creation of an application by clicking the applications options in the left navbar menu. Fill in all the required fields and create the application.
Create a device
Now it's time to create a device within your application. Go to your application and create a device.

Get keys
After the successful creation of the device, select that device and find configuration details that contain authentication keys. First, generate all the keys and you need to copy the Hex Array of keys for further use in the Arduino code.
Setup decoder
and finally, one more step needs to do in this platform. Go to the Device profile -> Codec. Choose Custom JavaScript codec functions. Here we need to write the decoding logic of the sensor data that we were sending.


Setup device

Now you need to assemble the device and upload the code. In this code, you need to replace 3 things that are NWKSKEY, APPSKEY & DEVADDR. 


Device connections



  • DHT OUT to - ULP Pin 7
  • GND - GND
  • VCC to 3.3V

After successful uploading of the code opens the serial monitor.



Now go to your device page and check the device data tab.


Goto to the activation tab and make sure the uplink and downlink frame counter is set to zero every time you reset your device.



Now the data is coming from the end device to our Chirpstack platform by using Lora communication.




Comments

Popular Posts