Skip to content

Latest commit

 

History

History
58 lines (44 loc) · 3.55 KB

LoRaWAN-TTN.md

File metadata and controls

58 lines (44 loc) · 3.55 KB

LoRaWAN The Things Network

This tutorial provides you an example of using Cosmic LoRa Aurora to send data to The Things Network.

Topology

LoRaWAN

Requirements

Prerequisites

  • Having an The Things Network account
  • Connect the LoRaWAN Gateway RAK 7268 to the Things Network, you can follow this tutorial.
  • Install CH340 Driver
  • Install LoRaWAN Library
    1. Download Library
    2. Unzip the Library into one Folder
    3. Copy the one folder into your Arduino -> libraries
    4. Confirm whether the library is properly installed by opening the Arduino IDE. Check if File -> Examples -> Antares LoRaWAN is exist.

Source Codes

make sure you use the appropiate code. please double check your cosmic board version.

Step by Step

Register the End Device to The Things Network

  1. Login to your TTN account.
  2. Create an Application in the TTN.
  • Application Creation
  • Application Creation 2
  1. Register End Device. This step is to register your LoRa Aurora to TTN.
  • Register End Device
  • Register End Device 2
  • Register End Device 3
  1. End Device is Registered. End Device is Registered

Program the End Device

  1. Plug the Cosmic LoRa Aurora boards to your Laptop.
  2. COM Port should be activated. (If not activated? Install CH340 driver).
  3. Setup in Arduino IDE : Pick the appropriate board : Tools → Board → ESP32 (If not listed? Install ESP32 Board)
  4. Load LoRaWAN code to Arduino IDE.
  5. Modify the code using your registered TTN parameters of Device Address, Application Session Key & Network Session Key.
  6. Click Verify then Click Upload to Board. (Error compile? Make sure do the Prerequisites)
  7. Open Serial Monitor of Arduino IDE. Set the Baud Rate as stated in Serial.begin of the code. Some debug info should be appeared stated it transmits some data to TTN. Serial Monitor
  8. Check your TTN Console. Some data must be shown. YEEAAYY Congrattzz!! You are successfully sending LoRaWAN to TTN. Data is Sent Data is Sent