<
From version < 102.17 >
edited by Xiaoling
on 2023/04/25 14:14
To version < 98.1 >
edited by Bei Jinggeng
on 2022/12/06 09:45
>
Change comment: There is no comment for this version

Summary

Details

Page properties
Author
... ... @@ -1,1 +1,1 @@
1 -XWiki.Xiaoling
1 +XWiki.Bei
Content
... ... @@ -28,7 +28,7 @@
28 28  
29 29  
30 30  
31 -= 1. Introduction =
31 += 1.Introduction =
32 32  
33 33  == 1.1 What is RS485-LN RS485 to LoRaWAN Converter ==
34 34  
... ... @@ -95,7 +95,6 @@
95 95  * Packet engine up to 256 bytes with CRC
96 96  
97 97  
98 -
99 99  == 1.3 Features ==
100 100  
101 101  
... ... @@ -109,7 +109,6 @@
109 109  * Support Interrupt uplink (Since hardware version v1.2)
110 110  
111 111  
112 -
113 113  == 1.4 Applications ==
114 114  
115 115  
... ... @@ -121,7 +121,6 @@
121 121  * Smart Factory
122 122  
123 123  
124 -
125 125  == 1.5 Firmware Change log ==
126 126  
127 127  
... ... @@ -128,6 +128,7 @@
128 128  [[RS485-LN Image files – Download link and Change log>>url:http://www.dragino.com/downloads/index.php?dir=RS485-LN/]]
129 129  
130 130  
128 +
131 131  == 1.6 Hardware Change log ==
132 132  
133 133  
... ... @@ -287,48 +287,44 @@
287 287  
288 288  To use RS485-LN to read data from RS485 sensors, connect the RS485-LN A/B traces to the sensors. And user need to make sure RS485-LN use the match UART setting to access the sensors. The related commands for UART settings are:
289 289  
290 -(% border="1" cellspacing="5" style="background-color:#f2f2f2; width:510px" %)
291 -|=(% style="width: 126px; background-color:#D9E2F3;color:#0070C0" %)(((
288 +
289 +(% border="1" cellspacing="5" style="background-color:#ffffcc; color:green; width:510px" %)
290 +|=(% style="width: 110px;" %)(((
292 292  **AT Commands**
293 -)))|=(% style="width: 187px; background-color:#D9E2F3;color:#0070C0" %)(((
292 +)))|=(% style="width: 210px;" %)(((
294 294  **Description**
295 -)))|=(% style="width: 197px;background-color:#D9E2F3;color:#0070C0" %)(((
294 +)))|=(% style="width: 190px;" %)(((
296 296  **Example**
297 297  )))
298 -|(% style="width:126px" %)(((
299 -
300 -
301 -(((
297 +|(% style="width:110px" %)(((
302 302  AT+BAUDR
303 -)))
304 -)))|(% style="width:177px" %)(((
299 +)))|(% style="width:190px" %)(((
305 305  Set the baud rate (for RS485 connection). Default Value is: 9600.
306 -)))|(% style="width:193px" %)(((
301 +)))|(% style="width:190px" %)(((
307 307  (((
308 308  AT+BAUDR=9600
309 309  )))
305 +
310 310  (((
311 -Options: (1200,2400,4800,
312 -14400,19200,115200)
307 +Options: (1200,2400,4800,14400,19200,115200)
313 313  )))
314 314  )))
315 -|(% style="width:126px" %)(((
310 +|(% style="width:110px" %)(((
316 316  AT+PARITY
317 -)))|(% style="width:177px" %)(((
312 +)))|(% style="width:190px" %)(((
318 318  Set UART parity (for RS485 connection)
319 -)))|(% style="width:193px" %)(((
314 +)))|(% style="width:190px" %)(((
320 320  (((
321 321  AT+PARITY=0
322 322  )))
318 +
323 323  (((
324 -Option: 0: no parity,
325 -1: odd parity,
326 -2: even parity
320 +Option: 0: no parity, 1: odd parity, 2: even parity
327 327  )))
328 328  )))
329 -|(% style="width:126px" %)(((
323 +|(% style="width:110px" %)(((
330 330  AT+STOPBIT
331 -)))|(% style="width:177px" %)(((
325 +)))|(% style="width:190px" %)(((
332 332  (((
333 333  Set serial stopbit (for RS485 connection)
334 334  )))
... ... @@ -336,28 +336,35 @@
336 336  (((
337 337  
338 338  )))
339 -)))|(% style="width:193px" %)(((
333 +)))|(% style="width:190px" %)(((
340 340  (((
341 341  AT+STOPBIT=0 for 1bit
342 342  )))
337 +
343 343  (((
344 344  AT+STOPBIT=1 for 1.5 bit
345 345  )))
341 +
346 346  (((
347 347  AT+STOPBIT=2 for 2 bits
348 348  )))
349 349  )))
350 350  
347 +
351 351  === 3.3.2 Configure sensors ===
352 352  
353 353  
354 354  (((
352 +(((
355 355  Some sensors might need to configure before normal operation. User can configure such sensor via PC and RS485 adapter or through RS485-LN AT Commands (% style="color:#4f81bd" %)**AT+CFGDEV**(%%). Each (% style="color:#4f81bd" %)**AT+CFGDEV **(%%)equals to send a RS485 command to sensors. This command will only run when user input it and won't run during each sampling.
354 +
355 +
356 356  )))
357 +)))
357 357  
358 -(% border="1" cellspacing="5" style="background-color:#f2f2f2; width:510px" %)
359 -|=(% style="width: 122px; background-color:#D9E2F3;color:#0070C0" %)**AT Commands**|=(% style="width: 198px; background-color:#D9E2F3;color:#0070C0" %)**Description**|=(% style="width: 190px;background-color:#D9E2F3;color:#0070C0" %)**Example**
360 -|(% style="width:122px" %)AT+CFGDEV|(% style="width:196px" %)(((
359 +(% border="1" cellspacing="5" style="background-color:#ffffcc; color:green; width:510px" %)
360 +|=(% style="width: 110px;" %)**AT Commands**|=(% style="width: 210px;" %)**Description**|=(% style="width: 190px;" %)**Example**
361 +|AT+CFGDEV|(% style="width:110px" %)(((
361 361  (((
362 362  This command is used to configure the RS485/TTL devices; they won’t be used during sampling.
363 363  )))
... ... @@ -371,6 +371,7 @@
371 371  )))
372 372  )))|(% style="width:190px" %)AT+CFGDEV=xx xx xx xx xx xx xx xx xx xx xx xx,m
373 373  
375 +
374 374  === 3.3.3 Configure read commands for each sampling ===
375 375  
376 376  
... ... @@ -401,7 +401,7 @@
401 401  
402 402  (% style="color:#037691" %)**AT+COMMANDx **(%%)**: **This command will be sent to RS485 devices during each sampling, Max command length is 14 bytes. The grammar is:
403 403  
404 -(% border="1" style="background-color:#f2f2f2; width:499px" %)
406 +(% border="1" style="background-color:#4bacc6; color:white; width:499px" %)
405 405  |(% style="width:496px" %)(((
406 406  **AT+COMMANDx=xx xx xx xx xx xx xx xx xx xx xx xx,m**
407 407  
... ... @@ -417,7 +417,7 @@
417 417  
418 418  (% style="color:#037691" %)**AT+DATACUTx **(%%)**: **This command defines how to handle the return from AT+COMMANDx, max return length is 100 bytes.
419 419  
420 -(% border="1" style="background-color:#f2f2f2; width:510px" %)
422 +(% border="1" style="background-color:#4bacc6; color:white; width:510px" %)
421 421  |(% style="width:510px" %)(((
422 422  **AT+DATACUTx=a,b,c**
423 423  
... ... @@ -559,11 +559,11 @@
559 559  == 3.4 Uplink Payload ==
560 560  
561 561  
562 -(% border="1" cellspacing="5" style="background-color:#f2f2f2; width:510px" %)
563 -|=(% scope="row" style="width: 70px;background-color:#D9E2F3;color:#0070C0" %)(((
564 +(% border="1" cellspacing="5" style="background-color:#ffffcc; color:green; width:500px" %)
565 +|=(% scope="row" style="width: 60px;" %)(((
564 564  Size(bytes)
565 -)))|(% style="background-color:#d9e2f3; color:#0070c0; width:80px" %)**1**|(% style="background-color:#d9e2f3; color:#0070c0; width:360px" %)(((
566 -**Length depends on the return from the commands**
567 +)))|(% style="width:80px" %)1|(% style="width:360px" %)(((
568 +Length depends on the return from the commands
567 567  )))
568 568  |=(% style="width: 90px;" %)(((
569 569  Value
... ... @@ -608,6 +608,7 @@
608 608  )))
609 609  
610 610  
613 +
611 611  === 3.5.1 Common Commands ===
612 612  
613 613  
... ... @@ -753,6 +753,7 @@
753 753  
754 754  
755 755  
759 +
756 756  ==== (% style="color:blue" %)**Set Payload version**(%%) ====
757 757  
758 758  
... ... @@ -795,6 +795,7 @@
795 795  
796 796  
797 797  
802 +
798 798  ==== (% style="color:blue" %)**Set RS485 Sampling Commands**(%%) ====
799 799  
800 800  
... ... @@ -879,6 +879,7 @@
879 879  
880 880  
881 881  
887 +
882 882  ==== (% style="color:blue" %)**Fast command to handle MODBUS device**(%%) ====
883 883  
884 884  
... ... @@ -922,6 +922,7 @@
922 922  
923 923  
924 924  
931 +
925 925  ==== (% style="color:blue" %)**RS485 command timeout**(%%) ====
926 926  
927 927  
... ... @@ -958,7 +958,7 @@
958 958  )))
959 959  
960 960  (((
961 -(% style="color:#4472c4" %)** 0x AA aa bb cc**(%%) Same as: AT+CMDDLaa=hex (bb cc)
968 +(% style="color:#4472c4" %)** 0x AA aa bb cc**(%%) Same as: AT+CMDDLaa=hex(bb cc)*1000
962 962  )))
963 963  
964 964  (((
... ... @@ -968,11 +968,12 @@
968 968  )))
969 969  
970 970  (((
971 -**0xAA 01 03 E8**  ~-~-> Same as  **AT+CMDDL1=1000 ms**
978 +**0xAA 01 00 01**  ~-~-> Same as  **AT+CMDDL1=1000 ms**
972 972  )))
973 973  
974 974  
975 975  
983 +
976 976  ==== (% style="color:blue" %)**Uplink payload mode**(%%) ====
977 977  
978 978  
... ... @@ -1027,6 +1027,7 @@
1027 1027  
1028 1028  
1029 1029  
1038 +
1030 1030  ==== (% style="color:blue" %)**Manually trigger an Uplink**(%%) ====
1031 1031  
1032 1032  
... ... @@ -1056,6 +1056,7 @@
1056 1056  
1057 1057  
1058 1058  
1068 +
1059 1059  ==== (% style="color:blue" %)**Clear RS485 Command**(%%) ====
1060 1060  
1061 1061  
... ... @@ -1104,6 +1104,7 @@
1104 1104  
1105 1105  
1106 1106  
1117 +
1107 1107  ==== (% style="color:blue" %)**Set Serial Communication Parameters**(%%) ====
1108 1108  
1109 1109  
... ... @@ -1187,7 +1187,7 @@
1187 1187  
1188 1188  
1189 1189  
1190 -==== (% style="color:blue" %)**Encrypted payload(Since Version 1.4.0)**(%%) ====
1201 +==== (% style="color:blue" %)**Encrypted payload**(%%) ====
1191 1191  
1192 1192  (((
1193 1193  
... ... @@ -1203,9 +1203,10 @@
1203 1203  
1204 1204  
1205 1205  
1206 -==== (% style="color:blue" %)**Get sensor value(Since Version 1.4.0)**(%%) ====
1207 1207  
1218 +==== (% style="color:blue" %)**Get sensor value**(%%) ====
1208 1208  
1220 +
1209 1209  * (((
1210 1210  (% style="color:#037691" %)** AT Command:**
1211 1211  )))
... ... @@ -1216,9 +1216,10 @@
1216 1216  
1217 1217  
1218 1218  
1219 -==== (% style="color:blue" %)**Resets the downlink packet count(Since Version 1.4.0)**(%%) ====
1220 1220  
1232 +==== (% style="color:blue" %)**Resets the downlink packet count**(%%) ====
1221 1221  
1234 +
1222 1222  * (((
1223 1223  (% style="color:#037691" %)** AT Command:**
1224 1224  )))
... ... @@ -1229,9 +1229,10 @@
1229 1229  
1230 1230  
1231 1231  
1232 -==== (% style="color:blue" %)**When the limit bytes are exceeded, upload in batches(Since Version 1.4.0)**(%%) ====
1233 1233  
1246 +==== (% style="color:blue" %)**When the limit bytes are exceeded, upload in batches**(%%) ====
1234 1234  
1248 +
1235 1235  * (((
1236 1236  (% style="color:#037691" %)** AT Command:**
1237 1237  )))
... ... @@ -1249,9 +1249,10 @@
1249 1249  
1250 1250  
1251 1251  
1252 -==== (% style="color:blue" %)**Copy downlink to uplink (Since Version 1.4.0)**(%%) ====
1253 1253  
1267 +==== (% style="color:blue" %)** Copy downlink to uplink **(%%) ====
1254 1254  
1269 +
1255 1255  * (((
1256 1256  (% style="color:#037691" %)** AT Command:**
1257 1257  )))
... ... @@ -1273,9 +1273,10 @@
1273 1273  
1274 1274  
1275 1275  
1276 -==== (% style="color:blue" %)**Query version number and frequency band 、TDC(Since Version 1.4.0)**(%%) ====
1277 1277  
1292 +==== (% style="color:blue" %)**Query version number and frequency band 、TDC**(%%) ====
1278 1278  
1294 +
1279 1279  (((
1280 1280  * (% style="color:#037691" %)**Downlink Payload:**
1281 1281  
... ... @@ -1290,9 +1290,10 @@
1290 1290  
1291 1291  
1292 1292  
1293 -==== (% style="color:blue" %)** Monitor RS485 communication of other devices(Since Version 1.4.0)**(%%) ====
1294 1294  
1310 +==== (% style="color:blue" %)** Monitor RS485 communication of other devices**(%%) ====
1295 1295  
1312 +
1296 1296  * (((
1297 1297  (% style="color:#037691" %)** AT Command:**
1298 1298  )))
... ... @@ -1334,32 +1334,34 @@
1334 1334  To enable the listening mode, use can run the command (% style="color:#4472c4" %)** AT+RXMODE**.
1335 1335  )))
1336 1336  
1354 +(((
1355 +
1356 +)))
1337 1337  
1338 -
1339 -(% border="1" cellspacing="5" style="background-color:#f2f2f2; width:510px" %)
1340 -|=(% style="width: 156px; background-color:#D9E2F3;color:#0070C0" %)(((
1358 +(% border="1" cellspacing="10" style="background-color:#ffffcc; width:500px" %)
1359 +|=(% style="width: 100px;" %)(((
1341 1341  **Command example**
1342 -)))|=(% style="width: 355px; background-color:#D9E2F3;color:#0070C0" %)(((
1361 +)))|=(% style="width: 400px;" %)(((
1343 1343  **Function**
1344 1344  )))
1345 -|(% style="width:156px" %)(((
1364 +|(% style="width:100px" %)(((
1346 1346  AT+RXMODE=1,10
1347 -)))|(% style="width:352px" %)(((
1366 +)))|(% style="width:400px" %)(((
1348 1348  Enable listening mode 1, if RS485-LN has received more than 10 RS485 commands from the network. RS485-LN will send these commands via LoRaWAN uplinks.
1349 1349  )))
1350 -|(% style="width:156px" %)(((
1369 +|(% style="width:100px" %)(((
1351 1351  AT+RXMODE=2,500
1352 -)))|(% style="width:352px" %)(((
1371 +)))|(% style="width:400px" %)(((
1353 1353  Enable listening mode 2, RS485-LN will capture and send a 500ms content once from the first detect of character. Max value is 65535 ms
1354 1354  )))
1355 -|(% style="width:156px" %)(((
1374 +|(% style="width:100px" %)(((
1356 1356  AT+RXMODE=0,0
1357 -)))|(% style="width:352px" %)(((
1376 +)))|(% style="width:400px" %)(((
1358 1358  Disable listening mode. This is the default settings.
1359 1359  )))
1360 -|(% style="width:156px" %)(((
1379 +|(% style="width:100px" %)(((
1361 1361  
1362 -)))|(% style="width:352px" %)(((
1381 +)))|(% style="width:400px" %)(((
1363 1363  A6 aa bb cc  same as AT+RXMODE=aa,(bb<<8 | cc)
1364 1364  )))
1365 1365  
... ... @@ -1407,30 +1407,36 @@
1407 1407  (% aria-label="image-20220602171200-9.png image widget" contenteditable="false" role="region" tabindex="-1" %)[[image:image-20220602171200-9.png||data-widget="image"]](% style="background-image:url(http://wiki.dragino.com/xwiki/webjars/wiki%3Axwiki/application-ckeditor-webjar/1.61/plugins/widget/images/handle.png); background:rgba(220,220,220,0.5); display:none" %)[[image:data:image/gif;base64,R0lGODlhAQABAPABAP///wAAACH5BAEKAAAALAAAAAABAAEAAAICRAEAOw==||draggable="true" height="15" role="presentation" title="Click and drag to move" width="15"]](% title="Click and drag to resize" %)​
1408 1408  )))
1409 1409  
1429 +(((
1430 +
1431 +)))
1410 1410  
1411 -
1412 1412  (((
1434 +(((
1413 1413  (% style="color:red" %)**Notice: Listening mode can work with the default polling mode of RS485-LN. When RS485-LN is in to send the RS485 commands (from AT+COMMANDx), the listening mode will be interrupt for a while.**
1414 1414  )))
1437 +)))
1415 1415  
1416 1416  
1417 1417  == 3.7 Buttons ==
1418 1418  
1419 1419  
1420 -(% border="1.5" cellspacing="4" style="background-color:#f2f2f2; width:430px" %)
1421 -|=(% style="width: 50px;background-color:#D9E2F3;color:#0070C0" %)**Button**|=(% style="width: 380px;background-color:#D9E2F3;color:#0070C0" %)**Feature**
1422 -|(% style="width:50px" %)ACT|(% style="width:361px" %)If RS485 joined in network, press this button for more than 1 second, RS485 will upload a packet, and the SYS LED will give a (% style="color:blue" %)**Blue blink**
1423 -|(% style="width:50px" %)RST|(% style="width:361px" %)Reboot RS485
1424 -|(% style="width:50px" %)PRO|(% style="width:361px" %)Use for upload image, see [[How to Update Image>>||anchor="H6.1Howtoupgradetheimage3F"]]
1443 +(% border="1.5" cellspacing="4" style="background-color:#ffffcc; width:430px" %)
1444 +|=(% style="width: 50px;" %)**Button**|=(% style="width: 380px;" %)**Feature**
1445 +|(% style="width:50px" %)**ACT**|(% style="width:361px" %)If RS485 joined in network, press this button for more than 1 second, RS485 will upload a packet, and the SYS LED will give a (% style="color:blue" %)**Blue blink**
1446 +|(% style="width:50px" %)**RST**|(% style="width:361px" %)Reboot RS485
1447 +|(% style="width:50px" %)**PRO**|(% style="width:361px" %)Use for upload image, see [[How to Update Image>>||anchor="H6.1Howtoupgradetheimage3F"]]
1425 1425  
1449 +
1426 1426  == 3.8 LEDs ==
1427 1427  
1428 1428  
1429 -(% border="1.5" cellspacing="4" style="background-color:#f2f2f2; width:430px" %)
1430 -|=(% style="width: 50px;background-color:#D9E2F3;color:#0070C0" %)**LEDs**|=(% style="width: 380px;background-color:#D9E2F3;color:#0070C0" %)**Feature**
1431 -|PWR|Always on if there is power
1432 -|SYS|After device is powered on, the SYS will (% style="color:green" %)**fast blink in GREEN**(%%) for 5 times, means RS485-LN start to join LoRaWAN network. If join success, SYS will be (% style="color:green" %)**on GREEN for 5 seconds** (%%)**. **SYS will (% style="color:green" %)**blink Blue**(%%) on every upload and (% style="color:green" %)**blink Green**(%%) once receive a downlink message.
1453 +(% border="1.5" cellspacing="4" style="background-color:#ffffcc; width:430px" %)
1454 +|=(% style="width: 50px;" %)**LEDs**|=(% style="width: 380px;" %)**Feature**
1455 +|**PWR**|Always on if there is power
1456 +|**SYS**|After device is powered on, the SYS will (% style="color:green" %)**fast blink in GREEN**(%%) for 5 times, means RS485-LN start to join LoRaWAN network. If join success, SYS will be (% style="color:green" %)**on GREEN for 5 seconds** (%%)**. **SYS will (% style="color:green" %)**blink Blue**(%%) on every upload and (% style="color:green" %)**blink Green**(%%) once receive a downlink message.
1433 1433  
1458 +
1434 1434  = 4. Case Study =
1435 1435  
1436 1436  
... ... @@ -1484,6 +1484,8 @@
1484 1484  
1485 1485  * (% style="color:#037691" %)**AT+NJM=0**
1486 1486  * (% style="color:#037691" %)**ATZ**
1512 +
1513 +
1487 1487  )))
1488 1488  
1489 1489  
... ... @@ -1685,7 +1685,7 @@
1685 1685  
1686 1686  RS485-LN sent below command:
1687 1687  
1688 -(% style="color:blue" %)**AT+CFGDEV=01 03 00 20 00 01,1**(%%) to RS485 network, and PC is able to get this command and return commands from MTU to show in the serial tool.
1715 +(% style="color:blue" %)**AT+CFGDEV=01 03 20 00 01 85 c0,1**(%%) to RS485 network, and PC is able to get this command and return commands from MTU to show in the serial tool.
1689 1689  
1690 1690  
1691 1691  We can see the output from the Serial port tool to analyze. And check if they are expected result.
... ... @@ -1737,10 +1737,9 @@
1737 1737  
1738 1738  == 6.8 Where to get the decoder for RS485-LN? ==
1739 1739  
1767 +The decoder for RS485-LN needs to be written by yourself. Because the sensor to which the user is connected is custom, the read device data bytes also need custom parsing, so there is no universal decoder. We can only provide templates for decoders (no intermediate data parsing part involved)
1740 1740  
1741 -The decoder for RS485-LN needs to be written by yourself. Because the sensor to which the user is connected is custom, the read device data bytes also need custom parsing, so there is no universal decoder. We can only provide [[templates>>https://github.com/dragino/dragino-end-node-decoder/tree/main/RS485-LN]] for decoders (no intermediate data parsing part involved)
1742 1742  
1743 -
1744 1744  = 7. Trouble Shooting =
1745 1745  
1746 1746  == 7.1 Downlink doesn't work, how to solve it? ==
... ... @@ -1773,9 +1773,10 @@
1773 1773  * (% style="color:red" %)**RU864**(%%):  frequency bands RU864
1774 1774  * (% style="color:red" %)**KZ865**(%%):  frequency bands KZ865
1775 1775  
1776 -= 9. Packing Info =
1777 1777  
1803 += 9.Packing Info =
1778 1778  
1805 +
1779 1779  **Package Includes**:
1780 1780  
1781 1781  * RS485-LN x 1
... ... @@ -1789,6 +1789,7 @@
1789 1789  * Package Size / pcs : 14.5 x 8 x 5 cm
1790 1790  * Weight / pcs : 170g
1791 1791  
1819 +
1792 1792  = 10. FCC Caution for RS485LN-US915 =
1793 1793  
1794 1794  
Copyright ©2010-2024 Dragino Technology Co., LTD. All rights reserved
Dragino Wiki v2.0