Wiki source code of Notes for LORIOT

Version 75.1 by Kilight Cao on 2023/11/01 16:57

Hide last authors
Xiaoling 1.4 1 (% class="wikigeneratedid" %)
Xiaoling 52.4 2 **~ Table of Contents:**
Xiaoling 1.1 3
Xiaoling 1.6 4 {{toc/}}
Xiaoling 1.4 5
Xiaoling 48.4 6
7
8
Xiaoling 1.4 9 = 1. Introduction =
10
Xiaoling 52.5 11
Xiaoling 1.4 12 (((
Xiaoling 1.7 13 (((
Kilight Cao 63.1 14 The Dragino LoRaWAN gateway can communicate with [[LORIOT>>url:https://www.loriot.io/]] LoRaWAN Network Server:
Xiaoling 1.4 15 )))
Xiaoling 1.7 16 )))
Xiaoling 1.1 17
Xiaoling 1.4 18 (((
Xiaoling 1.7 19 (((
Kilight Cao 67.1 20 Below list the products and requirements that support communication with LORIOT using Semtech UDP:
Xiaoling 1.4 21 )))
Xiaoling 1.7 22 )))
Xiaoling 1.1 23
Xiaoling 1.7 24 (((
Kilight Cao 67.1 25 (((
Xiaoling 68.2 26 ~1. LoRaWAN Gateway model: [[LPS8>>url:http://www.dragino.com/products/lora-lorawan-gateway/item/148-lps8.html]], [[LG308>>url:http://www.dragino.com/products/lora-lorawan-gateway/item/140-lg308.html]], [[DLOS8>>url:http://www.dragino.com/products/lora-lorawan-gateway/item/160-dlos8.html]],[[LPS8N>>https://www.dragino.com/products/lora-lorawan-gateway/item/228-lps8v2.html]],[[LG308N>>https://www.dragino.com/products/lora-lorawan-gateway/item/229-lg308n.html]]
Kilight Cao 67.1 27
28 (((
29 (((
Xiaoling 68.2 30 2. Firmware version since : [[lgw~~-~~-build-v5.4.1661158991-20220822-1704>>https://www.dragino.com/downloads/index.php?dir=LoRa_Gateway/LPS8/Firmware/Release/]]
Kilight Cao 67.1 31
32
Xiaoling 1.4 33 )))
Xiaoling 1.7 34 )))
Kilight Cao 67.1 35
36 Below list the products and requirements that support the use of LORIOT software:
37 )))
38 )))
39
Xiaoling 68.2 40 ~1. LoRaWAN Gateway model: [[LPS8>>url:http://www.dragino.com/products/lora-lorawan-gateway/item/148-lps8.html]], [[LG308>>url:http://www.dragino.com/products/lora-lorawan-gateway/item/140-lg308.html]], [[DLOS8>>url:http://www.dragino.com/products/lora-lorawan-gateway/item/160-dlos8.html]]
Kilight Cao 67.1 41
Xiaoling 1.7 42 (((
Kilight Cao 67.1 43 (((
Kilight Cao 69.1 44 2. Firmware version since :[[dragino-LORIOT~~-~~-v5.4.1676942123-squashfs-sysupgrade.bin>>http://repo.dragino.com/release/openwrt-firmware/lgw/dragino-LORIOT--v5.4.1676942123-squashfs-sysupgrade.bin]]
Xiaoling 32.2 45
46
Xiaoling 1.4 47 )))
Xiaoling 1.7 48 )))
Xiaoling 1.1 49
Kilight Cao 63.1 50 = 2. Gateway Registration for Semtech UDP =
Xiaoling 1.1 51
Xiaoling 1.4 52 == 2.1 Step 1: Get Gateway ETH0 MAC Address ==
Xiaoling 1.1 53
Xiaoling 52.6 54
Xiaoling 68.2 55 Dragino LoRaWAN gateway uses ETH0 MAC address to generate Gateway EUI to communicate with LORIOT, The user needs to find the ETH0 MAC in the "(% style="color:blue" %)**System -> System Overview**" (%%)menu.
Kilight Cao 63.1 56
57
58 [[image:image-20220831110558-1.png||height="595" width="909"]]
59
60
61 == 2.2 Step 2: Register Gateway ==
62
63
64 [[image:image-20220831111032-2.png||height="617" width="1263"]]
65
66
Xiaoling 68.2 67 (% style="color:blue" %)**Choose gateway model**
Kilight Cao 63.1 68
Kilight Cao 65.1 69 [[image:image-20220831111132-3.png||height="596" width="1223"]]
Kilight Cao 63.1 70
71
Xiaoling 68.2 72 (% style="color:red" %)**Special reminder: **(%%)If the user does not find the gateway Model, then (% style="color:blue" %)**git ~-~-> Packet Forwarder Semtech**(%%)  can be selected
Kilight Cao 65.1 73
74 [[image:image-20220831115222-11.png||height="596" width="1221"]]
75
76
Xiaoling 68.2 77 (% style="color:blue" %)**Enter the ETH0 MAC of the gateway**
Kilight Cao 63.1 78
79 [[image:image-20220831111307-4.png||height="850" width="1237"]]
80
81
82 [[image:image-20220831111821-5.png||height="604" width="1239"]]
83
84
85 == 2.3 Step 3: Back to Semtech UDP page ==
86
87
88 Back to the page of Semtech UDP check the secondary server settings and click the button of (% style="color:blue" %)**Save&Apply.**
89
90 (% class="box infomessage" %)
Xiaoling 1.4 91 (((
Kilight Cao 63.1 92 Server Address:  ~-~-> LORIOT Different servers use different addresses, Such as: **next.loriot.io**
Xiaoling 52.6 93
Kilight Cao 63.1 94 Uplink /Downlink Port :  ~-~-> 1780
95 )))
96
97 [[image:image-20220831112553-7.png]]
98
99
100 == 2.4 Step 4: Check Connection ==
101
102
103 (((
104 LORIOT will show disconnect if Gateway doesn't connect
105 )))
106
107 (((
108 LORIOT will show connect if Gateway connect to LORIOT ok.
109 )))
110
111 [[image:image-20220831114125-8.png||height="561" width="1150"]]
112
113
114 == 2.5  Trouble Shooting ==
115
116
117 User can check the station log in the(% style="color:blue" %)** LogRead ~-~-> System Log **(%%)page.
118
119 [[image:image-20220831114647-9.png||height="706" width="894"]]
120
121
122 and recode the station log in the (% style="color:blue" %)** LogRead  ~-~->  Recode Log**(%%) page.
123
124 [[image:image-20220831114746-10.png||height="292" width="972"]]
125
126
Kilight Cao 66.1 127
Kilight Cao 75.1 128 = 3. Gateway Registration for Basics Station =
Kilight Cao 63.1 129
130
Kilight Cao 75.1 131 The LoRa Basics™ Station protocol simplifies the management of large-scale LoRaWAN networks. LoRa Basics™ Station is the preferred way of connecting Gateways to LORIOT. [[The LoRa Basics Station doc>>url:https://www.thethingsindustries.com/docs/gateways/lora-basics-station/]]
132
Kilight Cao 63.1 133 (((
Kilight Cao 75.1 134 (% style="color:blue" %)**Below list the support products and Requirements:**
135 )))
136
137 1. LoRaWAN Gateway model:  [[LIG16>>url:http://www.dragino.com/products/lora-lorawan-gateway/item/171-lig16.html]], [[LG308>>url:http://www.dragino.com/products/lora-lorawan-gateway/item/140-lg308.html]], [[DLOS8>>url:http://www.dragino.com/products/lora-lorawan-gateway/item/160-dlos8.html]] ,[[LPS8>>url:http://www.dragino.com/products/lora-lorawan-gateway/item/148-lps8.html]]
138
139 2.  Firmware version since :       
140
141
142 (% style="color:blue" %)**What do you need to prepare?**
143
144 A gateway that can access the internet normally
145
146
147 === 3.1 Step 1: Register Gateway ===
148
149 [[image:image-20231101162122-1.png||height="528" width="1022"]]
150
151 Enter the gateway ID into the Custom EUI
152
153 [[image:image-20231101162623-2.png||height="526" width="1024"]]
154
155
156 == 3.2  Step 2: Generate and Download TLS Certificate ==
157
158 [[image:image-20231101163647-3.png||height="529" width="1024"]]
159
160
161 Download LORIOT's three TLS certificates, which are:
162
163 (% style="color:red" %)**DigiCert_Global_Root_G2.crt , "Gateway EUI".gws.loriot.io.crt , "Gateway EUI".gws.loriot.io.key**
164
165 [[image:image-20231101163743-4.png||height="528" width="1024"]]
166
167
168
169 == 3.3  Step 3: Access the gateway GUI ==
170
171 User need to upload the TLS certificate and configure the LNS URI
172
173
174 == 3.4  Step 4: Configure Station ==
175
176 User need to input Server URI, Server CUPS Key and LNS Key, as well as install CUPS certificate.
177
178 (% style="color:blue" %)**just to clarify:**
179
180 Server URI  ~-~->  Server Address, Example: wss:~/~/ap2.loriot.io:717
181 TLS CA Certificate         ~-~-> 
182 TLS Key  ~-~-> 
183 TLS Certificate  ~-~->   
184
185
186 == 3.5  Start Station ==
187
188 When the user has finished the configuration, Please click "Save&Apply" to start station to connect LORIOT.
189
190
191 == 3.6  Check Connection ==
192
193 If user completes the above steps,which will see Log in the LORIOT.
194
195 [[image:image-20231101165306-5.png||height="542" width="1050"]]
196
197
198 == 3.7  Trouble Shooting ==
199
200 User can check the station log in the** LogRead ~-~-> System Log **page.
201
202 [[image:http://wiki.dragino.com/xwiki/bin/download/Main/Notes%20for%20TTN/WebHome/image-20220526135845-15.png?rev=1.1||alt="image-20220526135845-15.png"]]
203
204
205 and recode the station log in the** LogRead  ~-~->  Recode Log** page.
206
207 [[image:http://wiki.dragino.com/xwiki/bin/download/Main/Notes%20for%20TTN/WebHome/image-20220526135940-16.png?rev=1.1||alt="image-20220526135940-16.png"]]
208
209
210
211 = 4. Gateways are connected using LORIOT software =
212
213 == 4.1 Step 1: Get Gateway ETH0 MAC Address ==
214
215
216 (((
Kilight Cao 63.1 217 Dragino LoRaWAN gateway use ETH0 MAC address to generate Gateway ID to communicate with LORIOT, User can get the ETH0 MAC address from SSH access and run **ifconfig** command.
218
Xiaoling 52.6 219
Xiaoling 1.4 220 )))
Xiaoling 1.1 221
Xiaoling 4.2 222 [[image:image-20220524175559-2.png]]
Xiaoling 1.1 223
Xiaoling 1.2 224 Get ETH0 MAC address
Xiaoling 1.1 225
Xiaoling 52.7 226
Xiaoling 1.4 227 (((
Xiaoling 52.7 228 (% style="color:red" %)**Note**: **To make set up more friendly, the ETH0 will show on the LORIOT page in a new firmware version.**
Xiaoling 32.2 229
230
Xiaoling 1.4 231 )))
Xiaoling 1.1 232
Kilight Cao 75.1 233 == 4.2 Step 2: Choose LORIOT service ==
Xiaoling 1.1 234
Xiaoling 52.10 235
Xiaoling 49.3 236 [[image:image-20220531182035-1.png]]
Xiaoling 1.1 237
Xiaoling 1.2 238 Choose to use LORIOT as LoRaWAN service provider
Xiaoling 1.1 239
Xiaoling 49.3 240
Xiaoling 52.8 241
Xiaoling 50.2 242 [[image:image-20220531182109-2.png]]
Xiaoling 1.1 243
Xiaoling 1.2 244 Install and choose the LORIOT server to be used
245
Xiaoling 32.2 246
Kilight Cao 75.1 247 == 4.3 Step 3: Checking Connection Status ==
Xiaoling 1.2 248
Xiaoling 52.10 249
Xiaoling 51.2 250 [[image:image-20220531182202-3.png]]
Xiaoling 1.2 251
252 Click to Home page and check the connection status
253
Xiaoling 32.2 254
Kilight Cao 75.1 255 == 4.4 Step 4: Setup Account in LORIOT ==
Xiaoling 1.2 256
Xiaoling 52.9 257
Xiaoling 1.2 258 Login [[LORIOT>>url:https://www.loriot.io/]] and create account
259
Xiaoling 52.2 260 [[image:image-20220531182253-4.png]]
Xiaoling 1.2 261
262 Log in LORIOT portal
263
264
Xiaoling 52.9 265
Xiaoling 1.4 266 Choose to use the server same as the gateway setting
267
Xiaoling 32.2 268 [[image:image-20220526111312-1.png||height="493" width="1098"]]
Xiaoling 1.2 269
270 Choose server
271
272
Xiaoling 52.9 273
Xiaoling 1.4 274 Create a New Network
275
Xiaoling 32.2 276 [[image:image-20220526111425-2.png||height="579" width="1378"]]
Xiaoling 1.2 277
278 Create a New Network
279
280
Xiaoling 32.2 281 [[image:image-20220526111500-3.png]]
Xiaoling 1.5 282
Xiaoling 1.2 283 Create a New Network
284
Xiaoling 32.2 285
Kilight Cao 75.1 286 == 4.5 Step 5: Register the gateway ==
Xiaoling 1.2 287
Xiaoling 52.9 288
Xiaoling 32.2 289 [[image:image-20220526111650-4.png]]
Xiaoling 1.2 290
291 Register the Gateway in LORIOT
292
293
Xiaoling 52.9 294
Xiaoling 1.2 295 Choose LG308 as gateway model
296
Xiaoling 32.2 297 [[image:image-20220526111742-5.png||height="496" width="1372"]]
Xiaoling 1.2 298
299 Choose LG308 as gateway model
300
301
Xiaoling 52.9 302
Xiaoling 1.2 303 Input Gateway ETH0 address
304
Xiaoling 35.2 305 [[image:image-20220526111918-6.png||height="744" width="1336"]]
Xiaoling 1.2 306
307 Choose SX1301 Reference and use SPI protocol
308
309
Xiaoling 52.9 310
Xiaoling 1.2 311 Choose the right Frequency Band and input location
312
Xiaoling 35.2 313 [[image:image-20220526112029-7.png||height="620" width="1306"]]
Xiaoling 1.2 314
315 Set up regional settings.
316
Xiaoling 45.2 317
Kilight Cao 75.1 318 == 4.6 Step 6: Check Connection ==
Xiaoling 1.2 319
Xiaoling 52.9 320
Xiaoling 1.5 321 (((
Xiaoling 1.2 322 LORIOT will show disconnect if Gateway doesn't connect
Xiaoling 1.5 323 )))
Xiaoling 1.2 324
Xiaoling 1.5 325 (((
Xiaoling 1.2 326 LORIOT will show connect if Gateway connect to LORIOT ok.
Xiaoling 52.9 327
328
Xiaoling 1.5 329 )))
Xiaoling 1.2 330
Xiaoling 36.2 331 [[image:image-20220526112143-8.png||height="654" width="1373"]]
Xiaoling 1.2 332
333 Status: Connected
334
Xiaoling 45.2 335
Kilight Cao 75.1 336 == 4.7 Debug If there is connection issue ==
Xiaoling 1.2 337
Xiaoling 52.9 338
Xiaoling 1.2 339 User can check if loriot is running by checking the web ui
340
Xiaoling 52.9 341
Xiaoling 45.2 342 [[image:image-20220526112917-18.png]]
Xiaoling 1.2 343
344 Status: Connected
345
Xiaoling 52.9 346
Xiaoling 1.11 347 (((
Xiaoling 1.2 348 If user want to see more log, he can run below commands in Linux and see the full log:
Xiaoling 1.11 349 )))
Xiaoling 1.2 350
Xiaoling 1.5 351 (% class="box" %)
352 (((
Xiaoling 1.8 353 (((
Xiaoling 1.11 354 ps | grep "loriot_dragino" | grep -v grep | awk '{print $1}' | xargs kill -s 9
355 /usr/bin/loriot_dragino_lg308_spi -f -s eu1.loriot.io
Xiaoling 1.5 356 )))
Xiaoling 1.8 357 )))
Xiaoling 1.2 358
Xiaoling 1.11 359 (((
Xiaoling 52.9 360
361
Xiaoling 1.2 362 Above two commands will first kill the loriot process and run it again to get more output.
Xiaoling 1.11 363 )))
Xiaoling 1.2 364
Xiaoling 47.2 365 [[image:image-20220530145011-1.png]]
Xiaoling 1.2 366
367 Get more debug info
368
Xiaoling 45.2 369
Kilight Cao 75.1 370 = 5. End Device Note =
Xiaoling 1.2 371
Kilight Cao 75.1 372 == 5.1 Downlink Setup ==
Xiaoling 1.2 373
Xiaoling 52.9 374
Xiaoling 48.2 375 [[image:image-20220530145133-2.png]]
Xiaoling 1.2 376
Xiaoling 45.2 377
Xiaoling 41.2 378 [[image:image-20220526112416-11.png]]
Xiaoling 1.2 379
Xiaoling 45.2 380
Xiaoling 41.2 381 [[image:image-20220526112459-12.png]]
Xiaoling 1.2 382
Xiaoling 45.2 383
Xiaoling 41.2 384 [[image:image-20220526112537-13.png]]
Xiaoling 1.2 385
Xiaoling 45.2 386
Xiaoling 41.2 387 [[image:image-20220526112608-14.png||height="610" width="1382"]]
Xiaoling 1.2 388
Xiaoling 45.2 389
Xiaoling 44.2 390 [[image:image-20220526112655-15.png]]
Xiaoling 1.2 391
Xiaoling 45.2 392
Xiaoling 44.2 393 [[image:image-20220526112719-16.png]]
Xiaoling 1.2 394
Xiaoling 45.2 395
Xiaoling 44.2 396 [[image:image-20220526112759-17.png||height="483" width="1386"]]