The gateway seems to work. I added him in the ttn production environment console. It seems that this dragino wiki page is already a bit outdated. I couldn’t build a node, because in my opinion the example is not working with the production environment.
Now I’m searching for a tutorial to build a node (raspberry pi + dragino hat), which works with the production environment. Does anyone know a good tutorial or could someone already successfully create a lora node with raspberry pi and dragino?
Many many thanks, already in advance for any help or helpful tips.
The good news is that the wiki is mostly OK. In the end you can get ABP to work OK between an “Arduino/Dragino shield” node and R.Pi/Dragino Hat gateway to the TTN Prod environment - but like all “single channel” solutions (I think), not all messages will get through - (N.B. they would if you had a “multiple channel” solution)
It seems you are using 2 x R.Pi? The following is more for R.Pi and Arduino, but hopefully it proves useful
ABP works OK, but OTAA doesn’t because (I think) the “downlink” part doesn’t work - if anyone has managed to do this for LMIC/DRAGINO, It would be great if they could post back how they did it
For the Arduino code,
Remember to use the LMIC library and use the following formats in TTN
DEVADDR - HEX
NWKSKEY - MSB
APPSKEY - MSB
Check that you are using the following pin mapping
const lmic_pinmap lmic_pins = {
.nss = 10,
.rxtx = LMIC_UNUSED_PIN,
.rst = 9,
.dio = {2, 6, 7},
};
Temporarily change the timeout from 60 to 1 e.g. const unsigned TX_INTERVAL = 1;
but even though you have set this extremely low, a message only turns up in the TTN backend about once a minute and lots of messages are ignored. Once you have proved connectivity, set the timeout back to 60 and you will get a higher percentage of messages being received (up to 1 in 3 getting though).
Tanks for your answer. Finally I got this working. Falsely I used OTAA to connect to ttn. This isn’t working with single channel gateway. So I switched to ABP and now it works.
Did you encounter any errors while compiling the code? I’m running an exactly similar setup but i’m getting the following error:
root@my6:~/single_chan_pkt_fwd-master# make
g++ -c -Wall base64.c
g++ -c -Wall main.cpp
main.cpp:166:1: error: expected ‘,’ or ‘;’ before ‘void’
void die(const char *s)
^
main.cpp: In function ‘void sendudp(char*, int)’:
main.cpp:324:23: error: ‘die’ was not declared in this scope
die("sendto()");
^
main.cpp: In function ‘int main()’:
main.cpp:553:21: error: ‘die’ was not declared in this scope
die("socket");
^
Makefile:14: recipe for target 'main.o' failed
make: *** [main.o] Error 1
root@my6:~/single_chan_pkt_fwd-master# nano main.cpp
TTN made changes on Last week (March 17) and as a result the Single Channel Gateway software for the Pi, linked in your post, no longer works with TTN.
Hi all,
I am trying to make a node with dragino and raspberry pi3 but i am not sure where to start, can somebody please guide me? or if someone has a sample code of a node to send dummy values to a gateway? I wil be really thankful.
Hi all,
I am new to Lora and i find it to confusing as i havent worked with anything similar to lora before. I hve two dragino lora hat v1.4 . I want to send some random values to a gateway every 1 or 2 minutes. But i am not sure where to start. I have seen some tutorials for the lora gateway with raspberry pi3 but i havent seen any tutorial for the lora node with raspberry pi3. Can somebody guide where to start? Which will be the good starting point? or if somebody has an example to make a lora node with raspberry pi3 and dragino. thanks
Hi Borroz,
Thanks for your reply.i made a gateway with the help of same tutorial you have mentioned but i am not able to get the node running. its showing the following errors …
Unknown interrupt flags for FSK
FAILURE
radio.c:630
Are you using some other hat for raspberry pi ? if yes then which one?
and yes i already have registered,
gateway is showing as connected. but application status is never seen… i dont know whether i have done the TTN configuration wrong or there is some problem at the dragino end…
what does that error mean? “OhOh. Unknown interrupt flags for FSK”
and is this a right respone? “[634ff] (1513260661) Thu Dec 13 …”
if some one else can help me in this regard…
understand that you build a single channel gateway with an RPI and Dragino hat.
these are only advised for tests and do not have the full functionality on the TTN network.
so if you build a node, in your case also with a dragino hat, make sure that node and gateway are set to the same frequency.
Yes you r right.
I am also having problem in understanding the DEVEUI, DEVKEY, and DEVADDR. Where to get these? or we can assign some random?
I know we can get The APPEUI and ARTKEY from the TTN registered application and i am using that from the TTN but i am not sure about the DEVEUI, KEY and DEVADDR.
thanks