Twitter icon
Facebook icon
LinkedIn icon
Google icon
Reddit icon
StumbleUpon icon
Del.icio.us icon

Run The Things Stack Network Server on a Raspberry Pi

Added to IoTplaybook or last updated on: 09/24/2021
Run The Things Stack Network Server on a Raspberry Pi

Story

I'm personally amazed by the LPWAN networks and the possibility to use public LoRaWAN networks with tiny low power devices. However I also find fascinating to run your own private LoRaWAN network for specific use cases. And now you can run it with a Raspberry Pi in a really simple way.

This solution uses The Things Stack LoRaWAN Network Server Open Source Edition using containers on balena.

Things used in this project

Hardware components

Raspberry Pi 4 Model B
Raspberry Pi 4 Model B
 
× 1

Newark

Software apps and online services

balenaCloud
balenaCloud
 
  Balena.io
balenaEtcher
balenaEtcher
 
  Balena.io

What is The Things Stack

If you don't know it The Things Stack is an example of a LoRaWAN network server. Previously know as The Things Network or TTN. Now The Things Stack is running on the The Things Industries clusters that are distributed worldwide. However, if you want to manage your own data without sharing it with any cloud provider, the data collected can’t leave your country, or other similar requirements, then the solution is to deploy The Things Stack LoRaWAN Network Server using balena on a Raspberry Pi.

Deploy the The Things Stack Network Server

To deploy the The Things Stack Network Server on your Pi go to the balenaHub project TTS-network-server here and click Fork this fleet.

balenaHub TTS-network-server project

balenaHub TTS-network-server project

You also can visit the project repo and click Deploy with balena

The-Things-Stack-balena github repository with Deploy with balena button

The-Things-Stack-balena github repository with Deploy with balena button

Clicking any of these deploy buttons, it will create a fleet on balenaCloud with all the necessary code to deploy your The Things Stack network server.

balenaCloud deploying the release of the The Things Stack

balenaCloud deploying the release of the The Things Stack

Click the Device online to see the services running.

balenaCloud device running the needed services for The Things Stack

balenaCloud device running the needed services for The Things Stack

Once the three services all running (postgresqlredis and stack), copy the local IP address of the Raspberry Pi and introduce it into your favourite browser with https. You also can use the balenaCloud Public Device URL.

Then the The Things Stack login page should appear.

To access The Things Stack use admin and as a password changeme.

The Things Stack console site

The Things Stack console site

Now you can Register gateways and create LoRaWAN applications into your private The Things Stack network server running on a Raspberry Pi with balena.

Please share the projects you build with this :-)

Credits

Marc Pous

Marc Pous

Developer Advocate at balena.io // Previous co-founder at thethings.iO // Founder IoT Stars, IoT Coffee Talk and IoT Barcelona

Xose Pérez

Xose Pérez

IoT developer. TTN Catalunya core member. Working for RAKwireless.

 

 

Hackster.io

This content is provided by our content partner Hackster.io, an Avnet developer community for learning, programming, and building hardware. Visit them online for more great content like this.

This article was originally published at Hackster.io. It was added to IoTplaybook or last modified on 09/24/2021.