LHT65N-VIB LoRaWAN Vibration Sensor Manual
Table of Contents:
- 1. Introduction
- 2. Registering LHT65N-VIB with a LoRaWAN Network Server
- 3. Configure the LHT65N-VIB via AT commands or LoRaWAN downlinks
- 3.1 Set Transmit Interval Time
- 3.2 Set Vibration Sensor Mode
- 3.3 Vibration sensitivity setting
- 3.4 Set Password
- 3.5 Quit AT Command
- 3.6 Set to sleep mode
- 3.7 Set system time
- 3.8 Set Time Sync Mode
- 3.9 Set Time Sync Interval
- 3.10 Get data
- 3.11 Print data entries base on page
- 3.12 Print last few data entries
- 3.13 Clear Flash Record
- 3.14 Auto Send None-ACK messages
- 4. Batteries
- 5. FAQ
- 6. Ordering Information
- 7. Packing Information
- 8. Reference Materials
- 9. FCC Warning
- 10. Use Cases
1. Introduction
1.1 What is the LHT65N-VIB LoRaWAN Vibration Sensor?
The Dragino LHT65N-VIB LoRaWAN Vibration Sensor is designed to 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.
It can be used in professional wireless sensor network applications, including equipment status monitoring, water leakage alarms, usage statistics, vibration intensity detection, and more.
The LHT65N-VIB 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.
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.
The LHT65N-VIB has a built-in 2400mAh non-rechargeable battery, which can last up to 3 years*.
The LHT65N-VIB is fully compatible with the LoRaWAN v1.0.3, Class A mode and can work with a standard LoRaWAN gateway.
*The actual battery life depends on how frequently data is transmitted. Please refer to the battery analyzer chapter for more details.
1.2 Features
- LoRaWAN v1.0.3, Class A mode
- Frequency Bands: CN470/EU433/KR920/US915/EU868/AS923/AU915
- Detecting object vibration status
- Detect vibration alarm
- 3-axis accelerator for x,y,z
- Calcula device runtime
- Built-in 2400mAh battery for long time use
- Built-in Temperature & Humidity sensor
- Tri-color LED to indicate working status
- Datalog feature (Max 3328 records)
- AT Commands to change parameters
- Remote configure parameters via LoRaWAN Downlink
- Firmware upgradeable via program port
1.3 Specification
Built-in Temperature Sensor:
- Resolution: 0.01 °C
- Accuracy Tolerance : Typ ±0.3 °C
- Long Term Drift: < 0.02 °C/yr
- Operating Range: -40 ~ 85 °C
Built-in Humidity Sensor:
- Resolution: 0.04 %RH
- Accuracy Tolerance : Typ ±3 %RH
- Long Term Drift: < 0.25 RH/yr
- Operating Range: 0 ~ 96 %RH
External Vibration Sensor:
- Detecting object vibration status
- accelerator for x,y,z
- Small size for easy installation
- Acceleration: ±2g,±4g,±8g;±16g
- Frequency: 25Hz,50Hz,100Hz,200Hz,400Hz
2. Registering LHT65N-VIB with a LoRaWAN Network Server
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.
2.1 How does the LHT65N-VIB work?
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.
The LHT65N-VIB's registration information can be found inside the device package.
The registration information includes the following:
- DevEUI
- AppEUI
- AppKey
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.
2.2 How to Activate LHT65N-VIB?
The LHT65N-VIB has two working modes:
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.
- 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.
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:
Usage of the ACT button | Function | Action |
---|---|---|
Pressing ACT between 1 - 3s | Test uplink status | If LHT65N-VIB is already joined to the LoRaWAN network, it will send an uplink packet. If an external sensor is connected, the Blue LED will blink once. If there is no external sensor, the Red LED will blink once. |
Pressing ACT for more than 3s | Activate Device | The Green LED will blink quickly 5 times, indicating that the LHT65N-VIB is entering working mode and starting to join the LoRaWAN network. The Green LED will solid for 5 seconds after successfully joining the network. |
Fast press ACT 5 times. | Deactivate Device | The Red LED will remain solid for 5 seconds, indicating that the LHT65N-VIB is in Deep Sleep Mode. |
2.3 Registering with The Things Stack
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 LoRaWAN gateway.
The typical end-to-end network setup with LHT65N-VIB and LPS8v2 is shown below:
2.3.1 Add LHT65N-VIB to The Things Stack
- From the LoRaWAN device repository
- Manually
3.2.2.1 Creating an application
Sign up for a free account with The Things Stack Sandbox if you do not have one yet. Then, create an application as shown in the screenshots below.
3.2.2.2 Adding using the LoRaWAN device repository
You can refer to the screenshots below to register your LHT65N-VIB using The Things Stack's LoRaWAN device repository.
3.2.2.3 Adding manually
You can refer to the screenshots below to register your LHT65N-VIB using The Things Stack's manual option.
1. Create
Add APP EUI and DEV EUI
Add APP EUI in the application
Add APP KEY
2.3.2 Activate the LHT65N-VIB by pressing and holding the ACT button for more than 5 seconds.
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.
2.3.3 Uplink Decoder in The Things Stack
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.
The LHT65N-VIB decoder can be downloaded from here: https://github.com/dragino/dragino-end-node-decoder
The uplink decoder can be added to the Uplink Payload Formatters of your device in The Things Stack. Refer to the screenshot below.
2.4 Uplink Payload (FPort=2)
The uplink payload is a total of 11 bytes. Uplink packets use FPort=2 and, by default, are sent every 20 minutes.
After each uplink, the BLUE LED blinks once.
There are four different working modes:
- VIBMOD=1 vibration count, work_min
- VIBMOD=2 TempC_SHT, Hum_SHT, vib_count
- VIBMOD=3 TempC_SHT, Hum_SHT, vib_min
- VIBMOD=4 X, Y, Z
2.4.1 VIBMOD=1
VIBMOD=1 represent the battery voltage, working mode, alarm status, TDC, vibration count, and work_min.
Size(bytes) | 2 | 1 | 4 | 4 |
---|---|---|---|---|
Value | BAT | MOD Alarm TDC | vib_count | work_min |
The following subsections describe each field:
2.4.1.1 BAT (Battery Voltage)
These two bytes represent the battery voltage. See the image below.
Calculate the battery voltage for the LHT65N-VIB, if the BAT=0B F2.
Convert 0x0BF2 to decimal (3058) and then divide by 1000 to get the voltage.
- 0x0BF2 (hex) = 3058 (dec)
- 3058/1000 = 3.058 V
2.4.1.2 MOD, Alarm, and TDC
This byte represent working mode, alarm status, and TCD. See the image below.
bytes[2]=0x06=0000 0110
Current working mode:
- (bytes[2]>>2)&0x07
- Shift two bits to right (0000 0110 -> 0000 0001)
- Then bitwise AND with 0x07 (0000 0001 & 0000 0111 = 0000 0001 = 1)
Current alarm status:
- (bytes[2] & 0x01)? "TRUE":"FALSE"
- 0000 0110 & 0000 0001 = 0000 0000 = 0 = FALSE
Is the current data triggered by TDC (data uploaded due to alarm)?
- (bytes[2] & 0x02)? "YES":"NO"
- 0000 0110 & 0000 0010 = 0000 0010 = 2 (NON-ZERO VALUE) = YES
2.4.1.3 vib_count
These 4 bytes (vib_count) represent the number of vibration events that has been recorded. See the image below.
- 0x00000007=7
2.4.1.4 work_min
These 4 bytes (work_min) indicate the duration the current vibration sensor has been active since the latest trigger. See the image below.
- 0x00000000=0
0 means that the current vibration sensor is not triggered.
2.4.2 VIBMOD=2
VIBMOD=2 represent the battery voltage, working mode, alarm status, TDC, vibration count, TempC_SHT, and Hum_SHT.
Size(bytes) | 2 | 1 | 4 | 2 | 2 |
---|---|---|---|---|---|
Value | BAT | MOD Alarm TDC | vib_count | TempC_SHT | Hum_SHT |
2.4.2.1 BAT (Battery Voltage)
These two bytes represent the battery voltage. See the image below.
Calculate the battery voltage for LHT65N-VIB.
- 0x0BC6/1000=3.014V
2.4.2.2 VIBMOD, Alarm and TDC
This byte represent working mode, alarm status, and TCD. See the image below.
bytes[2]=0x0A=0000 0101
Current working mode=(bytes[2]>>2)&0x07=2
Current alarm situation= (bytes[2] & 0x01)? "TRUE":"FALSE";=0=FALSE
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
2.4.2.3 vib_count
These 4 bytes represent the number of vibration events that has been recorded. See the image below.
- 0x00000000=0
2.4.2.4 TempC_SHT
These 2 bytes represent the temperature measured by the built-in temperature & humidity sensor, SHT31.
- 0x0B22/100=28.5 C
2.4.2.5 Hum_SHT
These 2 bytes represent the humidity measured by the built-in temperature & humidity sensor, SHT31.
- 0x0212/10=53
2.4.3 VIBMOD=3
VIBMOD=3 represents the battery voltage, working mode, alarm status, TDC, TempC_SHT, Hum_SHT, and work_min.
Size(bytes) | 2 | 1 | 2 | 2 | 4 |
---|---|---|---|---|---|
Value | BAT | MOD Alarm TDC | TempC_SHT | Hum_SHT | work_min |
2.4.3.1 BAT (Battery Voltage)
These 2 bytes represent the battery voltage.
- 0x0BC2/1000=3.01V
2.4.3.2 VIBMOD and Alarm and TDC
This byte represents the working mode, alarm status, and TDC.
bytes[2]=0x0A=0000 1110
Current working mode=(bytes[2]>>2)&0x07=3
Current alarm situation= (bytes[2] & 0x01)? "TRUE":"FALSE";=0=FALSE
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
2.4.3.3 TempC_SHT
These 2 bytes represent the temperature measured by the built-in temperature & humidity sensor, SHT31.
- 0x0B21/100=28.49 C
2.4.3.4 Hum_SHT
These 2 bytes represent the humidity measured by the built-in temperature & humidity sensor, SHT31.
- 0x0213/10=53.1
2.4.3.5 work_min
These 4 bytes (work_min) indicate the duration the current vibration sensor has been active since the latest trigger. See the image below.
- 0x00000000=0
0 means that the current vibration sensor is not triggered.
2.4.4 VIBMOD=4 (FPort=7)
VIBMOD=4 represents the battery voltage and the accelerometer data.
Size(bytes) | 2 | 2 | 2 | 2 | 2 |
---|---|---|---|---|---|
Value | BAT | X | Y | Z | ...... |
The first two bytes represent the battery voltage, for example 0A F3.
The reset of the bytes represents the accelerometer data on axis X, Y, and Z. Each axis represent in 2 bytes.
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.
Y=0x0014=20
Z=0x00F6=246
2.5 Integrating with IoT platforms
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.
2.5.1 Integrate and show data on ThingsEye
[will be added soon]
2.5.2 Integrate and show data on Datacake
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.
- Ensure that your device is programmed and properly connected to The Things Stack.
- Configure your application to forward data to DataCake by adding an integration.
- In The Things Stack console, navigate to Applications → <your application> → Integrations → Webhooks → + Add webhook.
- In the Choose webhook template page, select Datacake.
Add Datacake:
- In the Setup webhook for Datacake page, enter the Webhook ID and Token as shown below. Then select the Create Datacake webhook button.
In the Datacake console (https://datacake.co/) , add LHT65N-VIB as follows.
2.8 LED Indicator
The LHT65 has a tri-color LED for easily indicating different stages.
When the user presses the ACT button, the LED will function according to the LED status linked to the ACT button.
In a normal working state:
- For each uplink, the BLUE or RED LED will blink once:
- BLUE LED: Indicates an external sensor is connected.
- RED LED: Indicates no external sensor is connected.
- For each successful downlink, the PURPLE LED will blink once.
2.9 Installation
The LHT65N should be installed vertically on objects, with the sensor parallel to the object's surface.
3. Configure the LHT65N-VIB via AT commands or LoRaWAN downlinks
You can configure the LHT65N-VIB via AT commands or LoRaWAN Downlinks.
Configure via AT Commands: See the FAQ for instructions on How to connect to the LHT65N-VIB's UART interface
LoRaWAN downlink instructions for different platforms: Refer to the IoT LoRaWAN Server
There are two kinds of commands to configure the LHT65N-VIB:
1. General Commands.
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.
These commands can be used to configure:
- General system settings, such as uplink interval.
- LoRaWAN protocol and radio-related settings.
2. Commands design specially for the LHT65N-VIB
These commands are only valid for the LHT65N-VIB and are listed below:
3.1 Set Transmit Interval Time
Feature: Change the LHT65N-VIB's uplink transmission Interval.
AT Command: AT+TDC
Command Example | Function | Response |
AT+TDC=? | Show the current uplink transmission Interval | 30000 OK The interval is 30000ms = 30s |
AT+TDC=60000 | Set the transmission interval | OK Set transmission interval to 60000ms = 60 seconds |
Downlink Command: 0x01
Format: Prefix (0x01) followed by a 3 byte time value.
If the downlink payload is 0100003C, it means set the end node's transmit interval is set to 0x00003C=60(s), where the type code is 01.
- Example 1: Downlink Payload: 0100001E // Set Transmit Interval (TDC) to = 30 seconds
- Example 2: Downlink Payload: 0100003C // Set Transmit Interval (TDC) to = 60 seconds
3.2 Set Vibration Sensor Mode
Feature: Sets the Vibration Sensor Mode.
AT Command: AT+VIBMOD
Command Example | Function | Response |
AT+VIBMOD=MOD, AlarmTime, StopDurationTime | MOD: 1, 2, 3 AlarmTime: Sets the duration of continuous operation required to trigger the alarm (unit: seconds). (Set AlarmTimeout to 0 to disable alarm) StopDurationTime: Specifies the interval time after which the event is counted as a trigger. | OK |
AT+VIBMOD=4,CollectionInterval,Groups | 4: MOD=4 CollectionInterval: Collection Interval (unit: seconds) Groups: Number of collection groups | OK |
Example 1: AT+VIBMOD=1,60,10
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.
If vibration stops for more than 10 seconds, vib_count increases by one, and work_min resets to zero.
Example 2: AT+VIBMOD=4,1,10
MOD4 sets the collection interval to 10 seconds and collects 1 sets of data in total.
Downlink Command: 0x0A
Format: Prefix (0x0A) followed by a 5 bytes.
Example 1:
- AT+VIBMOD=1,60,10 = 0x0A01003C000A
Example 2:
- AT+VIBMOD=4,1,10 = 0x0A0400010A
3.3 Vibration sensitivity setting
Feature: Allows adjustment of sensitivity settings for different usage scenarios.
AT Command:
Command Example | Function | Response |
AT+VIBSET=Acceleration,Frequency,Threshold, Duration | Acceleration:
Frequency:
Threshold: interrupt threshold Duration: Interrupt detection duration (unit ms) | OK |
Example: AT+VIBSET=0,4,10,12
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.
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.
Downlink Command:
The format of the downlink command is as follows:
- Prefix: 0x09
- Acceleration: 2 bytes in hex
- Frequency: 2 bytes in hex
- Threshold: 2 bytes in hex
- Duration: 2 bytes in hex
The equivalent downlink command for the AT+VIBSET=0,4,10,12 is shown below:
0x0900040A0C
3.4 Set Password
Feature: Set device password, up to 9 digits
AT Command: AT+PWORD
Command Example | Function | Response |
AT+PWORD=? | Show password | 123456 OK |
AT+PWORD=999999 | Set password | OK |
Downlink Command:
There is no downlink command available for this feature.
3.5 Quit AT Command
Feature: Quit AT Command mode, so you need to input the password again before using AT Commands.
AT Command: AT+DISAT
Command Example | Function | Response |
AT+DISAT | Quit AT Command mode | OK |
Downlink Command:
There is no downlink command available for this feature.
3.6 Set to sleep mode
Feature: Set device to sleep mode
- AT+SLEEP=0 : Normal working mode. The device will sleep and use lower power when there is no LoRa message.
- AT+SLEEP=1 : Device is in deep sleep mode. No LoRa activation occurs, and it is used for storage or shipping.
AT Command: AT+SLEEP
Command Example | Function | Response |
AT+SLEEP | Set to sleep mode | Clear all stored sensor data… OK |
Downlink Command:
- There is no downlink command available for this feature.
3.7 Set system time
Feature: Set the system time in UNIX format. See here for format detail.
AT Command:
Command Example | Function |
AT+TIMESTAMP=1611104352 | OK Set System time to 2021-01-20 00:59:12 |
Downlink Command:
Prefix : 0x30
Time : 5 bytes in hexadecimal
Example:
0x306007806000 // Set timestamp to 0x(6007806000),Same as AT+TIMESTAMP=1611104352
3.8 Set Time Sync Mode
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.
AT Command:
Command Example | Function |
AT+SYNCMOD=1 | Enable Sync system time via LoRaWAN MAC Command (DeviceTimeReq) SYNCMOD is set to 1 by default. If you want to set a different time than the LoRaWAN server, you need to set this to 0. |
Downlink Command:
Prefix : 0x28
Example:
0x28 01 // Same As AT+SYNCMOD=1
0x28 00 // Same As AT+SYNCMOD=0
3.9 Set Time Sync Interval
Feature: Define system time synchronization interval. The default value is 10 days.
AT Command:
Command Example | Function |
AT+SYNCTDC=0x0A | Set SYNCTDC to 10 (0x0A), which means the synchronization interval is 10 days. |
Downlink Command:
Prefix: 0x29
Example:
0x29 0A // Same as AT+SYNCTDC=0x0A
3.10 Get data
Feature: Get the current sensor data.
AT Command:
- AT+GETSENSORVALUE=0 // The serial port retrieves the current sensor reading.
- AT+GETSENSORVALUE=1 // The serial port retrieves the current sensor reading and uploads it.
3.11 Print data entries base on page
Feature: Print sector data from start page to stop page (max is 416 pages).
AT Command: AT+PDTA
Command Example | Function |
AT+PDTA=1,3 | Stop Tx events when read sensor data 8031000 2024/10/12 08:26:16 1 2807 tdc:yes alarm:false event_count:0 work_min:0 8031010 2024/10/12 08:26:40 1 2804 tdc:no alarm:false event_count:0 work_min:0 8031020 1970/1/1 00:00:10 1 2806 tdc:yes alarm:false event_count:0 work_min:0 8031030 2024/10/12 08:28:18 1 2805 tdc:yes alarm:false event_count:0 work_min:0 8031040 2024/10/12 08:29:18 1 2804 tdc:yes alarm:false event_count:0 work_min:0 8031050 2024/10/12 08:30:18 1 2806 tdc:yes alarm:false event_count:1 work_min:0 8031060 2024/10/12 08:30:27 1 2806 tdc:no alarm:true event_count:2 work_min:0 8031070 2024/10/12 08:31:18 1 2806 tdc:yes alarm:false event_count:3 work_min:1 [Rx][16:33:25.888] 8031080 2024/10/12 08:32:18 1 2806 tdc:yes alarm:false event_count:3 work_min:1 8031090 2024/10/12 08:33:18 1 2807 tdc:yes alarm:false event_count:3 work_min:1 80310A0 80310B0 80310C0 80310D0 80310E0 80310F0 8031100 8031110 8031120 8031130 8031140 8031150 8031160 8031170 Start Tx events OK |
Downlink Command:
There is no downlink command for this feature.
3.12 Print last few data entries
Feature: Print the last few data entries
AT Command: AT+PLDTA
Command Example | Function |
AT+PLDTA=5 | Stop Tx events when read sensor data 0001 2024/10/12 08:33:18 1 2807 tdc:yes alarm:false event_count:3 work_min:1 0002 2024/10/12 08:34:50 1 2808 tdc:yes alarm:false event_count:3 work_min:1 0003 2024/10/12 08:35:50 1 2808 tdc:yes alarm:false event_count:3 work_min:1 0004 2024/10/12 08:36:50 1 2809 tdc:yes alarm:false event_count:3 work_min:1 0005 2024/10/12 08:37:50 1 2810 tdc:yes alarm:false event_count:3 work_min:1 |
Downlink Command:
There is no downlink command for this feature.
3.13 Clear Flash Record
Feature: Clear the flash storage used by the data log feature.
AT Command: AT+CLRDTA
Command Example | Function | Response |
AT+CLRDTA | Clear date record | Clear all stored sensor data… OK |
Downlink Command:
Prefix: 0xA3
Example:
0xA301 // Same as AT+CLRDTA
3.14 Auto Send None-ACK messages
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.
AT Command: AT+PNACKMD
The default factory setting is 0
Command Example | Function | Response |
---|---|---|
AT+PNACKMD=1 | Poll None-ACK message | OK |
Downlink Command: 0x34
Prefix: 0x34
Example:
0x3401 // Same as AT+PNACKMD=1
4. Batteries
4.1 Battery Type
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.
The discharge curve is nonlinear, so the battery level cannot be simply represented as a percentage. Below is the battery performance:
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.
4.2 Replacing Batteries
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.
4.3 Battery Life Analysis
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
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
5. FAQ
5.1 How to connect to LHT65N-VIB via UART interface?
The LHT65N-VIB has the UART interface in its Type-C. The UART Interface can be used for
- Send AT Commands, and get output from LHT65N-VIB
- Upgrade firmwre of LHT65N-VIB.
The hardware connection is: PC <--> USB to TTL Adapter <--> Jump wires <--> Type-C Adapter <--> LHT65N-VIB
5.1.1 Options for USB to TTL adapter
- CP2101 USB TTL Adapter
- CH340 USB TTL Adapter
- FT232 USB TTL Adapter
5.1.2 Options for Type-C adapter
Connection:
- USB to TTL GND <--> LHT65N GND
- USB to TTL RXD <--> LHT65N TXD
- USB to TTL TXD <--> LHT65N RXD
5.1.3 Connection Example
5.2 How to use AT commands?
First, connect the PC and LHT65N-VIB via USB TTL adapter as described in FAQ 6.1.
On the PC, you need to set serial tool (such as PuTTY or 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.
Input the password and ATZ to activate the LHT65N-VIB, as shown below:
5.2.1 AT commands
The AT command list is as below:
AT+<CMD>? : Help on <CMD>
AT+<CMD> : Run <CMD>
AT+<CMD>=<value> : Set the value
AT+<CMD>=? : Get the value
AT+DEBUG: Set more info output
ATZ: Triggers a reset of the MCU
AT+FDR: Reset Parameters to Factory Default, Keys Reserve
AT+DEUI: Get or Set the Device EUI
AT+DADDR: Get or Set the Device Address
AT+APPKEY: Get or Set the Application Key
AT+NWKSKEY: Get or Set the Network Session Key
AT+APPSKEY: Get or Set the Application Session Key
AT+APPEUI: Get or Set the Application EUI
AT+ADR: Get or Set the Adaptive Data Rate setting. (0: off, 1: on)
AT+TXP: Get or Set the Transmit Power (0-5, MAX:0, MIN:5, according to LoRaWAN Spec)
AT+DR: Get or Set the Data Rate. (0-7 corresponding to DR_X)
AT+DCS: Get or Set the ETSI Duty Cycle setting - 0=disable, 1=enable - Only for testing
AT+PNM: Get or Set the public network mode. (0: off, 1: on)
AT+RX2FQ: Get or Set the Rx2 window frequency
AT+RX2DR: Get or Set the Rx2 window data rate (0-7 corresponding to DR_X)
AT+RX1DL: Get or Set the delay between the end of the Tx and the Rx Window 1 in ms
AT+RX2DL: Get or Set the delay between the end of the Tx and the Rx Window 2 in ms
AT+JN1DL: Get or Set the Join Accept Delay between the end of the Tx and the Join Rx Window 1 in ms
AT+JN2DL: Get or Set the Join Accept Delay between the end of the Tx and the Join Rx Window 2 in ms
AT+NJM: Get or Set the Network Join Mode. (0: ABP, 1: OTAA)
AT+NWKID: Get or Set the Network ID
AT+FCU: Get or Set the Frame Counter Uplink
AT+FCD: Get or Set the Frame Counter Downlink
AT+CLASS: Get or Set the Device Class
AT+JOIN: Join network
AT+NJS: Get the join status
AT+SENDB: Send hexadecimal data along with the application port
AT+SEND: Send text data along with the application port
AT+RECVB: Print last received data in binary format (with hexadecimal values)
AT+RECV: Print last received data in raw format
AT+VER: Get current image version and Frequency Band
AT+CFM: Get or Set the confirmation mode (0-1)
AT+SNR: Get the SNR of the last received packet
AT+RSSI: Get the RSSI of the last received packet
AT+TDC: Get or set the application data transmission interval in ms
AT+PORT: Get or set the application port
AT+DISAT: Disable AT commands
AT+PWORD: Set password, max 9 digits
AT+CHS: Get or Set Frequency (Unit: Hz) for Single Channel Mode
AT+CHE: Get or Set eight channels mode,Only for US915,AU915,CN470
AT+PDTA: Print the sector data from start page to stop page
AT+PLDTA: Print the last few sets of data
AT+CLRDTA: Clear the storage, record position back to 1st
AT+SLEEP: Set sleep mode
AT+BAT: Get the current battery voltage in mV
AT+CFG: Print all configurations
AT+WMOD: Get or Set Work Mode
AT+ARTEMP: Get or set the internal Temperature sensor alarm range
AT+CITEMP: Get or set the internal Temperature sensor collection interval in min
AT+SETCNT: Set the count at present
AT+RJTDC: Get or set the ReJoin data transmission interval in min
AT+RPL: Get or set response level
AT+TIMESTAMP: Get or Set UNIX timestamp in second
AT+LEAPSEC: Get or Set Leap Second
AT+SYNCMOD: Get or Set time synchronization method
AT+SYNCTDC: Get or set time synchronization interval in day
AT+PID: Get or set the PID
5.3 How to use Downlink commands?
The following image shows how to send downlink commands (the payloads) from The Things Stack.
5.3.1 The Things Stack
The following image shows how to send downlink commands (the payloads) from Helium.
5.3.2 Helium
5.3.3 ChirpStack
The following image shows how to send downlink commands (the payloads) from ChripStack. The downlink window will not be displayed until the network is accessed.
The following image shows how to send downlink commands (the payloads) from AWS-IOT.
5.3.4 AWS-IoT
5.4 How to change the uplink interval?
Please see this link: http://wiki.dragino.com/xwiki/bin/view/Main/How%20to%20set%20the%20transmit%20time%20interval/
5.5 How to upgrade the firmware?
You can change firmware LHT65N-VIB to:
- Change the frequency band/region.
- Add new features.
- Fix bugs.
The firmware and changelog can be downloaded from : Firmware download link
Methods to Update Firmware:
- 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/
- Alternative Method: Update via UART TTL interface. For instructions, see: Update Instruction.
5.6 Why can't I see the datalog information
1. The time is not aligned, and the correct query command was not used.
2. Decoder error: the datalog data was not parsed, and the data was filtered out.
5.7 How can I read sensor data without LoRaWAN? (For Calibration Purpose)
Some clients need to calibrate the sensor values in a calibration lab. In such cases, reading the data without a LoRaWAN network is more convenient. To achieve this, you can use a USB Type-C breakout board to expose the UART pins while still 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.
After the UART connection is established, run the commands below:
1. AT+NJM=0 // Set Device to ABP mode , so can works without join to LoRaWAN server.
2. AT+GETSENSORVALUE=0 // The serial port gets the reading of the current sensor.
Example output:
6. Ordering Information
Part Number: LHT65N-VIB-XX
XX : The default frequency band
- AS923: LoRaWAN AS923 band
- AU915: LoRaWAN AU915 band
- EU433: LoRaWAN EU433 band
- EU868: LoRaWAN EU868 band
- KR920: LoRaWAN KR920 band
- US915: LoRaWAN US915 band
- IN865: LoRaWAN IN865 band
- CN470: LoRaWAN CN470 band
7. Packing Information
The Package Includes:
- LHT65N-VIB LoRaWAN Vibration Sensor x 1
8. Reference Materials
9. FCC Warning
This device complies with Part 15 of the FCC Rules. Operation is subject to the following two conditions:
- This device may not cause harmful interference.
- This device must accept any interference received, including interference that may cause undesired operation.
10. Use Cases
Examples of Practical Applications for LHT65N-VIB.
10.1 Install LHT65N-VIB to detect the number of uses of handwashing stations
Device settings vis AT command: AT+VIBMOD=1,120,5
This means that when 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.
- The data begins to rise after 8 o'clock, indicating that the wash basin sensor is working normally.
- During lunch time, from 12 noon to 1:30 PM, the data temporarily levels off but returns to normal operation after.
- 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.
- Number of wash basin alarms: 14 times
- The rest period is concentrated around 12 o'clock, as people wash their hands during the lunch break.
- The longer duration at 6 o'clock is due to someone needing to turn on the water to clean the toilet.
Sink installation example:
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.
10.2 Install LHT65N-VIB to detect the number of times the toilet is used
Device settings vis AT command: AT+VIBMOD=1,120,5
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.
When the toilet vibrates for only 100 seconds each time it is flushed, any vibration exceeding 120 seconds would indicate an abnormal situation.
- The data starts to rise after 8 o'clock, indicating that the toilet sensor is working normally.
- The data remains flat with no abnormalities during the lunch break from 12:00 PM to 1:30 PM.
- The data stops rising at 6:00 PM when work is over.
A manual alarm test is performed once at noon.
Toilet installation example:
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.
10.3 VIBMOD4 detect vibration intensity
Set AT+VIBMOD=4,1,10 to collect a set of XYZ vibration data every ten seconds.
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.