Sodaq Tatu + LoRa Bee + GPS Bee, how to set up connection?


Hello there!

New to the field, but trying to set up a lorawan connection. I'm using:

Sodaq Tatu + LoRa Bee RN2483 (and in a later stage the GPS Bee, not connected yet)

At this point I have followed these instructions as I believe succesfully, till step 4.
The tatu is powered, lorabee connected, antenna connected, and I can succesfully upload code.

However, with the demo code (step 4) from the Sodaq RN2483 library I can't seem to get a succesful connection. (

My questions;
- How do I exactly know if I'm in the range of a gateway? On the map ( it seems i'm just on the edge of the range... probably problem no 1?

-For the network key and application session key I have used the default as suggested. What do I use for my device adress? I now used the adress as I claimed here is that correct? (see part of code below)

I'm more an occasional Arduino user so this all is quite new to me, but hey figuring it out bit by bit.. hope anyone can help!


const uint8_t devAddr[4] =
0x02, 0x01, 0x17, 0x01
// this should be unique for your device/node. 02:01:17:xx > 02:01:17:01

const uint8_t appSKey[16] =
{0x2B, 0x7E, 0x15, 0x16, 0x28, 0xAE, 0xD2, 0xA6, 0xAB, 0xF7, 0x15, 0x88, 0x09, 0xCF, 0x4F, 0x3C};
// default one which is identitcal to the network key

const uint8_t nwkSKey[16] =
{0x2B, 0x7E, 0x15, 0x16, 0x28, 0xAE, 0xD2, 0xA6, 0xAB, 0xF7, 0x15, 0x88, 0x09, 0xCF, 0x4F, 0x3C};
// changed this from

Amsterdam - GPS Location Tracking, wearable, suggestions?

Devaddres is correct. Had the same problems in regards to connecting, basically there is no way (that I know of) to determine if you're in range of a gateway other then seeing packets from your node showing up. Best advice I can give is to check the map, make sure you're in range and use the setup outside. That way you'll at least know the structure of a building won't be a issue (isolated windows, concrete etc)


Also see this thread

(Chris Houwing) #4

This was for me a very good introduction for the GPS part :


ooh yes I already found this one! Gave me some insights yes. Thanks for sharing anyhow


my problem in the end was that I didn't turn on the lora bee connected on the sodaq tatu:

digitalWrite(20, HIGH); // switch on lorabee

in your void setup()

(Michael) #7


I am looking to setup a simple test to see if I can access the TTN cloud..

I have tried some of the sample code, but still struggling to get the script working. I have included all the relevant files, but getting the following errors:

Warning: platform.txt from core 'SODAQ AVR Boards' contains deprecated"{compiler.path}{}" {} {} "{build.path}/{archive_file}" "{object_file}", automatically converted to"{compiler.path}{}" {} {} "{archive_file_path}" "{object_file}". Consider upgrading this core.
sketch/lora.ino.cpp.o: In function `setup':
/Users/repair/Documents/Arduino/Lora 01/Sodaq_RN2483.h/lora/lora.ino:70: undefined reference to `Sodaq_RN2483::initABP(Stream&, unsigned char const*, unsigned char const*, unsigned char const*, bool)'
sketch/lora.ino.cpp.o: In function `loop':
/Users/repair/Documents/Arduino/Lora 01/Sodaq_RN2483.h/lora/lora.ino:95: undefined reference to `Sodaq_RN2483::sendReqAck(unsigned char, unsigned char const*, unsigned char, unsigned char)'
sketch/lora.ino.cpp.o: In function `__static_initialization_and_destruction_0':
/Users/repair/Documents/Arduino/Lora 01/Sodaq_RN2483.h/lora/lora.ino:62: undefined reference to `Sodaq_RN2483::Sodaq_RN2483()'
collect2: error: ld returned 1 exit status
exit status 1
Error compiling.

The code which I am testing with is as follows:

And using the following hardware:

Maybe there is somewhere I can download all of the libraries or an example file to get some basic testing up and running?

Thanks in advance..


(niels) #8

didnt test that code, but it looks like that example sketch just can't find the necessary libraries (you'll find them in the same github repo in the /src folder).. you need to include them and they need to be installed in your arduino environment (google will help you on how to do that), in this case include the necessary libs like this #include < Sodaq_RN2483.h> or secondly you can put them in the same folder as your sketch, in this case you have to include the libs like this: #include "Sodaq_RN2483.h"

(Michael) #9


Thanks for the reply - yes, that has fixed it, zipped up the src folder and imported it :wink:

Are there any good docs on how to send the data onto another cloud server or would Node-RED be best suited for this? Ideally I would be doing this via MQTT.



I don't know, but for now I am happy with it for prototyping. And the help I get from the community

(Michael) #11

Thanks pz1, that's a great start!

(niels) #12

you could also write yourself a super simple nodejs app that gets the data (near realtime) from TTN's MQTT service

(don't forget to install the necessary npm module: npm install mqtt

var mqtt    = require('mqtt');
var client  = mqtt.connect('tcp://');
client.on('connect', function () {
	'nodes/[your node's address]/packets',
	'nodes/[another address]/packets'

client.on('message', function (topic, message) {
  // message is Buffer .. now do what you want with it!, for example print it on the console like this:
  console.log('mqtt message:', message.toString());
client.on('connect', function(connack) { console.log('mqtt connack: ',connack); });
client.on('reconnect', function() { console.log('mqtt reconnected'); });
client.on('close', function() { console.log('mqtt closed'); });
client.on('offline', function() { console.log('mqtt offline'); });
client.on('error', function(err) { console.log('mqtt err: ',err); });