DRAGINO problems and solutions topic part 1

Hi, if you are running Raspbian Jessie, a systemd script would help.

sudo vi /etc/systemd/system/pktfwd.service

[Unit]
Description=single_chan_pkt_fwd
After=syslog.target network-online.target
[Service]
Type=simple
ExecStart=/home/pi/lorawan_gateway/single_chan_pkt_fwd/single_chan_pkt_fwd
Restart=on-failure
RestartSec=10
KillMode=process
[Install]
WantedBy=multi-user.target

 systemctl daemon-reload  
 systemctl enable pktfwd  
 systemctl start pktfwd
2 Likes

It works! Please guide me to start the program 2 minutes after the reboot as connecting to the 4G ppp connection takes time. Many thanks! :slight_smile:

@kazi93 You can try with

ExecStartPre=/bin/sleep 120

in the [Service] section,
or if you know the interface name

ExecStartPre=/usr/lib/systemd/systemd-networkd-wait-online --interface=ppp

where ppp is the name of your LTE interface.

Fixed Dragino 915 Mhz.

For those who use the 915 Mhz frequency, they must select in their GW Dragino the frequency 902.3 Mhz and ready

2 Likes

Allthough gateway made by joining a Dragino shield and a Raspberry Pi is not considered acceptable for TTN, is it possible to join to the TTN net for testing purposes? Is there some mechanism that lock such a setup?..I succeeded yesterday to put this setup into service (since my other approach using a Lopy as nanogateway following Pycom indications did not work), and initially was accepted but it did not appear in my console as one of my gateways. In fact, sensor values reached the network and values were showned. The gateway was working correctly for hours…However, today I cannot let it work…some comment regarding this behaviour?

Hi.
Only I teach programming and Lora. I Have RPI3+Lora\GPS hat for my gateway, code https://github.com/tftelkamp/single_chan_pkt_fwd. Please tell me where in the code to output the information that I sent to the file, not uploading to the server.

@dragino @BoRRoZ @BjoernA @gonzalo @telkamp @Epyon @erwin

Hi ! My friends! Currently I am receiving " Hello World" message. However, I would like to connect the DS18B20 with the Lora shield v1.4, I tried and no success! I need to know which ports are available to connect the data pin of the sensor? Red >> 5V, Black >> Ground and I guess white is the data pin …

Many thanks in advance

http://codegist.net/code/ds18b20%20lorawan/

@BoRRoZ Thanks again. I am actually struggling with the ‘‘Dragino shield V1.4 : Pin mapping’’.

How should I really connect ? Receiving error in Arduino IDE 1.8 :

error: ‘lmic_pinmap’ does not name a type
const lmic_pinmap lmic_pins = {
^
exit status 1
‘lmic_pinmap’ does not name a type

I moved your post to this specialized dragino topic :sunglasses:

I downloaded a different code and got it working on the rpi/hat. This one does poll the server. I was only able to get 3 packets sent in the downlink. Haven’t been able to recreate it since.

I did by commenting die() too. Changing the pin config didn’t make a difference coz when I commented die() I got it working. Also I was able to get downlinks but only a few (till now 3). Have you got regular downlinks on your device? Also is there any way we can check if the nodes receive the downlinks?

Which library and sketch you use? Seems you use a wrong library? no related to hardware for this issue.

1 Like

Sorry. It was the wrong library. However, could you please update the v1.4 pin_mapping?

The default pin map is:
const lmic_pinmap lmic_pins = {
.nss = 10,
.rxtx = LMIC_UNUSED_PIN,
.rst = 9,
.dio = {2, 6, 7},
};

The jumper settings should like this: http://wiki.dragino.com/index.php?title=File:Lora_Shield_v1.4.jpg

1 Like

Hi everyone! Im new to LoRa technology. Im about to make a gateway using my Dragino 433MHz LoRa/GPS Hat and RPi 3B. I have read several tutorials including dragino wiki but they use the frequency either 915MHz and 868MHz connecting to TTN. And based on my research, 433MHz is not compatible with LoRaWAN TTN. Can someone please help me how to configure my gateway without connecting it to TTN? A big thank you in advance!

Hi Alnemarie, You could maybe try a free Loriot account. Best wishes, Ron

Hi All. Trying to use the dual_chan_pkt_fwd with an InAir9b but my radio isn’t being recognised.
with:
“pin_nss”: 6,
“pin_dio0”: 7,
“pin_nss_2”: 6,
“pin_dio0_2”: 7,
“pin_rst”: 0
in the global.conf.json file, despite these being the correct connections to the RPi.

However it is recognised when using single_chan_pkt_fwd with:
int ssPin = 6;
int dio0 = 7;
int RST = 0;
in main.cpp

These should surely be equivalent, so no idea what the problem could be.
Any ideas would be appreciated. Cheers Ron

Answering my own question.
This has to be inserted before the call to ReadRegister in initLoraModem in LoraModem.c

    digitalWrite(RST, LOW);
    delay(100);
    digitalWrite(RST, HIGH);
    delay(100);
1 Like

I’m trying to set up a Dragino LG01-S LoRa Gateway but have run into a problem.

It’s working fine but I would like to run a VPN client on the Dragino and create a connection back to my own VPN server.

I’m halfway there and can get the Dragino to connect to my VPN but it becomes inaccessible once connected and only stays connected for around 60 seconds. It does not respond to pings from the VPN server.

I guess that I am missing a firewall rule somewhere but, as I can’t connect to the Dragino once it is connected to the VPN, I can’t work out where/what the rule needs to be!

My VPN config creates an interface called tun0 so I have created a new interface called “vpn” in /etc/config/network and assigned tun0 to it. I’ve also added the vpn interface to the existing firewall WAN rule.

Has anyone managed to get a VPN working on the Dragino or does anyone have any experience getting a VPN client working on OpenWRT?