Version 493.1 by Karry Zhuang on 2025/03/20 10:57

Show last authors
1 (% style="text-align:center" %)
2 [[image:image-20241204094648-1.jpeg||height="544" width="544"]]
3
4
5
6
7
8
9
10 **Table of Contents:**
11
12 {{toc/}}
13
14
15
16
17
18 = 1. Introduction =
19
20 == 1.1 What is the LHT65N-VIB LoRaWAN Vibration Sensor? ==
21
22
23 The Dragino LHT65N-VIB (% style="color:blue" %)**LoRaWAN Vibration Sensor**(%%) is designed to (% style="color:blue" %)**detect and measure vibrations, shocks, and accelerations of an object**(%%). By analyzing the object's motion, the LHT65N-VIB can send meaningful data such as alarms, device runtime, vibration counts, and vibration strength to an IoT platform for further analysis.
24
25 It can be used in professional wireless sensor network applications, including (% style="color:blue" %)**equipment status monitoring, water leakage alarms, usage statistics, vibration intensity detection**(%%), and more.
26
27 The LHT65N-VIB (% style="color:blue" %)**supports a datalogging feature**(%%), allowing it to record data when there is no network coverage. Users can retrieve the sensor readings later, ensuring no data is missed.
28
29 The LHT65N-VIB enables users to send data over extremely long distances. It offers ultra-long-range spread spectrum communication and high interference immunity while minimizing current consumption.
30
31 The LHT65N-VIB has a(% style="color:blue" %)** built-in 2400mAh non-rechargeable battery**(%%), which can last up to (% class="mark" %)3 years*(%%).
32
33 The LHT65N-VIB is fully compatible with the LoRaWAN v1.0.3, Class A mode and can work with a standard LoRaWAN gateway.
34
35 (% class="mark" %)*The actual battery life depends on how frequently data is transmitted. Please refer to the battery analyzer chapter for more details.
36
37
38 == 1.2 Assembling the vibration probe ==
39
40
41 The LHT65N-VIB is sold with an external vibration sensor probe. The vibration sensor probe can be connected to the LHT65N-VIB using the USB Type-C connector. You can find the USB Type-C port on the LHT65N-VIB after removing the blue plastic cap.
42
43
44 [[image:lht65n-vib-probe.jpeg]]
45
46
47 == 1.2 Features ==
48
49
50 * LoRaWAN v1.0.3, Class A mode
51 * Frequency Bands: CN470, EU433, KR920, US915, EU868, AS923, AU915
52 * Detects object vibration status
53 * Detects vibration alarms
54 * 3-axis accelerometer for x, y, z axes
55 * Calculates device runtime
56 * Built-in 2400mAh battery for long-term use
57 * Built-in temperature and humidity sensor
58 * Tri-color LED to indicate working status
59 * Datalog feature (up to 3328 records)
60 * AT commands to change parameters
61 * Remote configuration of parameters via LoRaWAN downlink
62 * Firmware upgradeable via programming port
63
64 == 1.3 Specification ==
65
66
67 (% style="color:#037691" %)**Built-in Temperature Sensor:**
68
69 * Resolution: 0.01 °C
70 * Accuracy tolerance : Typ ±0.3 °C
71 * Long Term Drift: < 0.02 °C/yr
72 * Operating range: -40 ~~ 85 °C
73
74 (% style="color:#037691" %)**Built-in Humidity Sensor:**
75
76 * Resolution: 0.04 %RH
77 * Accuracy tolerance : Typ ±3 %RH
78 * Long Term Drift: < 0.25 RH/yr
79 * Operating range: 0 ~~ 96 %RH
80
81 (% style="color:#037691" %)**External Vibration Sensor:**
82
83 * Detecting object vibration status
84 * accelerator for x,y,z
85 * Small size for easy installation
86 * Acceleration: ±2g,±4g,±8g;±16g
87 * Frequency: 25 Hz, 50 Hz,100 Hz, 200 Hz, 400 Hz
88
89 = 2. Registering LHT65N-VIB with a LoRaWAN Network Server =
90
91
92 **The LHT65N-VIB can be registered with any LoRaWAN network server. In this documentation, we use The Things Stack as an example, but similar settings may apply to other LoRaWAN network servers.**
93
94
95 == 2.1 How does the LHT65N-VIB work? ==
96
97
98 (((
99 The LHT65N-VIB is configured in LoRaWAN Class A mode by default. Each LHT65N-VIB is shipped with a unique global registration key that supports OTAA (Over-The-Air-Activation). To use the LHT65N-VIB with a LoRaWAN network, you first need to register the device with the network using the provided registration keys for OTAA support.
100
101 The LHT65N-VIB's registration information can be found inside the device package.
102
103 [[image:image-20230426083319-1.png||_mstalt="431106" height="258" width="556"]]
104
105 The registration information includes the following:
106
107 * DevEUI
108 * AppEUI
109 * AppKey
110
111 Once registered, if the LHT65N-VIB is within the coverage area of the LoRaWAN network, it can automatically join the network. After successfully joining, the LHT65N-VIB will begin measuring environmental temperature and humidity and will start transmitting sensor data to the LoRaWAN network server. The default uplink transmission interval is 20 minutes.
112
113
114 )))
115
116 == 2.2 How to Activate LHT65N-VIB? ==
117
118
119 (((
120 (((
121 The LHT65N-VIB has two modes:
122 )))
123
124 * (((
125 (% style="color:blue" %)**Deep sleep mode**(%%): In this mode, the LHT65N-VIB doesn't perform any LoRaWAN activation. It is used for storage and shipping to conserve battery life.
126 )))
127
128 (((
129 * (% style="color:blue" %)**Working mode**(%%): In this mode, the LHT65N-VIB works as a LoRaWAN sensor, joining the LoRaWAN network and sending sensor data to the server. Between each sampling/TX/RX cycle, the LHT65N-VIB enters STOP mode (IDLE mode), where it consumes the same power as in deep sleep mode.
130 )))
131
132 The LHT65N-VIB is set in deep sleep mode by default. The **ACT** button on the front can be used to switch between different modes. See the image below:
133 )))
134
135 [[image:image-20230717144740-2.png||_mstalt="430794" height="391" width="267"]]
136
137 (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:510px" %)
138 |=(% style="width: 167px;background-color:#4F81BD;color:white" %)**Usage of the ACT button**|=(% style="width: 117px;background-color:#4F81BD;color:white" %)**Function**|=(% style="width: 226px;background-color:#4F81BD;color:white" %)**Action**
139 |(% style="background-color:#f2f2f2; width:167px" %)Pressing ACT between 1 - 3s|(% style="background-color:#f2f2f2; width:117px" %)Test uplink status|(% style="background-color:#f2f2f2; width:225px" %)(((
140 If LHT65N-VIB is already joined to the LoRaWAN network, it will send an uplink packet. If an external sensor is connected, the (% style="color:blue" %)**Blue LED** (%%)will blink once. If there is no external sensor, the (% style="color:red" %)**Red LED**(%%) will blink once.
141 )))
142 |(% style="background-color:#f2f2f2; width:167px" %)Pressing ACT for more than 3s|(% style="background-color:#f2f2f2; width:117px" %)Activate Device|(% style="background-color:#f2f2f2; width:225px" %)(((
143 The(% style="background-color:#f2f2f2; color:green" %)** Green LED**(%%) will blink quickly 5 times, indicating that the LHT65N-VIB is entering working mode and starting to join the LoRaWAN network. The (% style="background-color:#f2f2f2; color:green" %)**Green LED**(%%) will solid for 5 seconds after successfully joining the network.
144 )))
145 |(% style="background-color:#f2f2f2; width:167px" %)Fast press ACT 5 times.|(% style="background-color:#f2f2f2; width:117px" %)Deactivate Device|(% style="background-color:#f2f2f2; width:225px" %)The (% style="color:red" %)**Red LED**(%%) will remain solid for 5 seconds, indicating that the LHT65N-VIB is in Deep Sleep Mode.
146
147 {{info}}
148 We recommend that you activate the device using the ACT button after adding its registration information to the LoRaWAN network server. Otherwise, the device will continuously send join-request messages in an attempt to join a LoRaWAN network but will fail.
149 {{/info}}
150
151
152 == 2.3 Registering with The Things Stack ==
153
154
155 (% class="wikigeneratedid" %)
156 In this section we will guide you through on how to register the LHT65N-VIB with The Things Stack. If your area has **The Things Stack** community network coverage, you can use it without setting up your own network. If not, you can set up your own LoRaWAN network coverage by using our [[**LPS8N**>>https://www.dragino.com/products/lora-lorawan-gateway/item/200-lps8n.html]] LoRaWAN gateway.
157
158 (% class="wikigeneratedid" %)
159 The typical end-to-end network setup with LHT65N-VIB and LPS8v2 is shown below:
160
161 (% class="wikigeneratedid" %)
162 [[image:lht65n-vib-nw-diagram.jpg||height="363" width="1359"]]
163
164
165 === 2.3.1 Add LHT65N-VIB to The Things Stack ===
166
167
168 * From the LoRaWAN device repository
169 * Manually
170
171 ==== 3.2.2.1 Creating an application ====
172
173
174 Sign up for a free account with [[The Things Stack Sandbox>>url:https://eu1.cloud.thethings.network]] if you do not have one yet. Then, create an application as shown in the screenshots below.
175
176
177 ==== 3.2.2.2 Adding using the LoRaWAN device repository ====
178
179
180 You can refer to the screenshots below to register your LHT65N-VIB using The Things Stack's LoRaWAN device repository.
181
182 On The Things Stack console:
183
184 ~1. Click **Applications**.
185
186 2. Click <**your application**>. E.g. dragino-docs
187
188 3 Click **End devices**.
189
190 4. Click **+ Register end devic**e button.
191
192
193 [[image:lht65n-vib-1.png]]
194
195
196 On the Register end device page:
197
198 ~1. Click **Select the end device in the LoRaWAN Device Repository** option.
199
200 2. Select the following parameters:
201
202 * **End device brand**: Dragon Technology Co., Limited
203 * **Model**: LHT65 - Temperature and Humidity Sensor. //**The LHT65N-VIB Vibration Sensor uses the same template as the LHT65 - Temperature and Humidity Sensor.**//
204 * **Hardware Ver**: Unknown Ver.
205 * **Firmware Ver**: 1.9.1
206 * **Profile (Region)**: Select the region that matches your device. E.g.: EU_863_870
207
208 3. **Frequency plan**: Select the frequency plan that matches your device. E.g.: Europe 863-870 MHz (SF9 for RX2 - recommended).
209
210 [[image:lht65n-vib-9.png]]
211
212
213 4. **JoinEUI**: Enter the AppEUI of the device (see the registration information sticker) and Click the **Confirm** button.
214
215 5. **DevEUI**: Enter the DevEUI of the device (see the registration information sticker).
216
217 6. **AppKey**: Enter the AppKey of the device (see the registration information sticker).
218
219 7. **End device ID**: Enter a name for your end device to uniquely identify it within this application.
220
221 8. Click **View registered end device** option.
222
223 9. Click **Register end device** button.
224
225
226 [[image:lht65n-vib-2.png]]
227
228
229 You will be navigated to the **Device overview **page.
230
231
232 ==== 3.2.2.3 Adding manually ====
233
234
235 You can refer to the screenshots below to register your LHT65N-VIB using The Things Stack's manual option.
236
237
238 1-4: Same as in the section 3.2.2.2.
239
240 5. Select **Enter end device specifies manually** option.
241
242 6. **Frequency plan**: Select the frequency plan that matches your device. E.g.: Europe 863-870 MHz (SF9 for RX2 - recommended).
243
244 7. **LoRaWAN version**: LoRaWAN Specification 1.0.3
245
246 8. Regional Parameters version: You can't change it and it will select automatically.
247
248
249 [[image:lht65n-vib-3.png]]
250
251
252 9. Click on the **Show advanced activation, LoRaWAN class and cluster settings **to expand the section.
253
254 10. Select **Over the air activation (OTAA**) option.
255
256 ~11. Select **None (class A only)**.
257
258 12. **JoinEUI**: Enter the **AppEUI** of the device (see the registration information sticker) and Click the **Confirm** button.
259
260
261 [[image:lht65n-vib-4.png]]
262
263
264 13. **DevEUI**: Enter the DevEUI of the device (see the registration information sticker).
265
266 14. **AppKey**: Enter the AppKey of the device (see the registration information sticker).
267
268 15. **End device ID**: Enter a name for your end device to uniquely identify it within this application.
269
270 16. Click **View registered end device** option.
271
272 17. Click **Register end device** button.
273
274 [[image:lht65n-vib-5.png]]
275
276
277 You will be navigated to the **Device overview **page.
278
279
280 === 2.3.2 Activate the LHT65N-VIB by pressing and holding the ACT button for more than 5 seconds. ===
281
282 (((
283
284
285 Press and hold the **ACT** button for more than 5 seconds to activate the LHT65N-VIB. It will then join The Things Stack. Once successfully connected, the device will begin uplinking sensor data to The Things Stack, which can be viewed on the Live data panel.
286 )))
287
288 [[image:image-20241011171332-1.png||height="238" width="816"]]
289
290
291 === 2.3.3 Uplink Decoder in The Things Stack ===
292
293
294 When the uplink payload arrives in The Things Stack, it is displayed in HEX format, which is not easy to read. You can add the LHT65N-VIB decoder in The Things Stack for easier readability of each sensor readings.
295
296 The uplink decoder can be added to the** Payload Formatters** of your device in The Things Stack. Refer to the screenshot below.
297
298 ~1. Click **Uplink** tab.
299
300 2. **Formatter type:** Select Custom Javascript formatter.
301
302 3. **Formatter code**: Copy the uplink payload formatter code from our [[dragino-end-node-decoder GitHub repository>>https://github.com/dragino/dragino-end-node-decoder/blob/main/LHT65N-VIB/LHT65N-VIB_TTN_Decoder.txt]] and paste it here.
303
304 4. Finally, click on the **Save changes** button.
305
306 [[image:Screenshot 2024-12-03 at 17.34.15.png]]
307
308
309 == 2.4 Uplink Payload (FPort~=2) ==
310
311 (((
312
313
314 The uplink payload is a total of 11 bytes. Uplink packets use **FPort=2 **and, by default, are sent (% style="color:#4f81bd" %)**every 20 minutes.**
315 )))
316
317 (((
318 After each uplink, the (% style="color:blue" %)**BLUE LED**(%%) blinks once.
319
320 There are four different working modes, and the uplink payload format varies for each mode:
321
322 * **VIBMOD=1** : vibration count, work_min
323 * **VIBMOD=2** : TempC_SHT, Hum_SHT, vib_count
324 * **VIBMOD=3** : TempC_SHT, Hum_SHT, vib_min
325 * **VIBMOD=4** : X, Y, Z
326
327
328 )))
329
330 === 2.4.1 VIBMOD~=1 : Vibration Count, Run Time ===
331
332
333 VIBMOD=1 represent the battery voltage, working mode, alarm status, TDC, vibration count, and work_min. The uplink payload is shown below.
334
335 (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:360px" %)
336 |=(% style="width: 80px;background-color:#4F81BD;color:white" %)(((
337 **Size(bytes)**
338 )))|=(% style="width: 40px;background-color:#4F81BD;color:white" %)(((
339 **2**
340 )))|=(% style="width: 80px;background-color:#4F81BD;color:white" %)(((
341 1
342 )))|=(% style="width: 80px;background-color:#4F81BD;color:white" %)(((
343 **4**
344 )))|=(% style="width: 80px;background-color:#4F81BD;color:white" %)(((
345 4
346 )))
347 |(% style="width:110px" %)(((
348 Value
349 )))|(% style="width:71px" %)(((
350 BAT
351 )))|(% style="width:99px" %)MOD
352 Alarm
353 TDC|(% style="width:132px" %)vib_count|(% style="width:54px" %)work_min
354
355 [[image:image-20241011175741-3.png||height="187" width="1023"]]
356
357
358 The following subsections describe each field:
359
360
361 ==== 2.4.1.1 BAT (Battery Voltage) ====
362
363
364 These two bytes represent the battery voltage. See the image below.
365
366 [[image:image-20241012091339-4.png||height="92" width="787"]]
367
368
369 Calculate the battery voltage for the LHT65N-VIB, if the BAT=0B F2.
370
371 Convert 0x0BF2 to decimal (3058) and then divide by 1000 to get the voltage.
372
373 * (% class="mark" style="color:#ff0000; font-family:Arial,sans-serif; font-size:10.5pt; font-style:normal; font-variant-alternates:normal; font-variant-east-asian:normal; font-variant-ligatures:normal; font-variant-numeric:normal; font-variant-position:normal; font-weight:400; text-decoration:none; white-space:pre-wrap" %)0x0BF2 (hex) = 3058 (dec)
374 * (% class="mark" style="color:#ff0000; font-family:Arial,sans-serif; font-size:10.5pt; font-style:normal; font-variant-alternates:normal; font-variant-east-asian:normal; font-variant-ligatures:normal; font-variant-numeric:normal; font-variant-position:normal; font-weight:400; text-decoration:none; white-space:pre-wrap" %)3058/1000 = 3.058 V
375
376 ==== 2.4.1.2 MOD, Alarm, and TDC ====
377
378
379 This byte represent working mode, alarm status, and TCD. See the image below.
380
381 [[image:image-20241012092023-5.png||height="89" width="792"]]
382
383 [[image:image-20250320103348-1.png||height="77" width="785"]]
384
385 (% class="mark" %)bytes[2]=0x06=0000 0110
386
387 (% class="mark" %)**Current working mode:**
388
389 * (% class="mark" %)(bytes[2]>>2)&0x07
390 * (% class="mark" %)Shift two bits to right (0000 0110 -> 0000 0001)
391 * (% class="mark" %)Then bitwise AND with 0x07 (0000 0001 & 0000 0111 = 0000 0001 = **1**)
392
393 (% class="mark" %)**Current alarm status:**
394
395 * (% class="mark" %)(bytes[2] & 0x01)? "TRUE":"FALSE"
396 * (% class="mark" %)0000 0110 & 0000 0001 = 0000 0000 = 0 = **FALSE**
397
398 (% class="mark" %)**Is the current data triggered by TDC (data uploaded due to alarm)?**
399
400 * (% class="mark" %)(bytes[2] & 0x02)? "YES":"NO"
401 * (% class="mark" %)0000 0110 & 0000 0010 = 0000 0010 = 2 (NON-ZERO VALUE) = **YES**
402
403 ==== 2.4.1.3 vib_count ====
404
405
406 These 4 bytes (vib_count) represent the number of vibration events that has been recorded. See the image below.
407
408 [[image:image-20241012092938-6.png||height="102" width="770"]]
409
410 * (% class="mark" %)0x00000007=7
411
412 ==== 2.4.1.4 work_min ====
413
414
415 These 4 bytes (work_min) indicate the duration the current vibration sensor has been active since the latest trigger. See the image below.
416
417 [[image:image-20241012093112-7.png||height="68" width="775"]]
418
419 * (% class="mark" %)0x00000000=0
420
421 (% class="mark" %)0 means that the current vibration sensor is not triggered.
422
423
424 === 2.4.2 VIBMOD~=2 : Vibration Count,Temperature,Humidity ===
425
426
427 VIBMOD=2 represent the battery voltage, working mode, alarm status, TDC, vibration count, TempC_SHT, and Hum_SHT. The uplink payload is shown below.
428
429
430 (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:380px" %)
431 |=(% style="width: 60px;background-color:#4F81BD;color:white" %)(((
432 **Size(bytes)**
433 )))|=(% style="width: 40px;background-color:#4F81BD;color:white" %)(((
434 **2**
435 )))|=(% style="width: 70px;background-color:#4F81BD;color:white" %)(((
436 1
437 )))|=(% style="width: 70px;background-color:#4F81BD;color:white" %)(((
438 **4**
439 )))|=(% style="width: 70px;background-color:#4F81BD;color:white" %)(((
440 2
441 )))|=(% style="width: 70px;background-color:#4F81BD;color:white" %)(((
442 2
443 )))
444 |(% style="width:110px" %)(((
445 Value
446 )))|(% style="width:71px" %)(((
447 BAT
448 )))|(% style="width:99px" %)MOD
449 Alarm
450 TDC|(% style="width:132px" %)vib_count|(% style="width:54px" %)TempC_SHT|(% style="width:54px" %)Hum_SHT
451
452 [[image:image-20241012093705-8.png||height="106" width="879"]]
453
454
455 ==== 2.4.2.1 BAT (Battery Voltage) ====
456
457
458 These two bytes represent the battery voltage. See the image below.
459
460 [[image:image-20241012094035-9.png||height="71" width="946"]]
461
462
463 Calculate the battery voltage for LHT65N-VIB.
464
465 * (% class="mark" %)0x0BC6/1000=3.014V
466
467 ==== 2.4.2.2 VIBMOD, Alarm and TDC ====
468
469
470 This byte represent working mode, alarm status, and TCD. See the image below.
471
472 [[image:image-20241012094131-10.png||height="126" width="934"]]
473
474 (% class="mark" %)bytes[2]=0x0A=0000 0101
475
476 (% class="mark" %)Current working mode=(bytes[2]>>2)&0x07=2
477
478 (% class="mark" %)Current alarm situation= (bytes[2] & 0x01)? "TRUE":"FALSE";=0=FALSE
479
480 (% class="mark" %)Whether the current data occurs is TDC (the data will be uploaded by the alarm)= (bytes[2] & 0x02)? "YES":"NO";=00000010 (non -zero value)=YES
481
482
483 ==== 2.4.2.3 vib_count ====
484
485
486 These 4 bytes represent the number of vibration events that has been recorded. See the image below.
487
488 [[image:image-20241012094340-11.png||height="92" width="954"]]
489
490 * (% class="mark" %)0x00000000=0
491
492 ==== 2.4.2.4 TempC_SHT ====
493
494
495 These 2 bytes represent the temperature measured by the built-in temperature & humidity sensor, SHT31.
496
497 [[image:image-20241012094549-12.png||height="64" width="941"]]
498
499 * (% class="mark" %)0x0B22/100=28.5 C
500
501 ==== 2.4.2.5 Hum_SHT ====
502
503
504 These 2 bytes represent the humidity measured by the built-in temperature & humidity sensor, SHT31.
505
506 [[image:image-20241012094803-13.png||height="76" width="950"]]
507
508 * (% class="mark" %)0x0212/10=53
509
510 === 2.4.3 VIBMOD~=3: Run Time,Temperature,Humidity ===
511
512
513 VIBMOD=3 represents the battery voltage, working mode, alarm status, TDC, TempC_SHT, Hum_SHT, and work_min. The uplink payload is shown below.
514
515 (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:380px" %)
516 |=(% style="width: 60px;background-color:#4F81BD;color:white" %)(((
517 **Size(bytes)**
518 )))|=(% style="width: 40px;background-color:#4F81BD;color:white" %)(((
519 **2**
520 )))|=(% style="width: 70px;background-color:#4F81BD;color:white" %)(((
521 1
522 )))|=(% style="width: 70px;background-color:#4F81BD;color:white" %)(((
523 **2**
524 )))|=(% style="width: 70px;background-color:#4F81BD;color:white" %)(((
525 2
526 )))|=(% style="width: 70px;background-color:#4F81BD;color:white" %)(((
527 4
528 )))
529 |(% style="width:110px" %)(((
530 Value
531 )))|(% style="width:71px" %)(((
532 BAT
533 )))|(% style="width:99px" %)MOD
534 Alarm
535 TDC|(% style="width:132px" %)TempC_SHT|(% style="width:54px" %)Hum_SHT|(% style="width:54px" %)work_min
536
537 [[image:image-20241012094926-14.png||height="91" width="984"]]
538
539
540 ==== 2.4.3.1 BAT (Battery Voltage) ====
541
542
543 These 2 bytes represent the battery voltage.
544
545 [[image:image-20241012095155-15.png]]
546
547 * (% class="mark" %)0x0BC2/1000=3.01V
548
549 ==== 2.4.3.2 VIBMOD and Alarm and TDC ====
550
551
552 This byte represents the working mode, alarm status, and TDC.
553
554 [[image:image-20241012095322-16.png||height="101" width="1094"]]
555
556 (% class="mark" %)bytes[2]=0x0A=0000 1110
557
558 (% class="mark" %)Current working mode=(bytes[2]>>2)&0x07=3
559
560 (% class="mark" %)Current alarm situation= (bytes[2] & 0x01)? "TRUE":"FALSE";=0=FALSE
561
562 (% class="mark" %)Whether the current data occurs is TDC (the data will be uploaded by the alarm)= (bytes[2] & 0x02)? "YES":"NO";=00000010 (non -zero value)=YES
563
564
565 ==== 2.4.3.3 TempC_SHT ====
566
567
568 These 2 bytes represent the temperature measured by the built-in temperature & humidity sensor, SHT31.
569
570 [[image:image-20241012095445-17.png]]
571
572 * (% class="mark" %)0x0B21/100=28.49 C
573
574 ==== 2.4.3.4 Hum_SHT ====
575
576
577 These 2 bytes represent the humidity measured by the built-in temperature & humidity sensor, SHT31.
578
579 [[image:image-20241012095509-18.png]]
580
581 * (% class="mark" %)0x0213/10=53.1
582
583 ==== 2.4.3.5 work_min ====
584
585
586 These 4 bytes (work_min) indicate the duration the current vibration sensor has been active since the latest trigger. See the image below.
587
588 [[image:image-20241012095558-19.png||height="83" width="1029"]]
589
590 * (% class="mark" %)0x00000000=0
591
592 (% class="mark" %)0 means that the current vibration sensor is not triggered.
593
594
595 === 2.4.4 VIBMOD~=4 :Three-axis X-Y-Z vibration data(FPort~=7) ===
596
597
598 VIBMOD=4 represents the battery voltage and the accelerometer data. The uplink payload is shown below.
599
600 (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:310px" %)
601 |=(% style="width: 60px;background-color:#4F81BD;color:white" %)(((
602 **Size(bytes)**
603 )))|=(% style="width: 50px; background-color: rgb(79, 129, 189); color: white;" %)(((
604 **2**
605 )))|=(% style="width: 50px; background-color: rgb(79, 129, 189); color: white;" %)(((
606 2
607 )))|=(% style="width: 50px; background-color: rgb(79, 129, 189); color: white;" %)(((
608 **2**
609 )))|=(% style="width: 50px; background-color: rgb(79, 129, 189); color: white;" %)(((
610 2
611 )))|=(% style="width: 50px; background-color: rgb(79, 129, 189); color: white;" %)(((
612 2
613 )))
614 |(% style="width:110px" %)(((
615 Value
616 )))|(% style="width:40px" %)(((
617 BAT
618 )))|(% style="width:50px" %)X|(% style="width:44px" %)Y|(% style="width:43px" %)Z|(% style="width:133px" %)......
619
620 [[image:image-20241014171434-4.png]]
621
622
623 (% class="mark" %)The first two bytes represent the battery voltage, for example 0A F3.
624
625 (% class="mark" %)The reset of the bytes represents the accelerometer data on axis X, Y, and Z. Each axis represent in 2 bytes.
626
627 (% class="mark" %)**X = 0xFC50. In binary, it is represented as 1111110001010000. The highest bit is 1, indicating a negative number in two's complement notation, and its value is -944.**
628
629 (% class="mark" %)Y=0x0014=20
630
631 (% class="mark" %)Z=0x00F6=246
632
633
634 == 2.5 Integrating with IoT platforms ==
635
636
637 The LHT65N-VIB sensor data can be integrated with other IoT platforms for better visualizing and analyzing the data. In this section, we will show you how to integrate sensor data from The Things Stack with some popular IoT platforms.
638
639
640 === 2.5.1 Integrate and show data on ThingsEye ===
641
642
643 The Things Stack application supports integration with ThingsEye.io. Once integrated, ThingsEye.io acts as an MQTT client for The Things Stack MQTT broker, allowing it to subscribe to upstream traffic and publish downlink traffic.
644
645 {{info}}
646 The integration will link The Things Stack application (with all the devices) with ThingsEye. You can select sensor data fields from each device when creating the ThingsEye dashboards.
647 {{/info}}
648
649
650 ==== 2.5.1.1 Configuring The Things Stack ====
651
652
653 We use The Things Stack Sandbox in this example:
654
655 * In **The Things Stack Sandbox**, go to the **Application **for the LHT65N-VIB you added.
656 * Select **MQTT** under **Integrations** in the left menu.
657 * In the **Connection information **section, under **Connection credentials**, The Things Stack displays an auto-generated **username**. You can use it or provide a new one.
658 * Click the **Generate new API key** button to generate a password. You can view it by clicking on the **visibility toggle/eye** icon. The API key works as the password.
659
660 {{info}}
661 The username and  password (API key) you created here are required in the next section.
662 {{/info}}
663
664
665 [[image:https://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/LT-22222-L/WebHome/tts-mqtt-integration.png?rev=1.1||alt="tts-mqtt-integration.png"]]
666
667
668 ==== 2.5.1.2 Configuring ThingsEye.io ====
669
670
671 The ThingsEye.io IoT platform is not open for self-registration at the moment. If you are interested in testing the platform, please send your project information to admin@thingseye.io, and we will create an account for you.
672
673 * Login to your [[ThingsEye.io >>url:https://thingseye.io]]account.
674 * Under the **Integrations center**, click **Integrations**.
675 * Click the **Add integration** button (the button with the **+** symbol).
676
677 (% class="wikigeneratedid" %)
678 [[image:https://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/LT-22222-L/WebHome/thingseye-io-step-1.png?rev=1.2||alt="thingseye-io-step-1.png"]]
679
680
681 On the **Add integration** window, configure the following:
682
683 **Basic settings:**
684
685 * Select **The Things Stack Community** from the **Integration type** list.
686 * Enter a suitable name for your integration in the **Name **text** **box or keep the default name.
687 * Ensure the following options are turned on.
688 ** Enable integration
689 ** Debug mode
690 ** Allow create devices or assets
691 * Click the **Next** button. you will be navigated to the **Uplink data converter** tab.
692
693 (% class="wikigeneratedid" %)
694 [[image:https://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/LT-22222-L/WebHome/thingseye-io-step-2.png?rev=1.1||alt="thingseye-io-step-2.png"]]
695
696
697 **Uplink data converter:**
698
699 * Click the **Create new** button if it is not selected by default.
700 * Enter a suitable name for the uplink data converter in the **Name **text** **box or keep the default name.
701 * Click the **JavaScript** button.
702 * Paste the uplink decoder function into the text area (first, delete the default code). The demo uplink decoder function can be found [[here>>url:https://raw.githubusercontent.com/ThingsEye-io/te-platform/refs/heads/main/Data%20Converters/The_Things_Network_MQTT_Uplink_Converter.js]].
703 * Click the **Next** button. You will be navigated to the **Downlink data converter **tab.
704
705 (% class="wikigeneratedid" %)
706 [[image:https://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/LT-22222-L/WebHome/thingseye-io-step-3.png?rev=1.1||alt="thingseye-io-step-3.png"]]
707
708
709 **Downlink data converter (this is an optional step):**
710
711 * Click the **Create new** button if it is not selected by default.
712 * Enter a suitable name for the downlink data converter in the **Name **text** **box or keep the default name.
713 * Click the **JavaScript** button.
714 * Paste the downlink decoder function into the text area (first, delete the default code). The demo downlink decoder function can be found [[here>>url:https://raw.githubusercontent.com/ThingsEye-io/te-platform/refs/heads/main/Data%20Converters/The_Things_Network_MQTT_Downlink_Converter.js]].
715 * Click the **Next** button. You will be navigated to the **Connection** tab.
716
717 (% class="wikigeneratedid" %)
718 [[image:https://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/LT-22222-L/WebHome/thingseye-io-step-4.png?rev=1.1||alt="thingseye-io-step-4.png"]]
719
720
721 **Connection:**
722
723 * Choose **Region** from the **Host type**.
724 * Enter the **cluster** of your **The Things Stack** in the **Region** textbox. You can find the cluster in the url (e.g., https:~/~/**eu1**.cloud.thethings.network/...).
725 * Enter the **Username** and **Password** of the MQTT integration in the **Credentials** section. The **username **and **password **can be found on the MQTT integration page of your The Things Stack account (see **2.5.1.1 Configuring The Things Stack**).
726 * Click the **Check connection** button to test the connection. If the connection is successful, you will see the message saying **Connected**.
727
728 [[image:https://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/LT-22222-L/WebHome/message-1.png?rev=1.1||alt="message-1.png"]]
729
730
731 * Click the **Add** button.
732
733 [[image:https://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/LT-22222-L/WebHome/thingseye-io-step-5.png?rev=1.1||alt="thingseye-io-step-5.png"]]
734
735
736 Your integration has been added to the** Integrations** list and will be displayed on the **Integrations** page. Check whether the status is shown as **Active**. If not, review your configuration settings and correct any errors.
737
738 [[image:https://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/LT-22222-L/WebHome/thingseye.io_integrationsCenter_integrations.png?rev=1.2||alt="thingseye.io_integrationsCenter_integrations.png"]]
739
740
741 ==== 2.5.1.3 Viewing integration details ====
742
743
744 Click on your integration from the list. The **Integration details** window will appear with the **Details **tab selected. The **Details **tab shows all the settings you have provided for this integration.
745
746 (% class="wikigeneratedid" %)
747 [[image:https://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/LT-22222-L/WebHome/integration-details.png?rev=1.1||alt="integration-details.png"]]
748
749
750 If you want to edit the settings you have provided, click on the **Toggle edit mode** button. Once you have done click on the **Apply changes **button.
751
752 {{info}}
753 See also [[ThingsEye documentation>>url:https://wiki.thingseye.io/xwiki/bin/view/Main/]].
754 {{/info}}
755
756 * To view the **JSON payload** of a message, click on the **three dots (...)** in the Message column of the desired message.
757
758 [add JSON payload screen capture here]
759
760
761 ==== 2.5.1.4 Viewing events ====
762
763
764 The **Events **tab displays all the uplink messages from the LHT65N-VIB.
765
766 * Select **Debug **from the **Event type** dropdown.
767 * Select the** time frame** from the **time window**.
768
769 [[image:https://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/LT-22222-L/WebHome/thingseye-events.png?rev=1.1||alt="thingseye-events.png"]]
770
771
772 * To view the **JSON payload** of a message, click on the **three dots (...)** in the **Message** column of the desired message.
773
774 [[image:lht65n-vib.png]]
775
776
777 ==== 2.5.1.5 Viewing Sensor data on a dashboard ====
778
779
780 You can create a dashboard with ThingsEye to visualize the sensor data coming from the LHT65N-VIB. The following image shows a dashboard created for the LHT65N-VIB. See **Creating a dashboard** in ThingsEye documentation for more information.
781
782
783 [[image:lht65n-vib-dashboard.png]]
784
785
786
787 ==== 2.5.1.6 Deleting an integration ====
788
789
790 If you want to delete an integration, click the **Delete integration** button on the Integrations page.
791
792
793 === 2.5.2 Integrate and show data on Datacake ===
794
795
796 (((
797 The **Datacake **IoT platform provides a user-friendly interface to display sensor data. With this integration, once you receive the sensor data in **The Things Stack** application, you can send it to **Datacake** for further processing.
798
799 * Ensure that LHT65N-VIB is properly connected to The Things Stack.
800
801 Now configure your The Things Stack application to forward data to Datacake by adding an integration with webhooks.
802
803 * In The Things Stack console, navigate to **Applications → <your application> → Integrations → Webhooks → + Add webhook.**
804
805 [[image:eu1.cloud.thethings.network_console_applications_dragino-docs_integrations_webhooks(Laptop with HiDPI screen).png]]
806
807 * In the **Choose webhook template** page, select **Datacake**.
808 )))
809
810
811 [[image:eu1.cloud.thethings.network_console_applications_dragino-docs_integrations_webhooks_add_template(Laptop with HiDPI screen).png]]
812
813 (((
814
815
816 In Datacake, go to **Account Settings**, then navigate to the **API Token** tab. Click the **Copy** button to copy the **API token**.
817
818 [[image:datacake-1.png]]
819
820
821 On the **Setup webhook for Datacake** page, enter the **Webhook ID** and paste the **Datacake API Token**. Then select the **Create Datacake webhook** button.
822
823 [[image:eu1.cloud.thethings.network_console_applications_dragino-docs_integrations_webhooks_add_template(Laptop with HiDPI screen) (2).png]]
824
825
826 )))
827
828 In the Datacake console ([[https:~~/~~/datacake.co/>>url:https://datacake.co/]]) , add LHT65N-VIB as follows.
829
830 ~1. On the left navigation, select **Devices**.
831
832 2. Click **+ Add Device** button.
833
834 [[image:datacake-7.png]]
835
836
837 ~1. On the **Add Device** window, select the connectivity type of your device, in this case select **LoRaWAN**.
838
839 2. Click **Next** button.
840
841 [[image:datacake-2.png]]
842
843
844 On the **Add LoRaWAN Device** window, under **Product**,
845
846 ~1. Select **New Product from template**.
847
848 2. Search for **lht65**
849
850 3. Select, **Dragino LHT65, LHT65N+ Temp & Hum **from the filtered list.
851
852 Click **Next** button.
853
854 [[image:datacake-3.png]]
855
856
857 On the **Add LoRaWAN Device** window, under **Network Server,**
858
859 ~1. Select **The Things Stack V3**.
860
861 Click **Next** button.
862
863 [[image:datacake-5.png]]
864
865
866 On the **Add LoRaWAN Device** window, under **Devices**,
867
868 ~1. Enter your LHT65N-VIB's **DevEUI** in the **DevEUI** field.
869
870 2. Assign a **name** for your device in the **Name** field.
871
872 Click **Next** button.
873
874 [[image:datacake-6.png]]
875
876
877 [will be continued... add more screenshots here]
878
879 [[image:image-20220523000825-10.png||_mstalt="450619"]]
880
881
882 == 2.8 LED Indicator ==
883
884
885 The LHT65N-VIB has a **tri-color LED** for easily indicating different stages.
886
887 When the user presses the ACT button, the LED will function according to the LED status linked to the ACT button.
888
889 In a normal working state:
890
891 * For each uplink, the **BLUE** or **RED** LED will blink once:
892 ** **BLUE LED**: Indicates an external sensor is connected.
893 ** **RED LED**: Indicates no external sensor is connected.
894 * For each successful downlink, the **PURPLE** **LED** will blink once.
895
896 == 2.9 Installation ==
897
898 This sections explains the assembling and installation instructions.
899
900 === 2.9.1 Attaching the vibration probe ===
901
902 The LHT65N-VIB is sold with an external vibration sensor probe. The vibration sensor probe can be connected to the LHT65N-VIB using its USB Type-C connector. You can find the USB Type-C port on the LHT65N-VIB after removing the blue plastic cap.
903
904 [[image:lht65n-vib-probe.jpeg]]
905
906
907 === 2.9.2 Installing on an object ===
908
909 The LHT65N should be installed vertically on objects, with the sensor parallel to the object's surface.
910
911 [[image:image-20220516231650-1.png||_mstalt="428597" height="436" width="428"]]
912
913
914 = 3. Configure the LHT65N-VIB via AT commands or LoRaWAN downlinks =
915
916
917 (((
918 You can configure the LHT65N-VIB via AT commands or LoRaWAN Downlinks.
919 )))
920
921 * (((
922 Configure via AT Commands: See the [[FAQ>>||anchor="H6.FAQ"]] for instructions on **How to connect to the LHT65N-VIB's UART interface**
923 )))
924
925 * (((
926 LoRaWAN downlink instructions for different platforms: Refer to the [[IoT LoRaWAN Server>>doc:Main.WebHome]]
927 )))
928
929 (((
930
931
932 There are two kinds of commands to configure the LHT65N-VIB:
933 )))
934
935 (((
936 (% style="color:#4f81bd" %)**1. General Commands**.
937 )))
938
939 (((
940 These commands are the same for all Dragino devices that support the DLWS-005 LoRaWAN Stack (Note~*~*). You can find these commands on the wiki: [[End Device Downlink Command>>doc:Main.End Device AT Commands and Downlink Command.WebHome]].
941
942 These commands can be used to configure:
943 )))
944
945 (((
946 * General system settings, such as uplink interval.
947 )))
948
949 (((
950 * LoRaWAN protocol and radio-related settings.
951 )))
952
953 (((
954
955
956 (% style="color:#4f81bd" %)**2. Commands design specially for the LHT65N**(%%)-VIB
957 )))
958
959 (((
960 These commands are only valid for the LHT65N-VIB and are listed below:
961 )))
962
963
964 == 3.1 Set Uplink Transmit Interval ==
965
966
967 **Feature**: Change the LHT65N-VIB's uplink transmission Interval.
968
969 (% style="color:#4f81bd" %)**AT command**
970
971 (% border="2" style="width:500px" %)
972 |(% style="width:142px" %)**Command**|(% style="width:356px" %)AT+TDC
973 |(% style="width:142px" %)**Parameters**|(% style="width:356px" %)**time** : time in milliseconds
974 |(% style="width:142px" %)**Get**|(% style="width:356px" %)AT+TDC=?
975 |(% style="width:142px" %)**Response**|(% style="width:356px" %)returns the current uplink interval
976 |(% style="width:142px" %)**Set**|(% style="width:356px" %)AT+TDC=<time>
977 |(% style="width:142px" %)**Response**|(% style="width:356px" %)<time> OK
978 |(% style="width:142px" %)**Example**|(% style="width:356px" %)AT+TDC=60000 ~/~/ Set uplink time interval to 60 seconds.
979
980 (% style="color:#4f81bd" %)**Downlink command**
981
982 (% border="2" style="width:500px" %)
983 |(% style="width:141px" %)**Prefix**|(% style="width:357px" %)0x01
984 |(% style="width:141px" %)**Parameters**|(% style="width:357px" %)**time** : time in seconds - 3 bytes in hexadecimal
985 |(% style="width:141px" %)**Payload format**|(% style="width:357px" %)<prefix><time>
986 |(% style="width:141px" %)**Example**|(% style="width:357px" %)(((
987 * 01**00001E ** ~/~/ Set uplink interval (TDC) to 30 seconds
988
989 * 01**00003C**  ~/~/ Set uplink interval (TDC) to 60 seconds
990 )))
991
992 == 3.2 Set Vibration Sensor Mode ==
993
994
995 **Feature**: Sets the Vibration Sensor Mode.
996
997 (% style="color:#4f81bd" %)**AT command**
998
999 (% border="2" style="width:500px" %)
1000 |(% style="width:143px" %)**Command**|(% style="width:355px" %)AT+VIBMOD
1001 |(% style="width:143px" %)**Parameters**|(% style="width:355px" %)(((
1002 **mode** : 1, 2, 3, 4
1003
1004 **alarm_time**: Sets the duration of continuous operation required to trigger the alarm (unit: seconds). (Set AlarmTimeout to 0 to disable the alarm.) - only applicable with mode 1, 2, 3
1005
1006 **stop_duration_time**: Specifies the interval after which the event is counted as a trigger. - only applicable with mode 1, 2, 3
1007
1008 **collection_interval **: Collection Interval (unit: seconds) - only applicable with mode 4.
1009
1010 **groups** : Number of groups - only applicable with mode 4
1011 )))
1012 |(% style="width:143px" %)**Set**|(% style="width:355px" %)(((
1013 for mode 1,2,3:
1014
1015 AT+VIBMOD=<mode><alarm_timeout><stop_duration_time>
1016
1017 for mode 4:
1018
1019 AT+VIBMOD=<mode><collection_interval><gropus>
1020 )))
1021 |(% style="width:143px" %)**Example**|(% style="width:355px" %)(((
1022 **AT+VIBMOD=1,60,10**
1023
1024 **MOD1** will display **vib_count** and **work_min** without temperature and humidity. If vibration stops for more than 60 seconds, an alarm message is generated.
1025
1026 If vibration stops for more than 10 seconds, **vib_count** increases by one, and **work_min** resets to zero.
1027
1028
1029 **AT+VIBMOD=4,1,10**
1030
1031 MOD4 sets the collection interval to 10 seconds and collects 1 sets of data in total.
1032 )))
1033
1034 [[image:image-20241014171308-3.png||height="65" width="709"]]
1035
1036
1037 (% style="color:#4f81bd" %)**Downlink command**
1038
1039 (% border="2" style="width:500px" %)
1040 |(% style="width:137px" %)**Prefix**|(% style="width:361px" %)0x0A
1041 |(% style="width:137px" %)**Parameters**|(% style="width:361px" %)(((
1042 **mode** : 1, 2, 3, 4 [1 byte in hex]
1043
1044 **alarm_time**: Sets the duration of continuous operation required to trigger the alarm (unit: seconds). (Set AlarmTimeout to 0 to disable the alarm.) - only applicable with mode 1, 2, and 3 [2 byte in hex]
1045
1046 **stop_duration_time**: Specifies the interval after which the event is counted as a trigger. - only applicable with mode 1, 2, and 3 [2 bytes in hex]
1047
1048 **collection_interval **: Collection Interval (unit: seconds) - only applicable with mode 4. [2 bytes in hexadecimal]
1049
1050 **groups** : Number of groups - only applicable with mode 4. [2 bytes in hexadecimal]
1051 )))
1052 |(% style="width:137px" %)**Payload format**|(% style="width:361px" %)(((
1053 for mode 1, 2, 3:
1054
1055 <prefix><mode><alarm_time><stop_duration_time>
1056
1057
1058 for mode 4:
1059
1060 <prefix><mode><collection_interval><groups>
1061 )))
1062 |(% style="width:137px" %)**Example**|(% style="width:361px" %)(((
1063 * 0A01003C000A
1064
1065 **MOD1** will display **vib_count** and **work_min** without temperature and humidity. If vibration stops for more than 60 seconds, an alarm message is generated.
1066
1067 If vibration stops for more than 10 seconds, **vib_count** increases by one, and **work_min** resets to zero.
1068
1069 * 0A0400010A
1070
1071 **MOD4** sets the collection interval to 10 seconds and collects 1 sets of data in total.
1072 )))
1073
1074 == 3.3 Vibration sensitivity setting ==
1075
1076
1077 **Feature**: Allows adjustment of sensitivity settings for different usage scenarios.
1078
1079
1080 (% style="color:#4f81bd" %)**AT Command:**
1081
1082 (% border="2" style="width:500px" %)
1083 |(% style="width:134px" %)**Command**|(% style="width:364px" %)AT+VIBSET
1084 |(% style="width:134px" %)**Parameters**|(% style="width:364px" %)(((
1085 **acceleration** :
1086
1087 * 0: ±2g
1088 * 1: ±4g
1089 * 2: ±8g
1090 * 3: ±16g
1091
1092 **frequency** :
1093
1094 * 0:25Hz
1095 * 1:50Hz
1096 * 2:100Hz
1097 * 3:200Hz
1098 * 4:400Hz
1099
1100 **threshold** : interrupt threshold
1101
1102 **duration** : Interrupt detection duration in milliseconds
1103 )))
1104 |(% style="width:134px" %)**Set**|(% style="width:364px" %)AT+VIBSET=<acceleration><frequency><threshold><duration>
1105 |(% style="width:134px" %)**Response**|(% style="width:364px" %)OK
1106 |(% style="width:134px" %)**Example**|(% style="width:364px" %)(((
1107 **~ AT+VIBSET=0,4,10,12**
1108
1109 The acceleration is set to ±2g, and the frequency is 400 Hz. The threshold is set to 10 × 16 mg, meaning a change between 158 and 162 mg can be detected.
1110 )))
1111
1112 If you want to detect an event lasting at least 30 milliseconds, set the register to 30/2.5 = 12 counts. When the time difference between consecutive readings exceeds 12 duration LSBs, an interrupt will be triggered. See the figure below for specific values.
1113
1114
1115 The following screenshots are taken from data sheets of the internal sensors:
1116
1117 [[image:image-20241014154353-1.png||height="307" width="727"]]
1118
1119 [[image:image-20241014154413-2.png||height="509" width="715"]]
1120
1121
1122 (% style="color:#4f81bd" %)**Downlink Command**
1123
1124 (% border="2" style="width:500px" %)
1125 |(% style="width:156px" %)**Prefix**|(% style="width:342px" %)0x09
1126 |(% style="width:156px" %)**Parameters**|(% style="width:342px" %)(((
1127 **acceleration** : 2 bytes in hex
1128
1129 * 0: ±2g
1130 * 1: ±4g
1131 * 2: ±8g
1132 * 3: ±16g
1133
1134 **frequency** : 2 bytes in hex
1135
1136 * 0:25Hz
1137 * 1:50Hz
1138 * 2:100Hz
1139 * 3:200Hz
1140 * 4:400Hz
1141
1142 **threshold** : interrupt threshold - 2 bytes in hex
1143
1144 **duration** : Interrupt detection duration in milliseconds - 2 bytes in hex
1145 )))
1146 |(% style="width:156px" %)**Example**|(% style="width:342px" %)(((
1147 09**00040A0C**
1148
1149 The acceleration is set to ±2g, and the frequency is 400 Hz. The threshold is set to 10 × 16 mg, meaning a change between 158 and 162 mg can be detected.
1150 )))
1151
1152 == 3.4 Set Password ==
1153
1154
1155 **Feature**: Set device password, up to 9 digits
1156
1157 (% style="color:#4f81bd" %)**AT Command:**
1158
1159 (% border="2" style="width:500px" %)
1160 |(% style="width:152px" %)**Command**|(% style="width:346px" %)AT+PWORD
1161 |(% style="width:152px" %)**Parameters**|(% style="width:346px" %)**password** : any password
1162 |(% style="width:152px" %)**Get**|(% style="width:346px" %)AT+PWORD=?
1163 |(% style="width:152px" %)**Response**|(% style="width:346px" %)Returns the current password
1164 |(% style="width:152px" %)**Set**|(% style="width:346px" %)AT+PWORD=<password>
1165 |(% style="width:152px" %)**Response**|(% style="width:346px" %)OK
1166 |(% style="width:152px" %)**Example**|(% style="width:346px" %)(((
1167 * AT+PWORD=? ~/~/ show the current password, 123456 for example
1168 * AT+PWORD=999999. ~/~/ set the password to 999999
1169 )))
1170
1171 (% style="color:#4f81bd" %)**Downlink Command:**
1172
1173 There is no downlink command available for this feature.
1174
1175
1176 == 3.5 Quit AT Command ==
1177
1178
1179 **Feature**: Quit AT Command mode, so you need to input the password again before using AT Commands.
1180
1181 (% style="color:#4f81bd" %)**AT Command:**
1182
1183 (% border="2" style="width:500px" %)
1184 |(% style="width:156px" %)**Command**|(% style="width:342px" %)AT+DISAT
1185 |(% style="width:156px" %)**Parameters**|(% style="width:342px" %)none
1186 |(% style="width:156px" %)**Set**|(% style="width:342px" %)AT+DISAT
1187 |(% style="width:156px" %)**Response**|(% style="width:342px" %)OK
1188 |(% style="width:156px" %)**Example**|(% style="width:342px" %)AT+DISAT ~/~/ quit AT command mode
1189
1190 (% style="color:#4f81bd" %)**Downlink Command**
1191
1192 There is no downlink command available for this feature.
1193
1194
1195 == 3.6 Set to sleep mode ==
1196
1197
1198 **Feature**: Set device to sleep mode.
1199
1200 (% style="color:#4f81bd" %)**AT Command:**
1201
1202 (% border="2" style="width:500px" %)
1203 |(% style="width:154px" %)**Command**|(% style="width:344px" %)AT+SLEEP
1204 |(% style="width:154px" %)**Parameters**|(% style="width:344px" %)(((
1205 mode : mode
1206
1207 **0** :  Normal working mode - The device enters sleep mode and uses lower power when there are no LoRa messages.
1208
1209 **1** : Deep sleep mode -The device does not activate LoRa and is intended for storage or shipping.
1210 )))
1211 |(% style="width:154px" %)**Set**|(% style="width:344px" %)AT+SLEEP=<mode>
1212 |(% style="width:154px" %)**Response**|(% style="width:344px" %)OK
1213 |(% style="width:154px" %)**Example**|(% style="width:344px" %)(((
1214 * **AT+SLEEP=0 ~/~/ **set to normal working mode.
1215 * **AT+SLEEP=1 ~/~/ **set to Deep sleep mode.
1216 )))
1217
1218 (% style="color:#4f81bd" %)**Downlink Command**
1219
1220 There is no downlink command available for this feature.
1221
1222
1223 == 3.7 Set system time ==
1224
1225
1226 **Feature**: Set the system time.
1227
1228 (% style="color:#4f81bd" %)**AT Command:**
1229
1230 (% border="2" style="width:500px" %)
1231 |(% style="width:142px" %)**Command**|(% style="width:356px" %)AT+TIMESTAMP
1232 |(% style="width:142px" %)**Parameters**|(% style="width:356px" %)**time** : time in UNIX format. [[See here for format details.>>||anchor="H2.6.2UnixTimeStamp"]]
1233 |(% style="width:142px" %)**Set**|(% style="width:356px" %)AT+TIMESTAMP=<time>
1234 |(% style="width:142px" %)**Response**|(% style="width:356px" %)OK
1235 |(% style="width:142px" %)**Example**|(% style="width:356px" %)(((
1236 * AT+TIMESTAMP=1611104352 ~/~/ Set System time to 2021-01-20 00:59:12
1237 )))
1238
1239 (% style="color:#4f81bd" %)**Downlink Command:**
1240
1241 (% border="2" style="width:500px" %)
1242 |(% style="width:141px" %)**Prefix**|(% style="width:357px" %)0x30
1243 |(% style="width:141px" %)**Parameters**|(% style="width:357px" %)**time** : time in UNIX format. [[See here for format details.>>||anchor="H2.6.2UnixTimeStamp"]] - 5 bytes in hexadecimal
1244 |(% style="width:141px" %)**Example**|(% style="width:357px" %)(((
1245 * 30**6007806000**  ~/~/ Set System time to 2021-01-20 00:59:12
1246 )))
1247
1248 == 3.8 Set Time Sync Mode ==
1249
1250
1251 (((
1252 **Feature**: Enable/Disable system time synchronization via the LoRaWAN MAC Command (DeviceTimeReq). The LoRaWAN server must support the v1.0.3 protocol to respond to this command.
1253
1254 (% style="color:#4f81bd" %)**AT Command:**
1255
1256 (% border="2" style="width:500px" %)
1257 |(% style="width:157px" %)**Command**|(% style="width:341px" %)AT+SYNCMOD
1258 |(% style="width:157px" %)**Parameters**|(% style="width:341px" %)(((
1259 **time_sync_mode** : Enable Sync system time via LoRaWAN MAC Command (DeviceTimeReq)
1260
1261 **1** : enable (default)
1262
1263 **0** : disable
1264 )))
1265 |(% style="width:157px" %)**Set**|(% style="width:341px" %)AT+SYNCMOD=<time_sync_mode>
1266 |(% style="width:157px" %)**Example**|(% style="width:341px" %)(((
1267 * AT+SYNCMOD=0 ~/~/ Disable the time sync mode
1268 )))
1269 |(% style="width:157px" %)**Note**|(% style="width:341px" %)If you want to set a different time than the LoRaWAN server, you need to set this to 0.
1270
1271
1272 )))
1273
1274 (% style="color:#4f81bd" %)**Downlink Command:**
1275
1276 (% border="2" style="width:500px" %)
1277 |(% style="width:162px" %)**Prefix**|(% style="width:336px" %)0x28
1278 |(% style="width:162px" %)**Parameters**|(% style="width:336px" %)(((
1279 **time_sync_mode** : Enable Sync system time via LoRaWAN MAC Command (DeviceTimeReq) - 1 byte in hexadecimal
1280
1281 **1** : enable (default)
1282
1283 **0** : disable
1284 )))
1285 |(% style="width:162px" %)**Example**|(% style="width:336px" %)(((
1286 * 28** 01**  ~/~/ Enable the time sync mode
1287 * 28 **00**  ~/~/ Disable the time sync mode
1288 )))
1289
1290 == 3.9 Set Time Sync Interval ==
1291
1292
1293 **Feature**: Define system time synchronization interval. The** **default value is 10 days.
1294
1295 (% style="color:#4f81bd" %)**AT Command:**
1296
1297 (% border="2" style="width:500px" %)
1298 |(% style="width:158px" %)**Command**|(% style="width:340px" %)AT+SYNCTDC
1299 |(% style="width:158px" %)**Parameters**|(% style="width:340px" %)**sync_interval** : synchronization interval
1300 |(% style="width:158px" %)**Set**|(% style="width:340px" %)AT+SYNCTDC=<sync_interval>
1301 |(% style="width:158px" %)**Response**|(% style="width:340px" %)
1302 |(% style="width:158px" %)**Example**|(% style="width:340px" %)(((
1303 * AT+SYNCTDC=10 ~/~/ Set synchronization interval to 10
1304 )))
1305
1306 (% style="color:#4f81bd" %)**Downlink Command:**
1307
1308 (% border="2" style="width:500px" %)
1309 |(% style="width:155px" %)**Prefix**|(% style="width:343px" %)0x29
1310 |(% style="width:155px" %)**Parameters**|(% style="width:343px" %)**sync_interval** : synchronization interval - 1 byte in hexadecimal
1311 |(% style="width:155px" %)**Example**|(% style="width:343px" %)(((
1312 * 29**0A**  ~/~/ Set synchronization interval to 10
1313 )))
1314
1315 == 3.10 Get data ==
1316
1317
1318 **Feature**: Get the current sensor data.
1319
1320 (% style="color:#4f81bd" %)**AT Command:**
1321
1322 (% border="2" style="width:500px" %)
1323 |(% style="width:157px" %)**Command**|(% style="width:341px" %)AT+GETSENSORVALUE
1324 |(% style="width:157px" %)**Parameters**|(% style="width:341px" %)(((
1325 **mode** : defines data retrieve and upload behavior
1326
1327 **0** : The serial port retrieves the current sensor reading.
1328
1329 **1** : The serial port retrieves the current sensor reading and uploads it.
1330 )))
1331 |(% style="width:157px" %)**Set**|(% style="width:341px" %)AT+GETSENSORVALUE=<mode>
1332 |(% style="width:157px" %)**Response**|(% style="width:341px" %)
1333 |(% style="width:157px" %)**Example**|(% style="width:341px" %)(((
1334 * **AT+GETSENSORVALUE=0**      ~/~/ The serial port retrieves the current sensor reading.
1335 * **AT+GETSENSORVALUE=1**      ~/~/ The serial port retrieves the current sensor reading and uploads it.
1336 )))
1337
1338 (% style="color:#4f81bd" %)**Downlink Command:**
1339
1340 There is no downlink command for this feature.
1341
1342
1343 == 3.11 Print data entries base on page ==
1344
1345
1346 **Feature**: Print sensor data from start page to stop page (max is 416 pages).
1347
1348 (% style="color:#4f81bd" %)**AT Command:**
1349
1350 (% border="2" style="width:500px" %)
1351 |(% style="width:148px" %)**Command**|(% style="width:349px" %)AT+PDTA
1352 |(% style="width:148px" %)**Parameters**|(% style="width:349px" %)(((
1353 **start** : start page number
1354
1355 **end** : end page number
1356 )))
1357 |(% style="width:148px" %)**Command format**|(% style="width:349px" %)AT+PDTA=<start>,<end>
1358 |(% style="width:148px" %)**Example**|(% style="width:349px" %)(((
1359 AT+PDTA=1,3 ~/~/ Prints sensor data from page 1 to 3
1360 )))
1361 |(% style="width:148px" %)**Example response**|(% style="width:349px" %)(((
1362 Stop Tx events when read sensor data
1363
1364 8031000 2024/10/12 08:26:16 1 2807 tdc:yes alarm:false event_count:0 work_min:0
1365
1366 8031010 2024/10/12 08:26:40 1 2804 tdc:no alarm:false event_count:0 work_min:0
1367
1368 8031020 1970/1/1 00:00:10 1 2806 tdc:yes alarm:false event_count:0 work_min:0
1369
1370 8031030 2024/10/12 08:28:18 1 2805 tdc:yes alarm:false event_count:0 work_min:0
1371
1372 8031040 2024/10/12 08:29:18 1 2804 tdc:yes alarm:false event_count:0 work_min:0
1373
1374 8031050 2024/10/12 08:30:18 1 2806 tdc:yes alarm:false event_count:1 work_min:0
1375
1376 8031060 2024/10/12 08:30:27 1 2806 tdc:no alarm:true event_count:2 work_min:0
1377
1378 8031070 2024/10/12 08:31:18 1 2806 tdc:yes alarm:false event_count:3 work_min:1
1379
1380 [Rx][16:33:25.888] 8031080 2024/10/12 08:32:18 1 2806 tdc:yes alarm:false event_count:3 work_min:1
1381
1382 8031090 2024/10/12 08:33:18 1 2807 tdc:yes alarm:false event_count:3 work_min:1
1383
1384 80310A0
1385
1386 80310B0
1387
1388 80310C0
1389
1390 80310D0
1391
1392 80310E0
1393
1394 80310F0
1395
1396 8031100
1397
1398 8031110
1399
1400 8031120
1401
1402 8031130
1403
1404 8031140
1405
1406 8031150
1407
1408 8031160
1409
1410 8031170
1411
1412 Start Tx events
1413
1414 OK
1415 )))
1416
1417 (% style="color:#4f81bd" %)**Downlink Command:**
1418
1419 There is no downlink command for this feature.
1420
1421
1422 == 3.12 Print last few data entries ==
1423
1424
1425 **Feature**: Print the last few data entries.
1426
1427 (% style="color:#4f81bd" %)**AT Command:**
1428
1429 (% border="2" style="width:500px" %)
1430 |(% style="width:147px" %)**Command**|(% style="width:351px" %)AT+PLDTA
1431 |(% style="width:147px" %)**Parameters**|(% style="width:351px" %)**num_entries** : number of data entries you want to print.
1432 |(% style="width:147px" %)**Command format**|(% style="width:351px" %)AT+PLDTA=<num_entries>
1433 |(% style="width:147px" %)**Example**|(% style="width:351px" %)AT+PLDTA=5 ~/~/ Print last 5 entries
1434 |(% style="width:147px" %)**Example output**|(% style="width:351px" %)(((
1435 Stop Tx events when read sensor data
1436
1437 0001 2024/10/12 08:33:18 1 2807 tdc:yes alarm:false event_count:3 work_min:1
1438
1439 0002 2024/10/12 08:34:50 1 2808 tdc:yes alarm:false event_count:3 work_min:1
1440
1441 0003 2024/10/12 08:35:50 1 2808 tdc:yes alarm:false event_count:3 work_min:1
1442
1443 0004 2024/10/12 08:36:50 1 2809 tdc:yes alarm:false event_count:3 work_min:1
1444
1445 0005 2024/10/12 08:37:50 1 2810 tdc:yes alarm:false event_count:3 work_min:1
1446 Start Tx and RTP events
1447 OK
1448 )))
1449
1450 (% style="color:#4f81bd" %)**Downlink Command:**
1451
1452 There is no downlink command for this feature.
1453
1454
1455 == 3.13 Clear Flash Record ==
1456
1457
1458 **Feature**: Clear the flash storage used by the data log feature.
1459
1460 (% style="color:#4f81bd" %)**AT Command:**
1461
1462 (% border="2" style="width:500px" %)
1463 |(% style="width:133px" %)**Command**|(% style="width:365px" %)AT+CLRDTA
1464 |(% style="width:133px" %)**Parameters**|(% style="width:365px" %)NO
1465 |(% style="width:133px" %)**Example**|(% style="width:365px" %)AT+CLRDTA ~/~/ Clear all stored sensor data in the flash.
1466
1467 (% style="color:#4f81bd" %)**Downlink Command:**
1468
1469 (% border="2" style="width:500px" %)
1470 |(% style="width:129px" %)**Prefix**|(% style="width:369px" %)0xA3
1471 |(% style="width:129px" %)**Parameters**|(% style="width:369px" %)01 - always use 01 (hex) with the prefix
1472 |(% style="width:129px" %)**Example**|(% style="width:369px" %)A3 **01  **~/~/ Clear all stored sensor data in the flash.
1473
1474 == 3.14 Auto Send None-ACK messages ==
1475
1476
1477 **Feature**: LHT65N-VIB will wait for an ACK for each uplink. If LHT65N-VIB doesn't receive an ACK from the network server, it will assume the message didn't reach the server and store it. LHT65N-VIB continues sending messages periodically as usual. Once LHT65N-VIB receives an ACK from the network server, it will assume the network is functioning properly and start sending the messages that haven't arrived.
1478
1479 (% style="color:#4f81bd" %)**AT Command**
1480
1481 The default factory setting is 0
1482
1483 (% border="2" style="width:500px" %)
1484 |(% style="width:135px" %)**Command**|(% style="width:363px" %)AT+PNACKMD
1485 |(% style="width:135px" %)**Parameters**|(% style="width:363px" %)always 1
1486 |(% style="width:135px" %)**Command format**|(% style="width:363px" %)AT+PNACKMD=1 ~/~/ Polls non-ACK message
1487 |(% style="width:135px" %)**Response**|(% style="width:363px" %)OK
1488
1489 (% style="color:#4f81bd" %)**Downlink Command**
1490
1491 Prefix: 0x34
1492
1493 (% border="2" style="width:500px" %)
1494 |(% style="width:135px" %)**Prefix**|(% style="width:363px" %)0x34
1495 |(% style="width:135px" %)**Parameters**|(% style="width:363px" %)01 in hexadecimal
1496 |(% style="width:135px" %)**Payload format**|(% style="width:363px" %)34**01 ~/~/ **Polls non-ACK message
1497
1498 = 4. Batteries =
1499
1500 == 4.1 Battery Type ==
1501
1502
1503 (((
1504 **The LHT65N-VIB is equipped with a 2400mAh Li-MnO2 (CR17505) battery.** The battery is non-rechargeable with a low discharge rate, designed for up to 8–10 years of use. This type of battery is commonly used in IoT devices for long-term operation, such as in water meters.
1505
1506 **The discharge curve is nonlinear, so the battery level cannot be simply represented as a percentage.** Below is the battery performance:
1507 )))
1508
1509 (((
1510 [[image:image-20220515075034-1.png||_mstalt="428961" height="208" width="644"]]
1511 )))
1512
1513 The minimum working voltage for the LHT65N-VIB is approximately 2.5V. When the battery voltage drops below 2.6V, it's time to replace the battery.
1514
1515
1516 == 4.2 Replacing Batteries ==
1517
1518
1519 The LHT65N-VIB has two screws on the back. Unscrew them to remove the battery cover and replace the battery inside. The sensor uses a standard CR17450 battery, and any brand should be suitable.
1520
1521 [[image:image-20220515075440-2.png||_mstalt="429546" height="338" width="272"]][[image:image-20220515075625-3.png||_mstalt="431574" height="193" width="257"]]
1522
1523
1524 == 4.3 Battery Life Analysis ==
1525
1526
1527 (((
1528 Dragino battery-powered products all operate in Low Power mode. You can refer to the guidelines from this link to calculate the estimated battery life: [[https:~~/~~/www.dropbox.com/scl/fo/kpnidyj98435yc2kzcuol/AGMEYy8T-ToxrjBxVKiBJMw?rlkey=clgoex1idnfka8845d6e9ajue&st=m513k45l&dl=0>>https://www.dropbox.com/scl/fo/kpnidyj98435yc2kzcuol/AGMEYy8T-ToxrjBxVKiBJMw?rlkey=clgoex1idnfka8845d6e9ajue&st=m513k45l&dl=0]]
1529 )))
1530
1531 (((
1532 A detailed test report for the LHT65N-VIB on different frequencies can be found here: [[https:~~/~~/www.dropbox.com/scl/fo/wnqaiyoq21kyzrmre6kzn/ABAgXYDr03OGSrM2ODFjUJA?rlkey=jed5yinvpdd0fiqww7x7cw201&st=rdtlz5ik&dl=0>>https://www.dropbox.com/scl/fo/wnqaiyoq21kyzrmre6kzn/ABAgXYDr03OGSrM2ODFjUJA?rlkey=jed5yinvpdd0fiqww7x7cw201&st=rdtlz5ik&dl=0]]
1533 )))
1534
1535
1536 = 5. FAQ =
1537
1538 == 5.1 How to connect to LHT65N-VIB via UART interface? ==
1539
1540
1541 The LHT65N-VIB has the UART interface in its Type-C. The UART Interface can be used for
1542
1543 * Send AT Commands, and get output from LHT65N-VIB
1544 * Upgrade firmwre of LHT65N-VIB.
1545
1546 The hardware connection is: **PC <~-~-> USB to TTL Adapter <~-~-> Jump wires <~-~-> Type-C Adapter <~-~-> LHT65N-VIB**
1547
1548
1549 === 5.1.1 Options for USB to TTL adapter ===
1550
1551
1552 * CP2101 USB TTL Adapter
1553 * CH340 USB TTL Adapter
1554 * FT232 USB TTL Adapter
1555
1556 === 5.1.2 Options for Type-C adapter ===
1557
1558
1559 [[image:image-20240122103221-3.png||_mstalt="425594" height="694" width="1039"]]
1560
1561
1562 **Connection:**
1563
1564 * (% style="background-color:yellow" %)**USB to TTL GND <~-~-> LHT65N GND**
1565 * (% style="background-color:yellow" %)**USB to TTL RXD <~-~-> LHT65N TXD**
1566 * (% style="background-color:yellow" %)**USB to TTL TXD <~-~-> LHT65N RXD**
1567
1568 (((
1569
1570
1571 === 5.1.3 Connection Example ===
1572
1573
1574 [[image:1655802313617-381.png||_mstalt="293917"]]
1575
1576
1577 [[image:image-20240122092100-1.jpeg||_mstalt="467389" height="466" width="643"]]
1578
1579
1580 == 5.2 How to use AT commands? ==
1581
1582
1583 First, connect the PC and LHT65N-VIB via USB TTL adapter as described in **FAQ 6.1.**
1584
1585 On the PC, you need to set serial tool (such as **[[PuTTY>>https://www.putty.org]] **or** [[SecureCRT>>https://www.vandyke.com/products/securecrt/]]**) baud rate to **9600** to access the serial console for LHT65N-VIB. The AT commands are disabled by default, and the user needs to enter the password (default: 123456) to activate them. The timeout for inputting AT commands is 5 minutes; after 5 minutes, the user will need to input the password again. The user can use the AT+DISAT command to disable AT commands before the timeout.
1586
1587 Input the password and ATZ to activate the LHT65N-VIB, as shown below:
1588 )))
1589
1590 [[image:image-20220530095701-4.png||_mstalt="430014"]]
1591
1592
1593 === 5.2.1 AT commands ===
1594
1595
1596 The AT command list is as below:
1597
1598 **AT+<CMD>?** : Help on <CMD>
1599
1600 **AT+<CMD>** : Run <CMD>
1601
1602 **AT+<CMD>=<value>** : Set the value
1603
1604 **AT+<CMD>=?** : Get the value
1605
1606 **AT+DEBUG :** Set more info output
1607
1608 **ATZ :** Triggers a reset of the MCU
1609
1610 **AT+FDR :** Reset Parameters to Factory Default, Keys Reserve
1611
1612 **AT+DEUI** : Get or Set the Device EUI
1613
1614 **AT+DADDR** : Get or Set the Device Address
1615
1616 **AT+APPKEY** : Get or Set the Application Key
1617
1618 **AT+NWKSKEY** : Get or Set the Network Session Key
1619
1620 **AT+APPSKEY** : Get or Set the Application Session Key
1621
1622 **AT+APPEUI** : Get or Set the Application EUI
1623
1624 **AT+ADR** : Get or Set the Adaptive Data Rate setting. (0: off, 1: on)
1625
1626 **AT+TXP** : Get or Set the Transmit Power (0-5, MAX:0, MIN:5, according to LoRaWAN Spec)
1627
1628 **AT+DR **: Get or Set the Data Rate. (0-7 corresponding to DR_X)
1629
1630 **AT+DCS** : Get or Set the ETSI Duty Cycle setting - 0=disable, 1=enable - Only for testing
1631
1632 **AT+PNM** : Get or Set the public network mode. (0: off, 1: on)
1633
1634 **AT+RX2FQ** : Get or Set the Rx2 window frequency
1635
1636 **AT+RX2DR** : Get or Set the Rx2 window data rate (0-7 corresponding to DR_X)
1637
1638 **AT+RX1DL** : Get or Set the delay between the end of the Tx and the Rx Window 1 in ms
1639
1640 **AT+RX2DL** : Get or Set the delay between the end of the Tx and the Rx Window 2 in ms
1641
1642 **AT+JN1DL** : Get or Set the Join Accept Delay between the end of the Tx and the Join Rx Window 1 in ms
1643
1644 **AT+JN2DL** : Get or Set the Join Accept Delay between the end of the Tx and the Join Rx Window 2 in ms
1645
1646 **AT+NJM** : Get or Set the Network Join Mode. (0: ABP, 1: OTAA)
1647
1648 **AT+NWKID** : Get or Set the Network ID
1649
1650 **AT+FCU** : Get or Set the Frame Counter Uplink
1651
1652 **AT+FCD** : Get or Set the Frame Counter Downlink
1653
1654 **AT+CLASS **: Get or Set the Device Class
1655
1656 **AT+JOIN **: Join network
1657
1658 **AT+NJS** : Get the join status
1659
1660 **AT+SENDB** : Send hexadecimal data along with the application port
1661
1662 **AT+SEND** : Send text data along with the application port
1663
1664 **AT+RECVB** : Print last received data in binary format (with hexadecimal values)
1665
1666 **AT+RECV** : Print last received data in raw format
1667
1668 **AT+VER** : Get current image version and Frequency Band
1669
1670 **AT+CFM** : Get or Set the confirmation mode (0-1)
1671
1672 **AT+SNR** : Get the SNR of the last received packet
1673
1674 **AT+RSSI** : Get the RSSI of the last received packet
1675
1676 **AT+TDC** : Get or set the application data transmission interval in ms
1677
1678 **AT+PORT** : Get or set the application port
1679
1680 **AT+DISAT** : Disable AT commands
1681
1682 **AT+PWORD** : Set password, max 9 digits
1683
1684 **AT+CHS** : Get or Set Frequency (Unit: Hz) for Single Channel Mode
1685
1686 **AT+CHE** : Get or Set eight channels mode,Only for US915,AU915,CN470
1687
1688 **AT+PDTA** : Print the sector data from start page to stop page
1689
1690 **AT+PLDTA **: Print the last few sets of data
1691
1692 **AT+CLRDTA **: Clear the storage, record position back to 1st
1693
1694 **AT+SLEEP** : Set sleep mode
1695
1696 **AT+BAT **: Get the current battery voltage in mV
1697
1698 **AT+CFG** : Print all configurations
1699
1700 **AT+WMOD** : Get or Set Work Mode
1701
1702 **AT+ARTEMP** : Get or set the internal Temperature sensor alarm range
1703
1704 **AT+CITEMP** : Get or set the internal Temperature sensor collection interval in min
1705
1706 **AT+SETCNT** : Set the count at present
1707
1708 **AT+RJTDC** : Get or set the ReJoin data transmission interval in min
1709
1710 **AT+RPL** : Get or set response level
1711
1712 **AT+TIMESTAMP** : Get or Set UNIX timestamp in second
1713
1714 **AT+LEAPSEC** : Get or Set Leap Second
1715
1716 **AT+SYNCMOD** : Get or Set time synchronization method
1717
1718 **AT+SYNCTDC** : Get or set time synchronization interval in day
1719
1720 **AT+PID** : Get or set the PID
1721
1722
1723 == 5.3 How to use Downlink commands? ==
1724
1725
1726 The following sections shows how to send downlinks to LHT65N-VIB from various LoRaWAN network servers.
1727
1728
1729 === (% style="color:blue" %)**5.3.1 The Things Stack**(%%) ===
1730
1731
1732 The following image shows how to send downlink commands (the payloads) from The Things Stack.
1733
1734
1735 [[image:eu1.cloud.thethings.network_console_applications_dragino-docs_devices_lt-22222-l_messaging_downlink(Laptop with HiDPI screen).png]]
1736
1737
1738 === (% style="color:blue" %)**5.3.2 Helium**(%%) ===
1739
1740
1741 The following image shows how to send downlink commands (the payloads) from Helium.
1742
1743 [[image:image-20220615092551-3.png||_mstalt="430794" height="423" width="835"]]
1744
1745
1746 === (% style="color:blue" %)**5.3.3 ChirpStack**(%%) ===
1747
1748
1749 The following image shows how to send downlink commands (the payloads) from ChripStack. (% style="color:blue" %)**The downlink window will not be displayed until the network is accessed.**
1750
1751 [[image:image-20220615094850-6.png||_mstalt="433082"]]
1752
1753
1754 [[image:image-20220615094904-7.png||_mstalt="433485" height="281" width="911"]]
1755
1756
1757 The following image shows how to send downlink commands (the payloads) from AWS-IOT.
1758
1759
1760 === (% style="color:blue" %)**5.3.4 AWS-IoT**(%%) ===
1761
1762
1763 [[image:image-20220615092939-4.png||_mstalt="434460" height="448" width="894"]]
1764
1765
1766 == 5.4 How to change the uplink interval? ==
1767
1768
1769 See the **Sub section 3.1**, **Set Transmit Interval Time**.
1770
1771
1772 == 5.5 How to upgrade the firmware? ==
1773
1774
1775 You can upgrade firmware of the LHT65N-VIB to:
1776
1777 * Change the frequency band/region.
1778 * Add new features.
1779 * Fix bugs.
1780
1781 The firmware and changelog can be downloaded from : **[[Firmware download link>>https://www.dropbox.com/scl/fo/ztlw35a9xbkomu71u31im/AMz-h4yQUzAm6A7EKnQh5bc/LoRaWAN%20End%20Node/LHT65N-VIB?dl=0&rlkey=ojjcsw927eaow01dgooldq3nu&subfolder_nav_tracking=1]]**
1782
1783 **Methods to Update Firmware:**
1784
1785 * **Recommanded method**: OTA (Over-the-Air) firmware update via wireless. For instructions, visit: [[http:~~/~~/wiki.dragino.com/xwiki/bin/view/Main/Firmware%20OTA%20Update%20for%20Sensors/>>url:http://wiki.dragino.com/xwiki/bin/view/Main/Firmware%20OTA%20Update%20for%20Sensors/]]
1786 * **Alternative Method**: Update via UART TTL interface. For instructions, see: **[[Update Instruction>>url:http://wiki.dragino.com/xwiki/bin/view/Main/UART%20Access%20for%20LoRa%20ST%20v4%20base%20model/#H1.LoRaSTv4baseHardware]]**.
1787
1788 == 5.6 Why can't I see the datalog information? ==
1789
1790
1791 ~1. The time is not aligned, and the correct query command was not used.
1792
1793 2. Decoder error: the datalog data was not parsed, and the data was filtered out.
1794
1795
1796 == 5.7 How can I read sensor data without LoRaWAN? (for calibration purpose) ==
1797
1798
1799 Some clients may need to calibrate sensor values in a lab environment. In these cases, it’s more convenient to read the data without a LoRaWAN network. To do this, you can use a USB Type-C breakout board to access the UART pins while keeping the probe connected. See below for details. For the pinout, please refer to the FAQ on [[How to connect LHT65-N via UART interface>>https://www.dropbox.com/sh/una19zsni308dme/AACOKp6J2RF5TMlKWT5zU3RTa?dl=0]].
1800
1801 [[image:image-20240122092100-1.jpeg||_mstalt="467389" height="346" width="476"]]
1802
1803
1804 After the UART connection is established, run the commands below:
1805
1806 1.** AT+NJM=0      **~/~/ Set Device to ABP mode so it can work without joining the LoRaWAN network server.
1807
1808 2.** AT+GETSENSORVALUE=0      **~/~/ The serial port gets the reading from the current sensor.
1809
1810 **Example output:**
1811
1812 [[image:image-20240128093852-1.png||_mstalt="431912" height="235" width="552"]]
1813
1814
1815 = 6. Ordering Information =
1816
1817
1818 Part Number: (% style="color:#4f81bd" %)** LHT65N-VIB-XX**
1819
1820 (% style="color:#4f81bd" %)**XX **(%%): The default frequency band
1821
1822 * (% style="color:#4f81bd" %)** **(% _mstmutation="1" style="color:red" %)**AS923**(%%): LoRaWAN AS923 band
1823 * (% style="color:#4f81bd" %)** **(% _mstmutation="1" style="color:red" %)**AU915**(%%): LoRaWAN AU915 band
1824 * (% style="color:#4f81bd" %)** **(% _mstmutation="1" style="color:red" %)**EU433**(%%): LoRaWAN EU433 band
1825 * (% style="color:#4f81bd" %)** **(% _mstmutation="1" style="color:red" %)**EU868**(%%): LoRaWAN EU868 band
1826 * (% style="color:#4f81bd" %)** **(% _mstmutation="1" style="color:red" %)**KR920**(%%): LoRaWAN KR920 band
1827 * (% style="color:#4f81bd" %)** **(% _mstmutation="1" style="color:red" %)**US915**(%%): LoRaWAN US915 band
1828 * (% style="color:#4f81bd" %)** **(% _mstmutation="1" style="color:red" %)**IN865**(%%): LoRaWAN IN865 band
1829 * (% style="color:#4f81bd" %)** **(% _mstmutation="1" style="color:red" %)**CN470**(%%): LoRaWAN CN470 band
1830
1831 = 7. Packing Information =
1832
1833
1834 The package includes:
1835
1836 * LHT65N-VIB LoRaWAN Vibration Sensor x 1
1837 * External vibration probe x 1
1838
1839 = 8. Reference Materials =
1840
1841
1842 * [[Datasheet, photos, firmware>>https://www.dropbox.com/scl/fo/zfqrx88n90zofefkgug2k/AP6y5A4ZDnP3d1EUrWvRk8w?rlkey=z8qn3nx8dhjp8gy0rd7btd6it&st=sgy7v350&dl=0]]
1843
1844 = 9. FCC Warning =
1845
1846
1847 This device complies with Part 15 of the FCC Rules. Operation is subject to the following two conditions:
1848
1849 1. This device may not cause harmful interference.
1850 1. This device must accept any interference received, including interference that may cause undesired operation.
1851
1852 = 10. Use Cases =
1853
1854
1855 This section includes some example practical applications for the LHT65N-VIB.
1856
1857
1858 == 10.1 Install the LHT65N-VIB to monitor the usage of handwashing stations ==
1859
1860
1861 Device settings using AT command: AT+VIBMOD=1,120,5
1862
1863 This means that if the water faucet remains on, a vibration lasting more than 120 seconds will trigger an alarm. When the vibration stops for more than 5 seconds, the vibration count will increase by 1.
1864
1865 * The data begins to rise after 8 o'clock, indicating that the wash basin sensor is working normally.
1866 * During lunch time, from 12 noon to 1:30 PM, the data temporarily levels off but returns to normal operation after.
1867 * At 6 PM, after work hours, the data flattens out, with only a small amount recorded, caused by employees working overtime and using the wash basin.
1868
1869 [[image:image-20241101174220-2.png||height="349" width="560"]]
1870
1871
1872 * Number of wash basin alarms: 14 times
1873 * The rest period is concentrated around 12 o'clock, as people wash their hands during the lunch break.
1874 * The longer duration at 6 o'clock is due to someone needing to turn on the water to clean the toilet.
1875
1876 [[image:image-20241101175954-3.png||height="210" width="601"]]
1877
1878
1879 **Sink installation example:**
1880 Fix the probe to the water inlet pipe of the sink using a cable tie. Since the vibration in the middle is not as noticeable, and the water outlet on the right is larger than the one on the left, resulting in a larger vibration amplitude, the probe should be installed at the middle of the left water inlet pipe. This way, vibrations can be detected on both sides of the water pipe.
1881
1882 [[image:image-20241202160241-2.png]]
1883
1884
1885 == 10.2 Install the LHT65N-VIB to detect the number of times the toilet is used ==
1886
1887
1888 Device settings using AT command: AT+VIBMOD=1,120,5
1889
1890 This means that if the vibration exceeds 120 seconds, an alarm message will be issued. When the vibration stops for more than 5 seconds, the number of vibrations will increase by 1.
1891 When the toilet vibrates for only 100 seconds each time it is flushed, any vibration exceeding 120 seconds would indicate an abnormal situation.
1892
1893 * The data starts to rise after 8 o'clock, indicating that the toilet sensor is working normally.
1894 * The data remains flat with no abnormalities during the lunch break from 12:00 PM to 1:30 PM.
1895 * The data stops rising at 6:00 PM when work is over.
1896
1897 [[image:image-20241101181711-4.png||height="330" width="562"]]
1898
1899
1900 A manual alarm test is performed once at noon.
1901
1902 [[image:image-20241101182128-5.png||height="257" width="574"]]
1903
1904
1905 **Toilet installation example:**
1906 Fix the probe to the water inlet pipe of the toilet with a wire tie. When the toilet is used, it will pump water, and the LHT65N-VIB will start detecting vibrations in the water pipe. **Note:** LHT65N-VIB should not be immersed in water. If necessary, ensure it is waterproofed.
1907
1908 [[image:image-20241202160143-1.png]]
1909
1910
1911 == 10.3 VIBMOD4: Detect vibration intensity ==
1912
1913
1914 Set AT+VIBMOD=4,1,10 to collect a set of XYZ vibration data every ten seconds.
1915
1916 By analyzing the data collected in the graph, we can observe that the vibration amplitude of the machine varies significantly under different working conditions. This monitoring method not only helps to determine in real time whether the machine is operating normally but also allows for the early detection of any abnormal changes in vibration frequency. This, in turn, helps to effectively prevent potential failures and ensures the safe and stable operation of the equipment.
1917
1918 [[image:image-20241104105122-1.png||height="559" width="695"]]