Connecting Dragino LG01 Gateway


(Paulo Sérgio) #22

Hi Shulti,

We need to start some service to start the gateway?
I have internet connection from gateway.

Some idea??
Many thanks !!
Paulo


(Paulo Sérgio) #23

Hi all….It is already connected :slight_smile:

The process was not running.

What I checked before:
teste3teste1teste2teste4

All configuration was ok.

So I follow this link :

https://www.thethingsnetwork.org/docs/gateways/troubleshooting/semtech-udp.html#gateway-not-detecte

1 - I check that program is not running see “Ensure the packet forwarder is running”

2 - Then I tried to find what i must to do to run the process.

I found this file: /etc/iot/scripts/lg01_pkt_fwd
And run like this:
/etc/iot/scripts/lg01_pkt_fwd&

After 2, 3 minutes it was connected to TTN.

I hope that this help someone.

Now that is connected, another step…I will try to see some packets traffic :slight_smile:
Paulo


(Kramer92) #24

In the latest firmware update LG01P has mqtt support, has anyone used their native mqtt offline yet?


(Ernstjan) #25

/etc/iot/scripts/lg01_pkt_fwd&

Helps me to active my gateway! Thnx!


(Kramer92) #26

This post was flagged by the community and is temporarily hidden.


(Labsud) #27

Hi,
Just received my Dragino LG01 and I’m having troubles.

I followed the tutorial (and I already built a gateway with a rpi+ic880 so I am ok with LoRawan basics) + applied suggested patch in this topic (I had to start lg01_pkt_fwd script and I created root/data folder) and I finally got a “connected” status on TTN channel. All firmware (MCU + Atheros) are up to date. But I don’t like the syslog :

Tue Jul 24 07:56:21 2018 kern.notice syslog: [IoT]: DNS Resolve Check: FAIL
Tue Jul 24 07:58:17 2018 kern.notice syslog: [IoT]: Internet Connection Check: FAIL
Tue Jul 24 07:58:19 2018 kern.notice syslog: [IoT]: DNS Resolve Check: FAIL
Tue Jul 24 07:58:29 2018 daemon.err uhttpd[1891]: ls: /dev/ttyUSB*: No such file or directory
Tue Jul 24 07:58:29 2018 daemon.err uhttpd[1891]: ls: /dev/ttyUSB*: No such file or directory
Tue Jul 24 07:59:32 2018 daemon.err uhttpd[1891]: ls: /dev/ttyUSB*: No such file or directory
Tue Jul 24 07:59:32 2018 daemon.err uhttpd[1891]: ls: /dev/ttyUSB*: No such file or directory
Tue Jul 24 08:00:00 2018 cron.info crond[1838]: USER root pid 4350 cmd checkdog
Sun Jan 1 00:00:05 2012 cron.err crond[1838]: time disparity of -3450719 minutes detected
Sun Jan 1 00:01:57 2012 kern.notice syslog: [IoT]: Internet Connection Check: FAIL
Sun Jan 1 00:01:59 2012 kern.notice syslog: [IoT]: DNS Resolve Check: FAIL

And obviously, GLOBAL led stays off.

Three things : no internet connection detected (but ping command are ok) and the ntp simply seems to crash and I cannot get my node connected (which works well with my rpi+ic880 gtw). I also can’t see the uart dialog between mcu and atheros (running “telnet localhost 6571” command from SSH terminal).

For the NTP issue I forced to reach fr.pool.ntp.org and it seems to work better.

Any idea ?


(Glbaum) #28

I was seeing similar errors on mine before however, I was not getting a connected status on TTN at the time so if you are seeing yours as connected perhaps the issues are different. I haven’t checked my syslog since I’ve gotten mine running and connected but I’ll have to do so when I get home later today. I can at least confirm that the Global LED on mine was at the very least on the last time I had looked at the gateway last evening.

I’ll have to report back to you when I have access to gateway.


(Labsud) #30

Ok I think I found the issue. So first, I only tested ABP to eliminate potential downlink problem. So apparently, in EU868 frequencies are rolling to minimize radio band use and so minimize duty cycle (correct me if I’m wrong). So for a mono-canal gateway it’s a big problem … So forcing my node to use only one frequency (868.1MHz in my case) solved the problem. Almost all packets are received (some times one is missing, I guess the gateway is busy by another node in the building).

Here my discussion about the node part : https://github.com/GrumpyOldPizza/ArduinoCore-stm32l0/issues/26

EDIT : I found the solution for lg01_pkg_fwd script that do not start automatically. In the iot-deamon file (which is start on boot) we found this :

#Check What Service we use
	service=`uci get iot-services.general.server_type`
	if [ "$service" != "disabled" ];then
		script_name=`uci get $service.general.routine_script`
		script=$IOT_DIR$script_name
		
		# Kill possible running daemon;
		servpid=`ps w| grep $script | grep -v grep | awk '{print $1}'`
		if [[ ! -z "$servpid" ]]; then 
			killall $script_name
		fi
		
		#start services 
		#check script type
		if [ "${script%.lua}" != "$script" ]; then
			lua $script &
		else
            $script 2>&1 > /dev/null &
		fi 
	fi

The problem is that there is no lorawan.general.routine_script configured. The fix is simple : edit /etc/config/lorawan and add option “routine_script ‘lg01_pkt_fwd’” to config “settings ‘general’” and reboot :wink:

EDIT #2 : I found another bug … SF11 and SF12 are not supported and the SF settings sent to TTN server are wrong. I know that because I compared with my “real” gateway. It shows that my node is correctly configured but LG01 seems to receive nothing when Dragino is configured SF11 or SF12, I don’t know why … And when it’s received (with SF7 to SF10) it’s not well reported : real SF7 is reported as SF12BW125. Real SF10 is reported as SF7BW125 …

EDIT #3 : … suddently SF are well reported to TTN server … without doing anything … strange … but SF11 and SF12 still not working


DRAGINO problems and solutions topic
(Jota) #31

Hi,

I’m issuing the same problem as labsud. Every frame with SF11 or SF12 never appear into gateway traffic. And as you can see, the same frame as seen in the gateway trafic, and in the application data don’t show the same SF

Into gateway traffic:

{
  "gw_id": "eui-xxxxxxxxxxxxxxxx",
  "payload": "xxxxxxxxxxxxxxxxxxxxxxxxxxxx",
  "lora": {
"spreading_factor": 9,
"bandwidth": 125,
"air_time": 185344000
  },
  "coding_rate": "4/5",
  "timestamp": "2018-07-31T15:56:06.240Z",
  "rssi": -46,
  "snr": 7.8,
  "dev_addr": "xxxxxxxx",
  "frequency": 868100000000000
}

Into application data:

{
  "time": "2018-07-31T15:56:05.923526878Z",
  "frequency": 868.1,
  "modulation": "LORA",
  "data_rate": "SF10BW125",
  "coding_rate": "4/5",
  "gateways": [
    {
      "gtw_id": "eui-xxxxxxxxxxxxxxxx",
      "timestamp": 859898932,
      "time": "2018-07-31T15:56:04.782568Z",
      "channel": 5,
      "rssi": -128,
      "snr": -15,
      "latitude": 45.xxxxx,
      "longitude": 5.xxxxx,
      "altitude": 2xx
    },
 ... other gateway but not dragino-lg01...
  ]
}

Because of the error in SF on gateway traffic, the gateway doesn’t appear into the application data.
This problem emerge only with some SF, I still haven’t test them all, and I may update a list of the buggy ones.

Joris


(Ernstjan) #32

Is there a fix for this problem? So, I have the same problem.


(Jota) #33

Which one are you issuing? both?

I haven’t find any fix, sorry. Here or there ( [LG01] Same packet, twice in application console ) I get no solution…


(Thomas Kämmerer) #34

It is neccessary to remove also ‘www.google.com’ from the host list. Google refuse the usage of ICMP against the site. Just pick another website - check with fping before - which allows the ICMP