Last modified by Xiaoling on 2024/09/24 15:37

From version 6.1
edited by Karry Zhuang
on 2024/09/23 18:35
Change comment: There is no comment for this version
To version 4.1
edited by Karry Zhuang
on 2024/09/20 18:06
Change comment: There is no comment for this version

Summary

Details

Page properties
Content
... ... @@ -1,16 +1,13 @@
1 -**Table of Contents:**
1 +
2 2  
3 -{{toc/}}
4 4  
5 5  
6 6  
7 7  
7 +== 1.RS485-LB connects to third-party sensors ==
8 8  
9 -= 1. RS485-LB connects to third-party sensors =
9 +== How to connect RS485-LB node to UART distance sensor? ==
10 10  
11 -== 1.1 How to connect RS485-LB node to UART distance sensor? ==
12 -
13 -
14 14  Take the A16-15 as an example, but the same setup can support different distance sensors, compare specifications see this [[link>>url:http://wiki.dragino.com/xwiki/bin/view/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/DDS04-LB_LoRaWAN_4-Channels_Distance_Detection_Sensor_User_Manual/#H1.4ProbeOptions]] to DDS04-LB.
15 15  
16 16  [[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/RS485-LB_Waterproof_RS485UART_to_LoRaWAN_Converter/WebHome/image-20240703151202-1.png?rev=1.1||alt="image-20240703151202-1.png"]]
... ... @@ -34,20 +34,20 @@
34 34  
35 35  [[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/RS485-LB_Waterproof_RS485UART_to_LoRaWAN_Converter/WebHome/image-20240703161941-4.png?width=1357&height=619&rev=1.1||alt="image-20240703161941-4.png" height="619" width="1357"]]
36 36  
34 +== 2.SN50v3-LB connects to third-party sensors ==
37 37  
38 -= 2. SN50v3-LB connects to third-party sensors =
36 +
39 39  
40 -== 2.1 Working Modes & Sensor Data. Uplink via FPORT~=2 ==
38 +=== 2.3.2 Working Modes & Sensor Data. Uplink via FPORT~=2 ===
41 41  
42 -
43 43  SN50v3-LB/LS has different working mode for the connections of different type of sensors. This section describes these modes. Use can use the AT Command (% style="color:blue" %)**AT+MOD**(%%) to set SN50v3-LB/LS to different working modes.
44 44  
45 45  For example:
46 46  
47 -(% style="color:blue" %)**AT+MOD=2  ** (%%) ~/~/ will set the SN50v3 to work in MOD=2 distance mode which target to measure distance via Ultrasonic Sensor.
44 + (% style="color:blue" %)**AT+MOD=2  ** (%%) ~/~/ will set the SN50v3 to work in MOD=2 distance mode which target to measure distance via Ultrasonic Sensor.
48 48  
49 49  
50 -(% style="color:red" %)**Important Notice:**
47 +(% style="color:red" %) **Important Notice:**
51 51  
52 52  ~1. Some working modes has payload more than 12 bytes, The US915/AU915/AS923 frequency bands' definition has maximum 11 bytes in (% style="color:blue" %)**DR0**(%%). Server sides will see NULL payload while SN50v3-LB/LS transmit in DR0 with 12 bytes payload.
53 53  
... ... @@ -55,10 +55,8 @@
55 55  
56 56  3. By default, the device will send an uplink message every 20 minutes.
57 57  
55 +==== 2.3.2.1  MOD~=1 (Default Mode) ====
58 58  
59 -=== 2.1.1 MOD~=1 (Default Mode) ===
60 -
61 -
62 62  In this mode, uplink payload includes in total 11 bytes. Uplink packets use FPORT=2.
63 63  
64 64  (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:517px" %)
... ... @@ -77,10 +77,8 @@
77 77  
78 78  [[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/LSN50%20%26%20LSN50-V2%20-%20LoRaWAN%20Sensor%20Node%20User%20Manual/WebHome/image-20220627150949-6.png?rev=1.1||alt="image-20220627150949-6.png"]]
79 79  
75 +==== 2.3.2.2  MOD~=2 (Distance Mode) ====
80 80  
81 -=== 2.1.2 MOD~=2 (Distance Mode) ===
82 -
83 -
84 84  This mode is target to measure the distance. The payload of this mode is totally 11 bytes. The 8^^th^^ and 9^^th^^ bytes is for the distance.
85 85  
86 86  (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:517px" %)
... ... @@ -100,13 +100,13 @@
100 100  
101 101  (% style="color:blue" %)**Connection of LIDAR-Lite V3HP:**
102 102  
103 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230512173758-5.png?width=712&height=563&rev=1.1||alt="image-20230512173758-5.png"]]
96 +[[image:image-20230512173758-5.png||height="563" width="712"]]
104 104  
105 105  (% style="color:blue" %)**Connection to Ultrasonic Sensor:**
106 106  
107 107  (% style="color:red" %)**Need to remove R1 and R2 resistors to get low power,otherwise there will be 240uA standby current.**
108 108  
109 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230512173903-6.png?width=715&height=596&rev=1.1||alt="image-20230512173903-6.png"]]
102 +[[image:image-20230512173903-6.png||height="596" width="715"]]
110 110  
111 111  For the connection to TF-Mini or TF-Luna , MOD2 payload is as below:
112 112  
... ... @@ -127,18 +127,19 @@
127 127  
128 128  **Connection to [[TF-Mini plus>>url:http://en.benewake.com/product/detail/5c345cd0e5b3a844c472329b.html]] LiDAR(UART version):**
129 129  
130 -(% style="color:red" %)**Need to remove R3 and R4 resistors to get low power,otherwise there will be 400uA standby current**[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230512180609-7.png?width=802&height=555&rev=1.1||alt="image-20230512180609-7.png"]]
123 +(% style="color:red" %)**Need to remove R3 and R4 resistors to get low power,otherwise there will be 400uA standby current.**(%%)
124 +(% style="color:red" %)[[image:image-20230512180609-7.png||height="555" width="802"]]
131 131  
132 132  **Connection to [[TF-Luna>>url:http://en.benewake.com/product/detail/5e1c1fd04d839408076b6255.html]] LiDAR (UART version):**
133 133  
134 -(% style="color:red" %)**Need to remove R3 and R4 resistors to get low power,otherwise there will be 400uA standby current**
128 +(% style="color:red" %)**Need to remove R3 and R4 resistors to get low power,otherwise there will be 400uA standby current.**(%%)
129 +(% style="color:red" %)[[image:image-20230610170047-1.png||height="452" width="799"]]
135 135  
136 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230610170047-1.png?width=799&height=452&rev=1.1||alt="image-20230610170047-1.png"]]
131 +==== 2.3.2.3  MOD~=3 (3 ADC + I2C) ====
137 137  
133 +==== 2.3.2.3  MOD~=3 (3 ADC + I2C) ====
138 138  
139 -=== 2.1.3 MOD~=3 (3 ADC + I2C) ===
140 140  
141 -
142 142  This mode has total 12 bytes. Include 3 x ADC + 1x I2C
143 143  
144 144  (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:517px" %)
... ... @@ -158,10 +158,10 @@
158 158  )))|(% style="width:163px" %)(((
159 159  Humidity(SHT20 or SHT31)
160 160  )))|(% style="width:53px" %)Bat
155 +[[image:image-20230513110214-6.png]]
161 161  
162 -=== 2.1.4 MOD~=4 (3 x DS18B20) ===
157 +==== 2.3.2.4 MOD~=4 (3 x DS18B20) ====
163 163  
164 -
165 165  This mode has total 11 bytes. As shown below:
166 166  
167 167  (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:517px" %)
... ... @@ -177,14 +177,12 @@
177 177  
178 178  [[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/LSN50%20%26%20LSN50-V2%20-%20LoRaWAN%20Sensor%20Node%20User%20Manual/WebHome/1656377606181-607.png?rev=1.1||alt="1656377606181-607.png"]]
179 179  
180 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230513134006-1.png?width=736&height=559&rev=1.1||alt="image-20230513134006-1.png"]]
174 +[[image:image-20230513134006-1.png||height="559" width="736"]]
181 181  
176 +==== 2.3.2.5  MOD~=5(Weight Measurement by HX711) ====
182 182  
183 -=== 2.1.5 MOD~=5 (Weight Measurement by HX711) ===
178 +[[image:image-20230512164658-2.png||height="532" width="729"]]
184 184  
185 -
186 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230512164658-2.png?width=729&height=532&rev=1.1||alt="image-20230512164658-2.png"]]
187 -
188 188  Each HX711 need to be calibrated before used. User need to do below two steps:
189 189  
190 190  1. Zero calibration. Don't put anything on load cell and run (% style="color:blue" %)**AT+WEIGRE**(%%) to calibrate to Zero gram.
... ... @@ -192,6 +192,7 @@
192 192  1. (((
193 193  Weight has 4 bytes, the unit is g.
194 194  
187 +
195 195  
196 196  )))
197 197  
... ... @@ -217,15 +217,13 @@
217 217  
218 218  [[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/LSN50%20%26%20LSN50-V2%20-%20LoRaWAN%20Sensor%20Node%20User%20Manual/WebHome/image-20220820120036-2.png?width=1003&height=469&rev=1.1||alt="image-20220820120036-2.png" height="469" width="1003"]]
219 219  
213 +==== 2.3.2.6  MOD~=6 (Counting Mode) ====
220 220  
221 -=== 2.1.6 MOD~=6 (Counting Mode) ===
222 -
223 -
224 224  In this mode, the device will work in counting mode. It counts the interrupt on the interrupt pins and sends the count on TDC time.
225 225  
226 226  Connection is as below. The PIR sensor is a count sensor, it will generate interrupt when people come close or go away. User can replace the PIR sensor with other counting sensors.
227 227  
228 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230512181814-9.png?width=697&height=543&rev=1.1||alt="image-20230512181814-9.png"]]
219 +[[image:image-20230512181814-9.png||height="543" width="697"]]
229 229  
230 230  (% style="color:red" %)**Note:** **LoRaWAN wireless transmission will infect the PIR sensor. Which cause the counting value increase +1 for every uplink. User can change PIR sensor or put sensor away of the SN50_v3 to avoid this happen.**
231 231  
... ... @@ -243,10 +243,8 @@
243 243  
244 244  [[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/LSN50%20%26%20LSN50-V2%20-%20LoRaWAN%20Sensor%20Node%20User%20Manual/WebHome/1656378441509-171.png?rev=1.1||alt="1656378441509-171.png"]]
245 245  
237 +==== 2.3.2.7  MOD~=7 (Three interrupt contact modes) ====
246 246  
247 -=== 2.1.7 MOD~=7 (Three interrupt contact modes) ===
248 -
249 -
250 250  (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:517px" %)
251 251  |=(% style="width: 50px;background-color:#4F81BD;color:white" %)(((
252 252  **Size(bytes)**
... ... @@ -260,12 +260,10 @@
260 260  Digital Interrupt1(PA8)
261 261  )))|(% style="width:186px" %)Digital Interrupt2(PA4)|(% style="width:197px" %)Digital Interrupt3(PB15)|(% style="width:100px" %)Reserved
262 262  
263 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230513111203-7.png?width=975&height=324&rev=1.1||alt="image-20230513111203-7.png"]]
252 +[[image:image-20230513111203-7.png||height="324" width="975"]]
264 264  
254 +==== 2.3.2.8  MOD~=8 (3ADC+1DS18B20) ====
265 265  
266 -=== 2.1.8 MOD~=8 (3ADC+1DS18B20) ===
267 -
268 -
269 269  (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:517px" %)
270 270  |=(% style="width: 50px;background-color:#4F81BD;color:white" %)(((
271 271  **Size(bytes)**
... ... @@ -283,12 +283,10 @@
283 283  ADC3(PA8)
284 284  )))
285 285  
286 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230513111231-8.png?width=900&height=335&rev=1.1||alt="image-20230513111231-8.png"]]
273 +[[image:image-20230513111231-8.png||height="335" width="900"]]
287 287  
275 +==== 2.3.2.9  MOD~=9 (3DS18B20+ two Interrupt count mode) ====
288 288  
289 -=== 2.1.9 MOD~=9 (3DS18B20+ two Interrupt count mode) ===
290 -
291 -
292 292  (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:517px" %)
293 293  |=(% style="width: 50px;background-color:#4F81BD;color:white" %)(((
294 294  **Size(bytes)**
... ... @@ -311,7 +311,7 @@
311 311  Count2(PA4)
312 312  )))
313 313  
314 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230513111255-9.png?width=899&height=341&rev=1.1||alt="image-20230513111255-9.png"]]
299 +[[image:image-20230513111255-9.png||height="341" width="899"]]
315 315  
316 316  (% style="color:blue" %)**The newly added AT command is issued correspondingly:**
317 317  
... ... @@ -329,9 +329,8 @@
329 329  When AA is 2, set the count of PA4 pin to BB Corresponding downlink:09 02 bb bb bb bb
330 330  
331 331  
332 -=== 2.1.10 MOD~=10 (PWM input capture and output mode,Since firmware v1.2) ===
317 +==== 2.3.2.10  MOD~=10 (PWM input capture and output mode,Since firmware v1.2) ====
333 333  
334 -
335 335  (% style="color:red" %)**Note: Firmware not release, contact Dragino for testing.**
336 336  
337 337  In this mode, the uplink can perform PWM input capture, and the downlink can perform PWM output.
... ... @@ -339,11 +339,10 @@
339 339  [[It should be noted when using PWM mode.>>||anchor="H2.3.3.12A0PWMMOD"]]
340 340  
341 341  
342 -==== 2.1.10.1  Uplink, PWM input capture ====
326 +===== 2.3.2.10.a  Uplink, PWM input capture =====
343 343  
328 +[[image:image-20230817172209-2.png||height="439" width="683"]]
344 344  
345 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230817172209-2.png?width=683&height=439&rev=1.1||alt="image-20230817172209-2.png"]]
346 -
347 347  (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:515px" %)
348 348  |(% style="background-color:#4f81bd; color:white; width:50px" %)**Size(bytes)**|(% style="background-color:#4f81bd; color:white; width:20px" %)**2**|(% style="background-color:#4f81bd; color:white; width:100px" %)**2**|(% style="background-color:#4f81bd; color:white; width:50px" %)**2**|(% style="background-color:#4f81bd; color:white; width:135px" %)**1**|(% style="background-color:#4f81bd; color:white; width:70px" %)**2**|(% style="background-color:#4f81bd; color:white; width:90px" %)**2**
349 349  |Value|Bat|(% style="width:191px" %)(((
... ... @@ -359,7 +359,7 @@
359 359  Duration of high level
360 360  )))
361 361  
362 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230817170702-1.png?width=1044&height=161&rev=1.1||alt="image-20230817170702-1.png"]]
345 +[[image:image-20230817170702-1.png||height="161" width="1044"]]
363 363  
364 364  When the device detects the following PWM signal ,decoder will converts the pulse period and high-level duration to frequency and duty cycle.
365 365  
... ... @@ -377,13 +377,12 @@
377 377  
378 378  Duty cycle= Duration of high level/ Pulse period*100 ~(%).
379 379  
380 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230818092200-1.png?width=627&height=344&rev=1.1||alt="image-20230818092200-1.png"]]
363 +[[image:image-20230818092200-1.png||height="344" width="627"]]
381 381  
365 +===== 2.3.2.10.b  Uplink, PWM output =====
382 382  
383 -==== 2.1.10.2 Uplink, PWM output ====
367 +[[image:image-20230817172209-2.png||height="439" width="683"]]
384 384  
385 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230817172209-2.png?width=683&height=439&rev=1.1||alt="image-20230817172209-2.png"]]
386 -
387 387  (% style="background-attachment:initial; background-clip:initial; background-image:initial; background-origin:initial; background-position:initial; background-repeat:initial; background-size:initial; color:blue; font-family:Arial,sans-serif" %)**AT+PWMOUT=a,b,c**
388 388  
389 389  a is the time delay of the output, the unit is ms.
... ... @@ -405,12 +405,12 @@
405 405  
406 406  The oscilloscope displays as follows:
407 407  
408 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230817172209-2.png?width=683&height=439&rev=1.1||alt="image-20230817172209-2.png"]]
409 409  
391 +[[image:image-20231213102404-1.jpeg||height="688" width="821"]]
410 410  
411 -===== 2.1.10.3 Downlink, PWM output =====
393 +===== 2.3.2.10. Downlink, PWM output =====
412 412  
413 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230817173800-3.png?width=685&height=412&rev=1.1||alt="image-20230817173800-3.png"]]
395 +[[image:image-20230817173800-3.png||height="412" width="685"]]
414 414  
415 415  Downlink:  (% style="color:#037691" %)**0B xx xx xx yy zz zz**
416 416  
... ... @@ -425,12 +425,10 @@
425 425  
426 426  The oscilloscope displays as follows:
427 427  
428 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230817173858-5.png?width=843&height=634&rev=1.1||alt="image-20230817173858-5.png"]]
410 +[[image:image-20230817173858-5.png||height="634" width="843"]]
429 429  
412 +==== 2.3.2.11  MOD~=11 (TEMP117) ====
430 430  
431 -==== 2.1.11 MOD~=11 (TEMP117) ====
432 -
433 -
434 434  In this mode, uplink payload includes in total 11 bytes. Uplink packets use FPORT=2.
435 435  
436 436  (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:517px" %)
... ... @@ -451,16 +451,14 @@
451 451  (0x0000)
452 452  )))
453 453  
454 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20240717113113-1.png?width=793&height=352&rev=1.1||alt="image-20240717113113-1.png"]]
434 +[[image:image-20240717113113-1.png||height="352" width="793"]]
455 455  
456 456  Connection:
457 457  
458 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20240717141528-2.jpeg?width=654&height=430&rev=1.1||alt="image-20240717141528-2.jpeg"]]
438 +[[image:image-20240717141528-2.jpeg||height="430" width="654"]]
459 459  
440 +==== 2.3.2.12  MOD~=12 (Count+SHT31) ====
460 460  
461 -==== 2.1.12 MOD~=12 (Count+SHT31) ====
462 -
463 -
464 464  This mode has total 11 bytes. As shown below:
465 465  
466 466  (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:517px" %)
... ... @@ -475,16 +475,14 @@
475 475  Count(PA8)
476 476  )))
477 477  
478 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20240717150948-5.png?width=979&height=389&rev=1.1||alt="image-20240717150948-5.png"]]
456 +[[image:image-20240717150948-5.png||height="389" width="979"]]
479 479  
480 480  Wiring example:
481 481  
482 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20240717152224-6.jpeg?width=680&height=359&rev=1.1||alt="image-20240717152224-6.jpeg"]]
460 +[[image:image-20240717152224-6.jpeg||height="359" width="680"]]
483 483  
462 +=== 2.3.3  ​Decode payload ===
484 484  
485 -== 2.2 ​Decode payload ==
486 -
487 -
488 488  While using TTN V3 network, you can add the payload format to decode the payload.
489 489  
490 490  [[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/LSN50%20%26%20LSN50-V2%20-%20LoRaWAN%20Sensor%20Node%20User%20Manual/WebHome/1656378466788-734.png?rev=1.1||alt="1656378466788-734.png"]]
... ... @@ -496,9 +496,8 @@
496 496  SN50v3-LB/LS TTN V3 Payload Decoder:  [[https:~~/~~/github.com/dragino/dragino-end-node-decoder>>url:https://github.com/dragino/dragino-end-node-decoder]]
497 497  
498 498  
499 -=== 2.2.1 Battery Info ===
475 +==== 2.3.3.1 Battery Info ====
500 500  
501 -
502 502  Check the battery voltage for SN50v3-LB/LS.
503 503  
504 504  Ex1: 0x0B45 = 2885mV
... ... @@ -506,7 +506,7 @@
506 506  Ex2: 0x0B49 = 2889mV
507 507  
508 508  
509 -=== 2.2.2 Temperature (DS18B20) ===
484 +==== 2.3.3.2  Temperature (DS18B20) ====
510 510  
511 511  
512 512  If there is a DS18B20 connected to PC13 pin. The temperature will be uploaded in the payload.
... ... @@ -515,7 +515,7 @@
515 515  
516 516  (% style="color:blue" %)**Connection:**
517 517  
518 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230512180718-8.png?width=647&height=538&rev=1.1||alt="image-20230512180718-8.png"]]
493 +[[image:image-20230512180718-8.png||height="538" width="647"]]
519 519  
520 520  (% style="color:blue" %)**Example**:
521 521  
... ... @@ -523,10 +523,10 @@
523 523  
524 524  If payload is: FF3FH :  (FF3F & 8000 == 1) , temp = (FF3FH - 65536)/10 = -19.3 degrees.
525 525  
526 -(FF3F & 8000:Judge whether the highest bit is 1, when the highest bit is 1, it is negative)
501 +FF3F & 8000:Judge whether the highest bit is 1, when the highest bit is 1, it is negative
527 527  
528 528  
529 -=== 2.2.3 Digital Input ===
504 +==== 2.3.3.3 Digital Input ====
530 530  
531 531  
532 532  The digital input for pin PB15,
... ... @@ -543,7 +543,7 @@
543 543  
544 544  )))
545 545  
546 -==== 2.2.4 Analogue Digital Converter (ADC) ====
521 +==== 2.3.3.4  Analogue Digital Converter (ADC) ====
547 547  
548 548  
549 549  The measuring range of the ADC is only about 0.1V to 1.1V The voltage resolution is about 0.24mv.
... ... @@ -557,17 +557,16 @@
557 557  
558 558  The position of PA5 on the hardware after **LSN50 v3.3** is changed to the position shown in the figure below, and the collected voltage becomes one-sixth of the original.
559 559  
560 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230811113449-1.png?width=608&height=370&rev=1.1||alt="image-20230811113449-1.png"]]
561 561  
536 +[[image:image-20230811113449-1.png||height="370" width="608"]]
562 562  
563 -=== 2.2.5 Digital Interrupt ===
538 +==== 2.3.3.5 Digital Interrupt ====
564 564  
565 -
566 566  Digital Interrupt refers to pin PA8, and there are different trigger methods. When there is a trigger, the SN50v3-LB/LS will send a packet to the server.
567 567  
568 568  (% style="color:blue" %)** Interrupt connection method:**
569 569  
570 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230513105351-5.png?width=485&height=147&rev=1.1||alt="image-20230513105351-5.png"]]
544 +[[image:image-20230513105351-5.png||height="147" width="485"]]
571 571  
572 572  (% style="color:blue" %)**Example to use with door sensor :**
573 573  
... ... @@ -614,7 +614,7 @@
614 614  door= (bytes[6] & 0x80)? "CLOSE":"OPEN";
615 615  
616 616  
617 -=== 2.2.6 I2C Interface (SHT20 & SHT31) ===
591 +==== 2.3.3.6 I2C Interface (SHT20 & SHT31) ====
618 618  
619 619  
620 620  The SDA and SCK are I2C interface lines. You can use these to connect to an I2C device and get the sensor data.
... ... @@ -626,7 +626,7 @@
626 626  
627 627  Below is the connection to SHT20/ SHT31. The connection is as below:
628 628  
629 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230610170152-2.png?width=846&height=501&rev=1.1||alt="image-20230610170152-2.png"]]
603 +[[image:image-20230610170152-2.png||height="501" width="846"]]
630 630  
631 631  The device will be able to get the I2C sensor data now and upload to IoT Server.
632 632  
... ... @@ -643,13 +643,13 @@
643 643  If you want to use other I2C device, please refer the SHT20 part source code as reference.
644 644  
645 645  
646 -=== 2.2.7 Distance Reading ===
620 +==== 2.3.3.7  Distance Reading ====
647 647  
648 648  
649 649  Refer [[Ultrasonic Sensor section>>||anchor="H2.3.3.8UltrasonicSensor"]].
650 650  
651 651  
652 -=== 2.2.8 Ultrasonic Sensor ===
626 +==== 2.3.3.8 Ultrasonic Sensor ====
653 653  
654 654  
655 655  This Fundamental Principles of this sensor can be found at this link: [[https:~~/~~/wiki.dfrobot.com/Weather_-_proof_Ultrasonic_Sensor_with_Separate_Probe_SKU~~_~~__SEN0208>>url:https://wiki.dfrobot.com/Weather_-_proof_Ultrasonic_Sensor_with_Separate_Probe_SKU___SEN0208]]
... ... @@ -660,7 +660,7 @@
660 660  
661 661  The picture below shows the connection:
662 662  
663 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230512173903-6.png?width=715&height=596&rev=1.1||alt="image-20230512173903-6.png"]]
637 +[[image:image-20230512173903-6.png||height="596" width="715"]]
664 664  
665 665  Connect to the SN50v3-LB/LS and run (% style="color:blue" %)**AT+MOD=2**(%%) to switch to ultrasonic mode (ULT).
666 666  
... ... @@ -671,13 +671,13 @@
671 671  Distance:  Read: 0C2D(Hex) = 3117(D)  Value:  3117 mm=311.7 cm
672 672  
673 673  
674 -=== 2.2.9 Battery Output - BAT pin ===
648 +==== 2.3.3.9  Battery Output - BAT pin ====
675 675  
676 676  
677 677  The BAT pin of SN50v3-LB/LS is connected to the Battery directly. If users want to use BAT pin to power an external sensor. User need to make sure the external sensor is of low power consumption. Because the BAT pin is always open. If the external sensor is of high power consumption. the battery of SN50v3-LB/LS will run out very soon.
678 678  
679 679  
680 -=== 2.2.10 +5V Output ===
654 +==== 2.3.3.10  +5V Output ====
681 681  
682 682  
683 683  SN50v3-LB/LS will enable +5V output before all sampling and disable the +5v after all sampling. 
... ... @@ -691,19 +691,16 @@
691 691  By default the **AT+5VT=500**. If the external sensor which require 5v and require more time to get stable state, user can use this command to increase the power ON duration for this sensor.
692 692  
693 693  
694 -=== 2.2.11 BH1750 Illumination Sensor ===
668 +==== 2.3.3.11  BH1750 Illumination Sensor ====
695 695  
696 696  
697 697  MOD=1 support this sensor. The sensor value is in the 8^^th^^ and 9^^th^^ bytes.
672 +[[image:image-20230512172447-4.png||height="416" width="712"]]
698 698  
699 -[[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230512172447-4.png?width=712&height=416&rev=1.1||alt="image-20230512172447-4.png"]]
700 -
701 701  [[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/LSN50%20%26%20LSN50-V2%20-%20LoRaWAN%20Sensor%20Node%20User%20Manual/WebHome/image-20220628110012-12.png?rev=1.1||alt="image-20220628110012-12.png" height="361" width="953"]]
702 702  
676 +==== 2.3.3.12  PWM MOD ====
703 703  
704 -=== 2.2.12 PWM MOD ===
705 -
706 -
707 707  * (((
708 708  The maximum voltage that the SDA pin of SN50v3 can withstand is 3.6V, and it cannot exceed this voltage value, otherwise the chip may be burned.
709 709  )))
... ... @@ -711,7 +711,7 @@
711 711  If the PWM pin connected to the SDA pin cannot maintain a high level when it is not working, you need to remove the resistor R2 or replace it with a resistor with a larger resistance, otherwise a sleep current of about 360uA will be generated. The position of the resistor is shown in the figure below:
712 712  )))
713 713  
714 - [[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SN50v3-LB/WebHome/image-20230817183249-3.png?width=417&height=320&rev=1.1||alt="image-20230817183249-3.png"]]
685 + [[image:image-20230817183249-3.png||height="320" width="417"]]
715 715  
716 716  * (((
717 717  The signal captured by the input should preferably be processed by hardware filtering and then connected in. The software processing method is to capture four values, discard the first captured value, and then take the middle value of the second, third, and fourth captured values.
... ... @@ -729,7 +729,7 @@
729 729  b) If the output duration is more than 30 seconds, better to use external power source. 
730 730  )))
731 731  
732 -=== 2.2.13 Working MOD ===
703 +==== 2.3.3.13  Working MOD ====
733 733  
734 734  
735 735  The working MOD info is contained in the Digital in & Digital Interrupt byte (7^^th^^ Byte).
... ... @@ -751,114 +751,25 @@
751 751  
752 752  ​
753 753  
754 -= 3. PS-LB-NA connects to third-party sensors =
725 +== 3.PS-LB-NA connects to third-party sensors ==
755 755  
756 -PS-LB-NA might connect to different kind of probes, 4~~20mA represent the full scale of the measuring range. So a 12mA output means different meaning for different probe. 
757 757  
758 758  
759 -**For example.**
760 760  
761 -(% border="1" cellspacing="3" style="background-color:#f2f2f2; width:500px" %)
762 -|(% style="background-color:#4f81bd; color:white; width:150px" %)**Probe Type**|(% style="background-color:#4f81bd; color:white; width:150px" %)**4~~20mA scale for this probe**|(% style="background-color:#4f81bd; color:white; width:200px" %)**Example: 12mA actually meaning for this probe**
763 -|(% style="background-color:#f2f2f2; width:206px" %)PH Combination Electrodes|(% style="background-color:#f2f2f2; width:222px" %)0 ~~ 14 pH|(% style="background-color:#f2f2f2; width:356px" %)PH Value: 7
764 -|(% style="background-color:#f2f2f2; width:206px" %)Water Pressure Sensor|(% style="background-color:#f2f2f2; width:222px" %)0~~5 meters|(% style="background-color:#f2f2f2; width:356px" %)2.5 meters pure water
765 -|(% style="background-color:#f2f2f2; width:206px" %)Pressure transmitter probe|(% style="background-color:#f2f2f2; width:222px" %)0~~1MPa|(% style="background-color:#f2f2f2; width:356px" %)0.5MPa air / gas or water pressure
766 766  
767 -User can set different probe model for above probes. So IoT server is able to se identical how it should parse the 4~~20mA or 0~~30v sensor value and get the correct value.
768 768  
769 769  
770 -=== 2.3.5 0~~20mA value (IDC_IN) ===
771 771  
772 772  
773 -(% style="color:#037691" %)**Payload Example**:
774 774  
775 -27AE(H) = 10158 (D)/1000 = 10.158mA.
776 776  
777 777  
778 -[[image:image-20230821150704-1.png||height="180" width="609"]]
779 779  
780 -**Connect to a 2 wire 4~~20mA sensor.**
781 781  
782 -[[image:image-20230225154759-1.png||height="408" width="741"]]
783 783  
784 784  
785 -=== 2.3.6 0~~30V value ( pin VDC_IN) ===
786 786  
787 787  
788 -Measure the voltage value. The range is 0 to 30V.
789 789  
790 -(% style="color:#037691" %)**Example**:
791 791  
792 -138E(H) = 5006(D)/1000= 5.006V
793 -
794 -
795 -=== 2.3.7 IN1&IN2&INT pin ===
796 -
797 -
798 -IN1 and IN2 are used as digital input pins.
799 -
800 -(% style="color:#037691" %)**Example**:
801 -
802 -09 (H): (0x09&0x08)>>3=1    IN1 pin is high level.
803 -
804 -09 (H): (0x09&0x04)>>2=0    IN2 pin is low level.
805 -
806 -
807 -This data field shows if this packet is generated by (% style="color:blue" %)**Interrupt Pin** (%%)or not. [[Click here>>||anchor="H3.3.2SetInterruptMode"]] for the hardware and software set up. Note: The Internet Pin is a separate pin in the screw terminal.
808 -
809 -(% style="color:#037691" %)**Example:**
810 -
811 -09 (H): (0x09&0x02)>>1=1    The level of the interrupt pin.
812 -
813 -09 (H): 0x09&0x01=1              0x00: Normal uplink packet.
814 -
815 -0x01: Interrupt Uplink Packet.
816 -
817 -
818 -=== 2.3.8 Sensor value, FPORT~=7 ===
819 -
820 -
821 -(% border="1" cellspacing="3" style="background-color:#f2f2f2; width:504px" %)
822 -|(% style="background-color:#4f81bd; color:white; width:94px" %)(((
823 -**Size(bytes)**
824 -)))|(% style="background-color:#4f81bd; color:white; width:43px" %)**2**|(% style="background-color:#4f81bd; color:white; width:367px" %)**n**
825 -|(% style="background-color:#f2f2f2; width:94px" %)Value|(% style="background-color:#f2f2f2; width:43px" %)[[BAT>>||anchor="H2.3.3BatteryInfo"]]|(% style="background-color:#f2f2f2; width:367px" %)(((
826 -Voltage value, each 2 bytes is a set of voltage values.
827 -)))
828 -
829 -[[image:image-20230220171300-1.png||height="207" width="863"]]
830 -
831 -Multiple sets of data collected are displayed in this form:
832 -
833 -[voltage value1], [voltage value2], [voltage value3],…[voltage value n/2]
834 -
835 -
836 -=== 2.3.9 ​Decode payload in The Things Network ===
837 -
838 -
839 -While using TTN network, you can add the payload format to decode the payload.
840 -
841 -
842 -[[image:1675144839454-913.png]]
843 -
844 -
845 -PS-LB-NA TTN Payload Decoder: [[https:~~/~~/github.com/dragino/dragino-end-node-decoder>>url:https://github.com/dragino/dragino-end-node-decoder]]
846 -
847 -
848 -
849 -
850 -
851 -
852 -
853 -
854 -
855 -
856 -
857 -
858 -
859 -
860 -
861 -
862 -
863 -
864 864