Dragino LDS02 - LoRaWAN Door Sensor User Manual

Document Version: 1.3

Image Version: v1.3

Version Description Date
1.0 Release 2021-May-16
1.1 Add more Battery Description 2021-Jul-1
1.3 Update LDS02 photo for with new version 2022-Jan-8

1. Introduction

1.1 What is LDS02 LoRaWAN Door Sensor

The Dragino LDS02 is a LoRaWAN Door Sensor. It detects door open/close status and uplinks to an IoT server via the LoRaWAN network. Users can view the door status, open time, and open counts on the IoT Server.

The LDS02 is powered by 2 x AAA batteries and is designed for long-term use. These batteries can provide approximately 16,000 to 70,000 uplink packets. When the batteries run low, users can easily open the enclosure and replace them with common AAA batteries.

The LDS02 sends data periodically every day, as well as for each door open/close action. It also counts the door open times and calculates the last door open duration. Users can disable the uplink for each open/close event, allowing the device to count each open event and uplink periodically.

The LDS02 features an open alarm. Users can configure this feature to send an Alarm if the door has been open for a certain time.

Each LDS02 comes pre-loaded with a set of unique keys for LoRaWAN registration. Register these keys to the LoRaWAN server, and the device will automatically connect after power-on.

LDS02 in a LoRaWAN Network

A diagram shows the LDS02 Door Sensor connected via LoRaWAN to an LG308 LoRaWAN Gateway, which connects to the Internet and then to a LoRaWAN Server.

1.2 Features

1.3 Applications

1.4 Dimension

Unit: mm

Diagram showing the dimensions of the LDS02: 73.90mm length, 29.2mm width, 14.8mm height. Another view shows 8.80mm height and a diameter of 3.20mm.

1.5 Firmware Change log

LDS02 uses the same firmware as LDS01. LDS02 Image files – Download link

2. Power ON LDS02

When you receive the LDS02, open the enclosure and add 2 x AAA batteries to power it. The LED will blink when the device is powered.

3. How to install LDS02

When installing the LDS02 on a wall, ensure it is mounted as shown below so that the marks align when the door is closed.

Open/Close threshold range: ~ 25mm

Diagram showing the two parts of the LDS02 sensor. One part is mounted on the door frame, and the other on the door itself. Arrows indicate that when the two parts are close, the door is closed, and when they are far apart, the door is open.

4. Operation Mode

4.1 How it works?

The LDS02 is configured as LoRaWAN OTAA Class A mode by default. It uses OTAA keys to join the network. To connect to a local LoRaWAN network, users need to input the OTAA keys into the network server and power on the LDS02. It will automatically join the network via OTAA.

If a user cannot set the OTAA keys in the network server and needs to use existing keys from the server, they can use AT Command to set the keys in the devices.

4.2 Example to join LoRaWAN network

This section provides an example of joining the TTN V3 Network. The network structure uses the LG308 as the LoRaWAN gateway.

Diagram illustrating the network setup: LDS02 Door Sensor connected via LoRaWAN to an LG308 LoRaWAN Gateway, which connects to the Internet and then to The Things Network (TTN) LoRaWAN server.

The LDS02, when installed on the door edge, detects the open/close event and sends the status to the LoRaWAN server. The LDS02 will uplink two types of messages to the server:

The LG308 is already configured to connect to the TTN V3 network. The next step is to configure TTN V3.

Step 1: Create a device in TTN V3 with the OTAA keys from LDS02.

Each LDS02 is shipped with a sticker containing unique device EUI, App EUI, and App Key.

A sticker is shown with details: DEV ADDR, DEV EUI, APP EUI, APP KEY, APPSKEY, NETSKEY, and SN.

Users can enter these keys in their LoRaWAN Server portal. The TTN V3 screenshot shows how to add an application and its details.

Add application

After creating the application, users can add end devices. The screen shows a list of applications and their details, including end devices.

Register end device

Users can register an end device either from the LoRaWAN Device Repository or manually.

1. Select the end device

Users select the Brand (Dragino Technology Co.,...) and Model (LDS02). If the exact device is not found, there's an option to search. A dropdown list shows available models like LDDS20, LDDS75, LDS01, LGT92, LHT65, LSE01, LSN50-V2.

2. Enter registration data

Users need to select the Frequency plan and enter the AppEUI and AppKey.

A screenshot shows the TTN V3 interface for registering an end device, including fields for Brand, Model, Hardware Ver., Firmware Ver., Profile (Region), Frequency plan, AppEUI, DevEUI, and AppKey.

Add APP KEY and DEV EUI

Users enter the Frequency plan (e.g., Europe 863-870 MHz), AppEUI, DevEUI, and AppKey.

End device ID: my-new-device

Step 2: Power on LDS02 and it will auto join to the TTN V3 network. After join success, it will start to upload messages to TTN V3 and users can see them in the panel.

A screenshot shows the TTN V3 Live Data panel, displaying uplink messages with details like DevAddr, MAC payload, FPort, SNR, RSSI, and the decoded payload content (e.g., BAT V, DOOR OPEN STATUS, DOOR OPEN TIMES, LAST DOOR OPEN DURATION).

4.3 Uplink Payload

Uplink Payload total 10 bytes.

Size(bytes) Value
2 Status&BAT 1 MOD 3 Total open door events 3 Last door open duration (unit: min) 1 Alarm
Always:0x01

Example: Example Payload Decoder in TTN V3

4.4 Downlink Payload

Downlink Control Type Type Code Downlink payload size(bytes)
TDC (Transmit Time Interval-Keep Alive Interval) 0x01 4
RESET 0x04 2
Set confirmed mode 0x05 2
Clear Counting 0xA6 2
Enable/Disable Alarm 0xA7 2
Control ADR/DR 0xA8 3
Set Alarm Timeout 0xA9 4

Example Downlink payload setting in TTN V3:

Users can schedule a downlink message by selecting the Insert Mode (Replace downlink queue or Push to downlink queue), setting the FPort, and entering the Payload. A 'Confirmed downlink' button is available.

Type Code 0x01: Controls the LDS02's Keep Alive interval. Example: 0100003C sets the interval to 60 seconds.

Type Code 0x04: Resets the LDS02. Example: 0x04FF.

Type Code 0x05: Sets uplink mode. 0x05 00 for unconfirmed mode, 0x05 01 for confirmed mode.

Type Code 0xA6: Clears counting. Example: 0xA601.

Type Code 0xA7: Controls alarm status. 0xA7 01 enables AT+DISALARM=1, 0xA7 00 disables it (AT+DISALARM=0).

Type Code 0xA8: Controls ADR/DR. Format: 0xA8 aa bb. 'aa' enables/disables ADR, 'bb' sets the DR. Example: 0x A8 00 02 sets ADR=0 and DR=1.

Type Code 0xA9: See Alarm Base Timeout for detail.

4.5 Integrate with Datacake

Datacake provides a user-friendly interface to display sensor data. After receiving data in TTN V3, users can connect Datacake to TTN V3 to view the data.

Steps:

  1. Ensure the device is programmed and connected to the network.
  2. To configure the Application to forward data to Datacake, add an integration.

A screenshot shows the TTN V3 Integrations page, where users can choose various webhook templates, including Datacake.

Add custom webhook

Users configure the webhook with a Webhook ID and a Datacake API Token.

Step 3: Create an account or log in Datacake.

Step 4: Search LDS02 and add DevEUI.

A screenshot of the Datacake dashboard shows device information, including Battery Voltage, Door Status, Last Door Open Duration, and Statistical Trend.

4.6 Alarm Base on Timeout

The LDS02 can monitor the timeout for a status change, useful for events like a fridge being left open too long.

User configuration via AT Command:

Downlink Command to configure:

Command: 0xA9 aa bb cc

Example: 0xA9 01 00 1E is equivalent to AT+TTRIG=1,30.

Example: 0xA9 00 00 00 is equivalent to AT+TTRIG=0,0, disabling the timeout Alarm.

4.7 LEDs

Action LED behavior
Power On GREEN on 1s, RED on 1s, BLUE on 1s
Joined successful GREEN LED on 5s
Send an uplink message GREEN LED blinks once
Got a downlink message BLUE LED blinks once

5. Battery & How to replace

5.1 Battery Type and replace

The LDS02 is equipped with 2 x AAA LR03 batteries. If the batteries are running low (indicated as 2.1v in the platform), users can buy generic AAA batteries and replace them.

Note:

  1. The LDS02 does not have screws; use a nail to open it from the middle.
  2. Ensure correct battery orientation when installing.

Important Notice: Make sure to use new AAA LR03 batteries and that the batteries do not have a broken surface.

Example of AAA LR03 battery: A diagram shows a AAA battery with dimensions and branding.

5.2 Battery Life Analyze

Dragino battery-powered products operate in Low Power mode. Users can refer to the following guideline to estimate battery life: DRAGINO Battery Life Guide.

6. Use AT Command

6.1 Access AT Command

The LDS02 supports an AT Command set. Users can use a USB to TTL adapter to configure the LDS02 via AT commands.

USB to TTL Connections:

A diagram shows the pinout of the LDS02 board, indicating TXD, RXD, GND, VDD, CLK, SNLULS, DIO, and SOO pins.

In a PC, users need to set the serial tool (such as PuTTY, SecureCRT) baud rate to 115200 to access the serial console of the LDS02. The AT Access password is 123456.

A screenshot of a serial port utility shows the connection settings and a log of the device's activity, including joining the network and sending uplink messages.

Each AT Command requires an ENTER key press at the end before sending.

When entering the first command, the RED LED will turn on, and users can input AT Commands. After inputting all necessary AT Commands, enter AT+CLPM=1 to set the device to Low Power mode, and the RED LED will turn off.

More details on AT Commands can be found in the AT Command Manual.

7. FAQ

7.1 How to upgrade the image?

Users can upgrade the firmware of the LDS02 for bug fixes, new features, or to change the working region. The upgrade instructions are available here: http://wiki.dragino.com/index.php?title=Firmware_Upgrade_Instruction

7.2 How to change the LoRa Frequency Bands/Region?

If a user has, for example, US915 frequency and wants to change it to AS923 frequency, they can follow the instructions for upgrading the image. When downloading the images, select the required image file for download.

7.3 Can I disable uplink for each event to save battery life?

Yes, users can use the following methods:

Via AT Command:

Via LoRaWAN downlink Command:

8. Order Info

Part Number: LDS02-XXX

XXX indicates the frequency bands:

9. Packing Info

Package Includes:

Dimension and weight:

10. Support

Support is provided Monday to Friday, from 09:00 to 18:00 GMT+8. Due to different timezones, live support cannot be offered. However, questions will be answered as soon as possible within the mentioned schedule.

Provide as much information as possible regarding your inquiry (product models, accurately describe your problem, and steps to replicate it, etc.) and send an email to support@dragino.com.

Models: LDS02, LoRaWAN Door Sensor

File Info : application/pdf, 22 Pages, 763.46KB

LDS02 LoRaWAN Door Sensor UserManual v1.3

References

Microsoft Word 2019

Related Documents

Preview Dragino LDS02 LoRaWAN Door Sensor User Manual
User manual for the Dragino LDS02 LoRaWAN Door Sensor, detailing its features, installation, operation, LoRaWAN network integration, data payloads, AT commands, battery management, and support.
Preview Dragino LPS8 LoRaWAN Gateway User Manual
A comprehensive user manual for the Dragino LPS8 LoRaWAN Gateway, covering setup, configuration, network integration, and troubleshooting.
Preview Dragino LA66 USB Adapter V2 User Manual - LoRaWAN Connectivity
Comprehensive user manual for the Dragino LA66 USB Adapter V2, detailing its features, specifications, LoRaWAN connectivity, setup examples, and troubleshooting for IoT applications.
Preview Dragino LPS8v2 LoRaWAN Indoor Gateway Datasheet
Datasheet for the Dragino LPS8v2, an open-source LoRaWAN indoor gateway. Details its features, specifications, and ordering information for bridging LoRa wireless networks to IP networks.
Preview Dragino LIG16 LoRaWAN Gateway User Manual
Comprehensive user manual for the Dragino LIG16 Indoor LoRaWAN Gateway, detailing its features, specifications, network setup, configuration, and troubleshooting for IoT deployments.
Preview LPS8v2 LoRaWAN Indoor Gateway Benutzerhandbuch
Dieses Benutzerhandbuch bietet detaillierte Informationen zum Dragino LPS8v2 LoRaWAN Indoor Gateway, einschließlich Einrichtung, Konfiguration, Funktionen und Fehlerbehebung für Systemintegratoren und IoT-Enthusiasten.
Preview Dragino LT Series LoRa IO Controller User Manual
This user manual provides comprehensive information on the Dragino LT Series LoRa IO Controller, including specifications, features, operation modes, AT commands, and troubleshooting.
Preview Dragino PB01 LoRaWAN Push Button User Manual: Features, Setup, and Operation
This user manual provides comprehensive details on the Dragino PB01 LoRaWAN Push Button, covering its features, specifications, activation, LoRaWAN network integration, uplink payload formats, configuration via AT commands, battery replacement, and firmware updates.