Dragino LoRa Iot kit with Chirp Stack

Hi There,
I moved from TTN cause I have LG01-N Single Channel Gateway, which is not support at all by TTN !! because it does not compatible with LoRaWAN.
They adviced me to go with ChirpStack in order to build m own network for Lora node mounted with Arduino and Gateway.

Any suggestions/ tutorials to get started ? I have read some discussion here, but no luck to find something to go ahead.

Thank you in advance.
Regards,
MoShawa

61H9-EhffgL.AC_SX466

Hi @MoShawa,

The first thing is connecting the gateway to Chirpstack.
Did you do it?

After that, the most important thing is to consider that LG01-N is a single frequency and Data Rate gateway, that you can select on the gateway.
So your devices must work only in that frequency and data rate.

Please, check your gateway is connected and we can go on.

Regards.

Hi @pulidoj,

Thank you for your response. after reading some forums I am working on install all chirpstack server components ( Gateway Bridge, Network Server and Application Server) using Ubuntu in order to connect my Lg01-N gateway, but I got stuck. I built all components and they all running without errors. but I am not sure about matching configuration between app server and lg01-n.

The LoRa App Server Web Interface doesnot appear on localhost:8080 !! I attached photo for the configuration in Lg01 which I made just three changes in lg01:
“serv_port_down”: 1700,
“serv_port_up”: 1700,
“server_address”: “localhost”,

Regards

in chrome browser I typed http://localhost:8080 and does not appear anything. is there specific ip for localhost that i am not aware ?

Hi,

You are going ahead, that’s great.
You must setup properly Server Address, you have to introduce the IP of your ubuntu server: http://YOUR_UBUNTU_SERVER_IP

After that you have to add your gateway into Chirpstack Application Server:
To enter you must go in Chrome into http://YOUR_UBUNTU_SERVER_IP:8080

To add your gateway you need the Gateway ID, in this case this is a84041…, as shown in the screenshot you sent.

Hello pulidoj,
So far, I am succeed to access Chirpstack application server via port 8080 through Ubuntu that installed in my pc ( my fault was to access web UI via Windows not inside Ubuntu :frowning: " maybe it is possible, but I don not know how "), though I putted all parameters for my gateway right on chirpstack application server, it is shown as never seen !

my configuration by photos please find them attached.
I appretiate your help.

regards
moShawaUploading: chstk-1-.JPG… Uploading: chstk-2.JPG… Uploading: chstk-3.JPG… Uploading: chstk-4.JPG… Uploading: chstk-5.JPG… Uploading: chstk-6.JPG…

I’m sorry, but pictures are not accessible.

Please, make some kind of link to access them.

chstk-7

I am sorry for delayed response cuz of pc lags.
Here you are …!!

Hi @MoShawa,

I think you are running your Chirpstack perfectly, but I guess you have only some problem with IPs of Dragino gateway and Ubuntu Server.

What’s your Gateway IP? I see it is connected through WiFi. No problem at all about this.
You selected as Server Address into Dragino’s Lorawan config 10.0.2.15. Is that the real IP of your Ubuntu Server?

You should access Chirpstack Application with no problem from a Windows computer in your LAN.
If your Ubuntu Server’s IP is 10.0.2.15, you should access from a device in your LAN through 10.0.2.15:8080.

I connected an OLG01-N and you can check different things to see if everything is working.

At gateway level, you can read logread in SSH connection.

You should see these pieces of code:

Wed Dec 30 10:39:56 2020 daemon.info lg01_pkt_fwd[3221]:
Wed Dec 30 10:39:56 2020 daemon.info lg01_pkt_fwd[3221]: REPORT~ ##### 2020-12-30 10:39:56 UTC #####
Wed Dec 30 10:39:56 2020 daemon.info lg01_pkt_fwd[3221]: REPORT~ ### [UPSTREAM] ###
Wed Dec 30 10:39:56 2020 daemon.info lg01_pkt_fwd[3221]: REPORT~ # RF packets received by concentrator: 0
Wed Dec 30 10:39:56 2020 daemon.info lg01_pkt_fwd[3221]: REPORT~ # CRC_OK: 0.00%, CRC_FAIL: 0.00%, NO_CRC: 0.00%
Wed Dec 30 10:39:56 2020 daemon.info lg01_pkt_fwd[3221]: REPORT~ # RF packets forwarded: 0 (0 bytes)
Wed Dec 30 10:39:56 2020 daemon.info lg01_pkt_fwd[3221]: REPORT~ # PUSH_DATA datagrams sent: 0 (0 bytes)
Wed Dec 30 10:39:56 2020 daemon.info lg01_pkt_fwd[3221]: REPORT~ # PUSH_DATA acknowledged: 0.00%
Wed Dec 30 10:39:56 2020 daemon.info lg01_pkt_fwd[3221]: REPORT~ ### [DOWNSTREAM] ###
Wed Dec 30 10:39:56 2020 daemon.info lg01_pkt_fwd[3221]: REPORT~ # PULL_DATA sent: 6 (100.00% acknowledged)
Wed Dec 30 10:39:56 2020 daemon.info lg01_pkt_fwd[3221]: REPORT~ # PULL_RESP(onse) datagrams received: 0 (0 bytes)
Wed Dec 30 10:39:56 2020 daemon.info lg01_pkt_fwd[3221]: REPORT~ # RF packets sent to concentrator: 0 (0 bytes)
Wed Dec 30 10:39:56 2020 daemon.info lg01_pkt_fwd[3221]: REPORT~ # TX errors: 0
Wed Dec 30 10:39:56 2020 daemon.info lg01_pkt_fwd[3221]: REPORT~ ##### END #####
Wed Dec 30 10:39:56 2020 daemon.info lg01_pkt_fwd[3221]:
Wed Dec 30 10:39:56 2020 daemon.info lg01_pkt_fwd[3221]: INFO~ (json): [stat update] {"stat":{"time":"2020-12-30 10:39:56 UTC","lati":37.71800,"long":-3.97122,"alti":0,"rxnb":0,"rxok":0,"rxfw":0,"ackr":0.0,"dwnb":0,"txnb":0,"pfrm":"LG01/OLG01","mail":"dragino-1bdad4@dragino.com","desc":"DESC"}}
Wed Dec 30 10:39:56 2020 daemon.info lg01_pkt_fwd[3221]: INFO~ [up] PUSH_ACK received in 1 ms

The last two lines show you that a stat message is transmitted to the Lora Server to say it is alive and the last one is an ACK confirmation from the Lora Server.

If instead of that you find:

Wed Dec 30 10:42:37 2020 daemon.info lg01_pkt_fwd[17154]: INFO~ (json): [stat update] {"stat":{"time":"2020-12-30 10:42:37 UTC","lati":37.71800,"long":-3.97122,"alti":0,"rxnb":0,"rxok":0,"rxfw":0,"ackr":0.0,"dwnb":0,"txnb":0,"pfrm":"LG01/OLG01","mail":"dragino-1bdad4@dragino.com","desc":"DESC"}}
Wed Dec 30 10:42:37 2020 daemon.info lg01_pkt_fwd[17154]: lg01_pkt_fwd.c:333:init_socket(): INFO~ sockfd=68
Wed Dec 30 10:42:38 2020 daemon.info lg01_pkt_fwd[17154]: lg01_pkt_fwd.c:333:init_socket(): INFO~ sockfd=65

It means that you are not receiving an answer from the Lora Server.

You can also check at a Gateway Bridge level. You can read your syslog at your Ubuntu Server.

When the stat message is sent to your Lora Server the log must show this line:

Dec 30 11:39:26 PIdatalogger chirpstack-gateway-bridge[719]: time="2020-12-30T11:39:26+01:00" level=info msg="integration/mqtt: publishing event" event=stats qos=0 stats_id=eb1bb91d-6389-4ec1-a04c-30f0f548e1d9 topic=gateway/a840411bdad44150/event/stats`

Last, your Dragino FW version should work ok, but there are some more versions ahead.
You could also test to upgrade your Dragino FW.
http://www.dragino.com/downloads/index.php?dir=LoRa_Gateway/LG01N/Firmware/Release/

Hi pulidoj,

Yes my Ubuntu’s server ip: 10.0.2.15 and i can sccess through it by 8080 to App. UI. And my gateway’log read as you mentioned there is an error like:

lg01_pkt_fwd[17154]: lg01_pkt_fwd.c:333:init_socket(): INFO~ sockfd=65

lg01_pkt_fwd[17154]: lg01_pkt_fwd.c:333:init_socket(): INFO~ sockfd=65

Blockquote

And i attached some logsys from ubuntu server.

Hi there,

I see two strange things.

  1. On ifconfig from Dragino I see wlan0-2 with IP 192.168.0.128, so this is out of range of your 10.0.2.15 Ubuntu’s IP, as you are pointing to 10.0.2.15 on Server Address of LoraWan config.
    Is it like if your gateway is connected to a different LAN from Ubuntu server.
    Why don’t you try to connect with ethernet cable to the same LAN as Ubuntu server?

  2. The second is the errors when ping PostgresSQL. I have to check it and let you know.

Regards.

1 Like

Hi pulidoj,

Happy New Year !!
new year comes with good news I succeed to connect my gateway to chirpstack server finally. Thank you a lot for your help !! As you mentioned there was a problem in Ip issue range. I configured gateway’s ip to same Ubuntu serever’s range 10.0.2.x. So far gateway is connected to server which I can access to App UI through webbrowser from Windows.
but I have an issue: the Uplink and downlink shown as an UnconfirmedDataDown and UnconfirmedDataUp. any suggestion to solve it ? I have attached some photos please fine them.

Best Regards,
Moshawa

Hi @MoShawa,

That’s great.

In order to avoid Downlinks, you have to disable ADR in your end-device.
Network server is trying to change your ADR and TX power, but your gateway cannot do it.

Remember that one limitation of LG01 is that it can only work in a fixed Frequency and Data Rate, so it cannot execute the request of the server.

1 Like

Hi @MoShawa - I have the same problem here and I’m wondering if you could help posting the steps on how to fix the Ip issue range on the dragino gateway. Thank you and happy new year!

Hi,
My server ip is 10.0.x.y
I have changed gateway ip to 10.0.x.z
And pc ip to 10.0.x.any number.
And you have to change in ubuntu network setting to work as bridge adapter.

Hopefully this work.
Regards

Moshawa

Hey @MoShawa, thanks for replying.
I just noticed you set the server on your machine (please correct me if I’m wrong). I have my server live on aws and I can access the web-ui on port 8080, however my dragino gateway (LG01-N) is showing last seen as “never”. I’ve tested with TTN and everything works fine there.

I had the impression the only thing I had to do in the gateway is to point to the live server as showed in this image.

System overview looks fine, excluding LoRaWAN is not connected (expected).

I have all the ports used by chirpstack open on the firewall (8080, 8883, 1883, 1700). Do you think I’m missing some configuration?

Thank you!

Hi @Rick,

You have to check 3 points:

  • You have Chirpstack Gateway Bridge running on your AWS server.
  • You insert the IP of your AWS server on field Server Address on Dragino’s LoRawan setup.
  • You have your AWS server Port 1700 open.

If it is like that you should at least receive the stats packets from the gateway into Chirpstack Gateway Bridge log of the server.

Hey @pulidoj, thanks for jumping in.
I might have a problem with aws. I have the inbound rules set to port 1700 but netstat does not show that port. I’ll do some research about that since I’m new to EC2 instances and I’ll post my progress if I find the problem.

Thank you!

Hi… I am starting to learn about LoRaWAN and fortunately I found a dragino LoRa IOT kit laying around. The gateway that I have in this kit is the LG01-P Gateway.

Unfortunately, I have problems while trying to follow the user guide from the wiki page. It seems that I can’t upload the test programs via arduino to the LG01-P Gateway.

Hey @pulidoj
I’ve decided to give it a try on Digital Ocean and I can see the live lorawan frames now. I’ll go with DO for now until I can figure out the security settings on AWS.

I’ll try set the device now. Thanks for helping. CC: @MoShawa

1 Like