# DRAGINO problems and solutions topic part 1

**URL:** <https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951>\
**Category:** \[obsolete\] SCPF\
**Created:** [August 14, 2017, 9:56am UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951 "2017-08-14T09:56:40Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![BoRRoZ](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/borroz/32/44234_2.png) [@BoRRoZ](https://www.thethingsnetwork.org/forum/u/BoRRoZ)\
**Post date:** [August 14, 2017, 9:56am UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951/1 "2017-08-14T09:56:40Z")

</div>

this topic is to share information about all the DRAGINO problems and solutions.

part 2 is **[HERE](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-2/19143)**

- [http://wiki.dragino.com/index.php?title=Lora/GPS\_HAT](http://wiki.dragino.com/index.php?title=Lora/GPS_HAT)
- [http://wiki.dragino.com/index.php?title=Connect\_to\_TTN](http://wiki.dragino.com/index.php?title=Connect_to_TTN)
- **[search ‘dragino’ on this forum](https://www.thethingsnetwork.org/forum/search?q=dragino)**
-

---

<div class="post-metadata">

**Author:** ![CamilaS](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/camilas/32/6359_2.png) [@CamilaS](https://www.thethingsnetwork.org/forum/u/CamilaS)\
**Post date:** [August 14, 2017, 9:57am UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951/2 "2017-08-14T09:57:30Z")

</div>

Hello,

I’m new here and I hope someone could help me, In follow configuration I have some problems:  
[http://wiki.dragino.com/index.php?title=Connect\_to\_TTN](http://wiki.dragino.com/index.php?title=Connect_to_TTN)

The Problem:

- I only can send the first package, but on the node I don’t recive “EV\_TXCOMPLETE”

- The count don’t change

In both devices are configuraded in interfaces as:  
 ![](https://www.thethingsnetwork.org/forum/uploads/default/original/2X/6/60d996304fe51da314a3e60bc8b6a15825eeef28.png)

- For the gateway I’m using: single\_chan\_pkt\_fwd

- For the node I’m using: lmic\_pi-master (ABP)

The gateway looks to be working  
 ![](https://www.thethingsnetwork.org/forum/uploads/default/original/2X/4/41865d8b697c862ff3d831ab10936dc09e3c5837.png)

![](https://www.thethingsnetwork.org/forum/uploads/default/original/2X/5/53fefbf6ef1515743a9905b831fa5e5978d4e189.png)

![](https://www.thethingsnetwork.org/forum/uploads/default/original/2X/a/ab269a15f60f24919be6377dd7cd619aaf187e84.png)

![](https://www.thethingsnetwork.org/forum/uploads/default/original/2X/8/81f285f95f5c60622ff6572dbb497dce8bb84e4d.png)

(Only for the first package)

But for the node, I Always send only the first package or recive a error or “OhOh. Unknown interrupt flags for FSK”. I don’t know what to change to made it Works

![](https://www.thethingsnetwork.org/forum/uploads/default/original/2X/3/3c3211672e23e366e5d3a407d608e6f4a8af6974.png)

![](https://www.thethingsnetwork.org/forum/uploads/default/original/2X/7/73edc9201575efdde6caaf5cdc307cda9b990217.png)

![](https://www.thethingsnetwork.org/forum/uploads/default/original/2X/3/3bd87d4fba417c924dcfac45bfbd6672489bdd65.png)

On the configuration I use the following formats in TTN:  
DEVADDR - HEX  
NWKSKEY - MSB  
APPSKEY -MSB

![](https://www.thethingsnetwork.org/forum/uploads/default/original/2X/0/0273297bab988e32e25ac0d539e338e28f7c3913.png)

![](https://www.thethingsnetwork.org/forum/uploads/default/original/2X/b/b303b3a3a2acfdcf042f1f4bea61f067dc7196ad.png)

On TTN I can see:

![](https://www.thethingsnetwork.org/forum/uploads/default/original/2X/a/addb2cf7984fd70f96995c5a388d0790e991e9df.png)

![](https://www.thethingsnetwork.org/forum/uploads/default/original/2X/6/6a4ddc8f598b250f05433c631672a163f7557de5.png)

---

<div class="post-metadata">

**Author:** ![Surya](https://www.thethingsnetwork.org/forum/letter_avatar_proxy/v4/letter/s/8e8cbc/32.png) [@Surya](https://www.thethingsnetwork.org/forum/u/Surya)\
**Post date:** [August 14, 2017, 9:32am UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951/3 "2017-08-14T09:32:02Z")

</div>

I am working with Dragino Lora shield v1.3 and Raspberry Pi 3 in building a single channel gateway and connected to Things network.

But my gateway shows that the status as not connected.

The server address I have tried with are 54.72.145.119, 52.169.76.203, 54.229.214.112. But the problem still exist. Can anyone help me please?

---

<div class="post-metadata">

**Author:** ![HaSch](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/hasch/32/35713_2.png) [@HaSch](https://www.thethingsnetwork.org/forum/u/HaSch)\
**Post date:** [August 12, 2017, 7:22am UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951/4 "2017-08-12T07:22:04Z")

</div>

> [@Single Channel Packet Forwarder part 2 \[Deprecated\]](https://www.thethingsnetwork.org/forum/t/single-channel-packet-forwarder-part-2-deprecated/5999/70):
>
> Has anyone tried using this code: [GitHub - bokse001/dual\_chan\_pkt\_fwd at dual\_chan\_pkt\_fwd\_up\_down](https://github.com/bokse001/dual_chan_pkt_fwd/tree/dual_chan_pkt_fwd_up_down) ont their Dragino Lora GPS hat? It says it can allow downlink on the hat and can be compatible with TTN. Here is the blog by the developer too: [The Things Network dual-channel up&downlink gateway – Hans Boksem](https://hansboksem.wordpress.com/2017/01/23/the-things-network-dual-channel-updownlink-gateway/)

Yes, I tried but it isn’t working on Dragino LoRa GPS hat. I contacted the developer and spoke to him but for now he hasn’t the time to look after the code. Maybe it helps if you contact him, too.

The dual channel code is only working with Uputronics board with 2 mounted RFM95 modules. If only 1 module is soldered, you can make a little change to the code to get it work.

---

<div class="post-metadata">

**Author:** ![rocketfarm](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/rocketfarm/32/20484_2.png) [@rocketfarm](https://www.thethingsnetwork.org/forum/u/rocketfarm)\
**Post date:** [August 14, 2017, 10:07am UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951/5 "2017-08-14T10:07:50Z")

</div>

I have a Dragino Lora Mini [http://wiki.dragino.com/index.php?title=LoRa\_Mini](http://wiki.dragino.com/index.php?title=LoRa_Mini) that I am really having a hard time connecting it to TTN.

The sketch compiles and uploads fine, but nothing happens after “-- STATUS” is printed t the console. The TTN gateway does not show any traffic.

This is my sketch

```
#include <TheThingsNetwork.h>
#include <CayenneLPP.h>
#include <SoftwareSerial.h>

// Set your AppEUI and AppKey
const char *appEui = "{MY_APP_EUI}";
const char *appKey = "{MY_APP_KEY}";

#define debugSerial Serial

SoftwareSerial loraSerial(10, 11); // RX, TX

// Replace REPLACE_ME with TTN_FP_EU868 or TTN_FP_US915
#define freqPlan TTN_FP_EU868

TheThingsNetwork ttn(loraSerial, debugSerial, freqPlan);
CayenneLPP lpp(51);

void setup()
{
  loraSerial.begin(9600);
  debugSerial.begin(9600);

  // Wait a maximum of 10s for Serial Monitor
  while (!debugSerial && millis() < 10000)
;

  debugSerial.println("-- STATUS");
  ttn.showStatus();

  debugSerial.println("-- JOIN");
  ttn.join(appEui, appKey);
}

void loop()
{
  debugSerial.println("-- LOOP");

  lpp.reset();
  lpp.addTemperature(1, 22.5);
  lpp.addBarometricPressure(2, 1073.21);
  lpp.addGPS(3, 52.37365, 4.88650, 2);

  // Send it off
 ttn.sendBytes(lpp.getBuffer(), lpp.getSize());

 delay(10000);

```

}

---

<div class="post-metadata">

**Author:** ![BoRRoZ](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/borroz/32/44234_2.png) [@BoRRoZ](https://www.thethingsnetwork.org/forum/u/BoRRoZ)\
**Post date:** [August 10, 2017, 9:51pm UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951/6 "2017-08-10T21:51:40Z")

</div>

[http://wiki.dragino.com/index.php?title=LoRa\_Mini](http://wiki.dragino.com/index.php?title=LoRa_Mini)

> <https://github.com/dragino/Arduino-Profile-Examples/blob/master/libraries/Dragino/examples/LoRa/LoRaWAN/Arduino_LMIC/Arduino_LMIC.ino>

---

<div class="post-metadata">

**Author:** ![Charles](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/charles/32/45146_2.png) [@Charles](https://www.thethingsnetwork.org/forum/u/Charles)\
**Post date:** [August 11, 2017, 12:33am UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951/7 "2017-08-11T00:33:08Z")

</div>

@rocketfarm  
you’re using a sketch with TheThingNetwork library which use a LoraWan device RN2483 (serial) Dragino Lora Mini has RFM95 device inside, so you must use LMIC stack as @BoRRoZ give you example

---

<div class="post-metadata">

**Author:** ![Srinivas](https://www.thethingsnetwork.org/forum/letter_avatar_proxy/v4/letter/s/ecccb3/32.png) [@Srinivas](https://www.thethingsnetwork.org/forum/u/Srinivas)\
**Post date:** [August 14, 2017, 2:00pm UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951/8 "2017-08-14T14:00:35Z")

</div>

Hey I just got the hat working and I can see the same data as you. I wanted to know how do you read the payload? Is it the actual data sent or do we have to convert it from ASCII to text? Also I have seen the data changes at the last byte/bytes, is there a reason for it? Because I thought the code sends the same data each time.

---

<div class="post-metadata">

**Author:** ![BoRRoZ](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/borroz/32/44234_2.png) [@BoRRoZ](https://www.thethingsnetwork.org/forum/u/BoRRoZ)\
**Post date:** [August 14, 2017, 2:28pm UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951/9 "2017-08-14T14:28:33Z")

</div>

> **[LoRaWAN For Raspberry Pi With Worldwide Frequency Support](https://www.hackster.io/glovebox/lorawan-for-raspberry-pi-with-worldwide-frequency-support-e327d2)**
>
> LoRaWAN LMIC 1.6 for Raspberry Pi with Dragino LoRA/GPS HAT or standalone RFM95W LoRa Module. By Dave Glover.

---

<div class="post-metadata">

**Author:** ![Srinivas](https://www.thethingsnetwork.org/forum/letter_avatar_proxy/v4/letter/s/ecccb3/32.png) [@Srinivas](https://www.thethingsnetwork.org/forum/u/Srinivas)\
**Post date:** [August 14, 2017, 3:38pm UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951/10 "2017-08-14T15:38:06Z")

</div>

I did contact him, haven’t received a reply yet. Did you manage to get the downlink working on the lora gps hat? Also I might sound like a noob, but on the application console on TTN, I have noticed a couple of byte changes on the payload. Why does this happen? Shouldn’t the node send the same data at all times?

---

<div class="post-metadata">

**Author:** ![CamilaS](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/camilas/32/6359_2.png) [@CamilaS](https://www.thethingsnetwork.org/forum/u/CamilaS)\
**Post date:** [August 14, 2017, 10:07pm UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951/11 "2017-08-14T22:07:33Z")

</div>

> [@Srinivas](#):
>
> I wanted to know how do you read the payload? Is it the actual data sent or do we have to convert it from ASCII to text?

When you talk about read the payload, is about the Picture on Application Data? If yes, on the code of [GitHub - ernstdevreede/lmic\_pi: Raspberry Pi port LoRaMAC in C / LoRaWAN in C http://www.research.ibm.com/labs/zurich/ics/lrsc/lmic.html](https://github.com/ernstdevreede/lmic_pi), is implemente to return on the App in format HEX. Or if you talking about the data in the output of the gateway (Base64) you can decoder with this: [https://lorawan-packet-decoder-0ta6puiniaut.runkit.sh/](https://lorawan-packet-decoder-0ta6puiniaut.runkit.sh/).  
From what I read, there is no data being sent in ASCII format because it requires a higher bandwidth.

> [@Srinivas](#):
>
> Also I have seen the data changes at the last byte/bytes, is there a reason for it? Because I thought the code sends the same data each time.

I’m no sure, but I think is for that:

- The data and a count sent:  
 ![](https://www.thethingsnetwork.org/forum/uploads/default/original/2X/8/8f057a21c20d8f34f6390a46a2f9fc403f4263aa.png)

- On the function do\_send():  
 ![](https://www.thethingsnetwork.org/forum/uploads/default/original/2X/7/7b06f2454c7f0d7a9de51cafe8c79e4074a922c9.png)

The diference about the data sent is the conter, because Always the code repeat the “Hello world!” + cntr and after save the data in the buf variable, the cntr change.

---

<div class="post-metadata">

**Author:** ![Srinivas](https://www.thethingsnetwork.org/forum/letter_avatar_proxy/v4/letter/s/ecccb3/32.png) [@Srinivas](https://www.thethingsnetwork.org/forum/u/Srinivas)\
**Post date:** [August 15, 2017, 1:58pm UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951/12 "2017-08-15T13:58:37Z")

</div>

Thank you so much. I was able to convert the app payload and gateway traffic.

---

<div class="post-metadata">

**Author:** ![HaSch](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/hasch/32/35713_2.png) [@HaSch](https://www.thethingsnetwork.org/forum/u/HaSch)\
**Post date:** [August 16, 2017, 7:37am UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951/13 "2017-08-16T07:37:57Z")

</div>

> [@HaSch](#):
>
> Has anyone tried using this code: [GitHub - bokse001/dual\_chan\_pkt\_fwd at dual\_chan\_pkt\_fwd\_up\_down](https://github.com/bokse001/dual_chan_pkt_fwd/tree/dual_chan_pkt_fwd_up_down) ont their Dragino Lora GPS hat? It says it can allow downlink on the hat and can be compatible with TTN. Here is the blog by the developer too: [The Things Network dual-channel up&downlink gateway – Hans Boksem](https://hansboksem.wordpress.com/2017/01/23/the-things-network-dual-channel-updownlink-gateway/)
> 
> Yes, I tried but it isn’t working on Dragino LoRa GPS hat. I contacted the developer and spoke to him but for now he hasn’t the time to look after the code. Maybe it helps if you contact him, too.
> 
> The dual channel code is only working with Uputronics board with 2 mounted RFM95 modules. If only 1 module is soldered, you can make a little change to the code to get it work.

Now, I’ve got the code working. The point is that in global\_conf.json you have to set pin\_rst to 3 instead of 0 as in README.md. Pins for Dragino hat are:

```
"pin_nss": 6,
"pin_dio0": 7,
"pin_nss_2": 6,
"pin_dio0_2": 7,
"pin_rst": 3,

```

The other pins can remain untouched.

As Dragino hat has only one RFM95 module you will get a single channel gateway, not a dual channel gateway (with up- and downlink). Therefore you have to comment out line 552 in LoraModem.c:

`// Die("Unrecognized transceiver");`

After that the GW will work fine.

---

<div class="post-metadata">

**Author:** ![Srinivas](https://www.thethingsnetwork.org/forum/letter_avatar_proxy/v4/letter/s/ecccb3/32.png) [@Srinivas](https://www.thethingsnetwork.org/forum/u/Srinivas)\
**Post date:** [August 15, 2017, 9:16pm UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951/14 "2017-08-15T21:16:16Z")

</div>

Hey, I am using the lora hat as a gateway. I know there has been some issues with using the hat as a gateway and the single packet code doesn’t support downlink. But is there any way I can check if downlink packets reach my gateway or not? I tried sending a downlink data from the ttn console but it is just scheduled (as expected) but shouldn’t it atleast try to send the data to the gateway? Does this have anything to do with the Fair access policy.

---

<div class="post-metadata">

**Author:** ![kersing](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/kersing/32/44777_2.png) [@kersing](https://www.thethingsnetwork.org/forum/u/kersing)\
**Post date:** [August 15, 2017, 10:02pm UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951/15 "2017-08-15T22:02:00Z")

</div>

A gateway needs to poll the back-end periodically for downlink packets (this ensures firewalls keep the connection active) Does the single channel gateway poll?

---

<div class="post-metadata">

**Author:** ![Srinivas](https://www.thethingsnetwork.org/forum/letter_avatar_proxy/v4/letter/s/ecccb3/32.png) [@Srinivas](https://www.thethingsnetwork.org/forum/u/Srinivas)\
**Post date:** [August 15, 2017, 10:40pm UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951/16 "2017-08-15T22:40:51Z")

</div>

I am not sure, I am using the single\_ch\_pkt\_fwd on the dragino gps hat.

---

<div class="post-metadata">

**Author:** ![kersing](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/kersing/32/44777_2.png) [@kersing](https://www.thethingsnetwork.org/forum/u/kersing)\
**Post date:** [August 16, 2017, 9:35am UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951/17 "2017-08-16T09:35:06Z")

</div>

Then may-be you need to check/investigate. Or do you expect us to do the work for you?

---

<div class="post-metadata">

**Author:** ![Srinivas](https://www.thethingsnetwork.org/forum/letter_avatar_proxy/v4/letter/s/ecccb3/32.png) [@Srinivas](https://www.thethingsnetwork.org/forum/u/Srinivas)\
**Post date:** [August 16, 2017, 8:41pm UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951/18 "2017-08-16T20:41:21Z")

</div>

I am able to receive packets from the ttn on my gateway. But it is the response packets sent after I send a packet received from the node. I am also able to ping my gateway pi, from a different device on a different network. How do I know if on sending a downlink packet the ttn sends a packet to my gateway pi?  
There is no firewall setting in place, I have the DMZ setup to forward all packets to my gateway pi, so it shouldn’t block anything. I am sorry but I do not know how to check if the gateway polls ttn or not, as I can see any packets between the gateway and ttn except while sending packets received from the node.

---

<div class="post-metadata">

**Author:** ![kersing](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/kersing/32/44777_2.png) [@kersing](https://www.thethingsnetwork.org/forum/u/kersing)\
**Post date:** [August 16, 2017, 9:51pm UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951/19 "2017-08-16T21:51:16Z")

</div>

You could check the code to see if it includes a downlink poll.

---

<div class="post-metadata">

**Author:** ![kazi93](https://www.thethingsnetwork.org/forum/letter_avatar_proxy/v4/letter/k/e274bd/32.png) [@kazi93](https://www.thethingsnetwork.org/forum/u/kazi93)\
**Post date:** [August 18, 2017, 6:28pm UTC](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951/20 "2017-08-18T18:28:31Z")

</div>

Hi! My friends! @telkamp @BoRRoZ @BjoernA@Harald_Naumann  
I have added the line in the crontab however, if you know any other possible way to keep it running. Many thanks in advance.

Note : Raspbian plus LoraHAT (rpi3)

Method 1 : which stops working once press ctrl+C or reboot system  
**#sudo /home/pi/lorawan\_gateway/single\_chan\_pkt\_fwd/single\_chan\_pkt\_fwd**

Method 2: looking for a method to keep it running in the background…

I added below in # sudo crontab e (unsuccessful)

\*/2 \* \* \* \* sudo /home/pi/lorawan\_gateway/single\_chan\_pkt\_fwd/single\_chan\_pkt\_fwd

OR

\*/2 \* \* \* \* /bin/sh -c sudo /home/pi/lorawan\_gateway/single\_chan\_pkt\_fwd/single\_chan\_pkt\_fwd`Preformatted text`

[Next page](https://www.thethingsnetwork.org/forum/t/dragino-problems-and-solutions-topic-part-1/8951.md?page=2)
