Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The Things Network v3 #36

Open
hardillb opened this issue Nov 12, 2021 · 6 comments
Open

The Things Network v3 #36

hardillb opened this issue Nov 12, 2021 · 6 comments

Comments

@hardillb
Copy link

Hi,

Are there any instructions for setting up the Gateway Hat with the new v3 Things network setup?

@ryanbateman
Copy link

@hardillb FWIW, I managed to get it working using the RAKWireless repo here, following the instructions there regarding standard setup, then downloading the global_conf.json from the v3 console and using that to update the packet forward config.

@hardillb
Copy link
Author

hardillb commented Mar 2, 2022

@ryanbateman Thanks, I have mine working via that route, but it would be nice for PiSupply offer an update since they are still selling this hardware.

@ryanbateman
Copy link

@hardillb Yes, I very much agree.

@salmanfarisvp
Copy link

Thnaks, @ryanbateman Could you please add the instructions and do a pull request if possible? Thanks.

@ChristopherRush
Copy link
Contributor

ChristopherRush commented Aug 11, 2022 via email

@emendir
Copy link

emendir commented Jul 30, 2024

It took me a bit of research and trial and error, but I succeeded in the end.
Over the last three years the configuration options on TheThingsNetwork have changed often, so I don't know how long they'll stay valid for.

Here are my notes in which I documented what I learned. They're not step-by-step instructions, but for people already familiar with working with LoRaWAN and TheThingsNetwork, they should give you all the info you need to get it working.

LoRaWAN settings for working with the LoRa Node pHAT RAK811 and TheThingsNetwork

RAK811

The [[LoRa Node pHAT RAK811]] hardware and the RAK811 python library's LoRaWAN compatibility seem to be limited to a specific set of its specifications.
I deduce this from the configuration options documented here being a subset of all LoRaWAN specs.
Those configurations which I could not configure on the RAK811, I experimented with when trying to register the device on TheThinsNetwork, to find which configurations there resulting in the RAK811 working correctly.

Supported Configurations

Here are the configurations I know I can apply:

Given that we're working with
For these settings, I configured, on both the RAK811 and in the TheThingsNetwork console when registering a new device, the following:

RAK Config Name TTN Config Name Value
join_mode Activation mode OTAA
app_eui JoinEUI I chose a value myself
app_key AppKey generated by TTN
app_eui JoinEUI from RAK811 or generated by TTN

Fixed TTN Configurations

Here are the configurations that can't be applied/I didn't apply to the RAK811 which I had to apply in TheThingsNetwork console (while adding a device):

Configuration Value
Frequency Plan Europe 863-870 MHz (SF9 for RX2)
LoRaWAN Version LoRaWAN Specification 1.0.3
Regional Parameters version RP001 Regional Parameters 1.0.3 revision A

To see a list of the device's configuration that are set to explore further configuration options, run the following shell command on a raspberry pi to which a RAK811 is connected:

rak811v3 get-config lora:status

DevEUI

Preconfigured

The RAK811 pHAT has a pre-configured device EUI.
When the device is connected to a raspbery pi, the device EUI can be read by executing the following shell command on the raspberry pi:

rak811v3 get-config lora:status | grep DevEui

Manual

The RAK811 pHAT's DevEUI can be changed, in shell or in python, replacing the preconfigured device EUI, and persisting across reboots.

rak811v3 set-config lora:dev_eui 70XXXXXXXXXXXXXX
from rak811.rak811_v3 import Rak811

lora = Rak811()

DEV_EUI = "70XXXXXXXXXXXXXX"
lora.set_config(f'lora:dev_eui:{DEV_EUI}')

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants