Dragino SDI-12-LB User manual

(
/xwiki/bin/view/Main/
)
/
Home
(
/xwiki/bin/view/Main/
)
/
User Manual for LoRaWAN End Nodes
(
/xwiki/bin/view
/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/
)
/
SDI-12-LB -- SDI-12 to LoRaWAN Converter User Manual
(
/xwiki/bin/view
/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SDI-12-LB%20--%20SDI-
12%20to%20LoRaWAN%20Converter%20User%20Manual/
)
SDI-12-LB -- SDI-12 to LoRaWAN
Converter User Manual
Last modified by
Xiaoling
(
/xwiki/bin/view/XWiki/Xiaoling
)
on 2023/02/24 09:16

Table of Contents
:
•
1. Introduction
◦
1.1 What is SDI-12 to LoRaWAN Converter
◦
1.2 Features
◦
1.3 Specification
◦
1.4 Connect to SDI-12 Sensor
◦
1.5 Sleep mode and working mode
◦
1.6 Button & LEDs
◦
1.7 Pin Mapping
◦
1.8 BLE connection
◦
1.9 Mechanical
•
2. Configure SDI-12 to connect to LoRaWAN network
◦
2.1 How it works

◦
2.2 Quick guide to connect to LoRaWAN server (OTAA)
◦
2.3 SDI-12 Related Commands
▪
2.3.1 Basic SDI-12 debug command
▪
al!!-- Get SDI-12 sensor Identification
▪
aM!,aMC!, aM1!- aM9!, aMC1!- aMC9!
▪
aC!, aCC!,!aC1!- aC9!,!aCC1!- aCC9!!
▪
aR0!- aR9!,!aRC0!- aRC9!
▪
2.3.2!Advance SDI-12 Debug command
▪
2.3.3 Convert ASCII to String
▪
2.3.4 Define periodically SDI-12 commands and uplink.
◦
2.4!Uplink Payload
▪
2.4.1 Device Payload, FPORT=5
▪
2.4.2 Uplink Payload, FPORT=2
▪
2.4.3 Battery Info
▪
2.4.4 Interrupt Pin
▪
2.4.5 Payload version
▪
2.4.6 Decode payload in The Things Network
◦
2.5 Uplink Interval
◦
2.6 Examples To Set SDI commands.
▪
2.6.1 Examples 1
◦
2.7 Frequency Plans
◦
2.8 Firmware Change Log
•
3. Configure SDI-12-LB via AT Command or LoRaWAN Downlink
◦
3.1!Set Transmit Interval Time
◦
3.2 Set Interrupt Mode
◦
3.3 Set the output time
◦
3.4 Set the all data mode
◦
3.5 Set the splicing payload for uplink
◦
3.6 Set the payload version
•
4. Battery & how to replace
◦
4.1 Battery Type
◦
4.2 Replace Battery
◦
4.3 Power Consumption Analyze
▪
4.3.1 Battery Note
▪
4.3.2 Replace the battery
•
5. Remote Configure device
◦
5.1 Connect via BLE
◦
5.2 AT Command Set
•
6. OTA firmware update
•
7. FAQ
◦
7.1 How to use AT Command to access device?
◦
7.2 How to update firmware via UART port?
◦
7.3 How to change the LoRa Frequency Bands/Region?
•
8. Order Info
•
9. Packing Info

•
10. Support
1. Introduction
1.1 What is SDI-12 to LoRaWAN Converter
The Dragino
SDI-12-LB
is a
SDI-12 to LoRaWAN Converter!
designed for Smart Agriculture solution.
SDI-12 (Serial Digital Interface at 1200 baud) is an asynchronous
serial communications
(
https://en.wikipedia.org/wiki/Serial_communication
)
protocol for intelligent sensors that monitor
environment data. SDI-12 protocol is widely used in Agriculture sensor and Weather Station sensors.
SDI-12-LB has SDI-12 interface and support 12v output to power external SDI-12 sensor. It can get the
environment data from SDI-12 sensor and sends out the data via LoRaWAN wireless protocol.
The LoRa wireless technology used in SDI-12-LB allows device to send data and reach extremely long
ranges at low data-rates. It provides ultra-long range spread spectrum communication and high
interference immunity whilst minimizing current consumption.
SDI-12-LB is powered by
8500mAh Li-SOCI2 battery
, it is designed for long term use up to 5 years.
Each SDI-12-LB is pre-load with a set of unique keys for LoRaWAN registrations, register these keys to
local LoRaWAN server and it will auto connect after power on.

1.2 Features
•
LoRaWAN 1.0.3 Class A
•
Ultra-low power consumption
•
Controllable 3.3v, 5v and 12v output to power external sensor
•
SDI-12 Protocol to connect to SDI-12 Sensor
•
Monitor Battery Level
•
Bands: CN470/EU433/KR920/US915/EU868/AS923/AU915/IN865
•
Support Bluetooth v5.1 and LoRaWAN remote configure.
•
Support wireless OTA update firmware
•
Uplink on periodically
•
Downlink to change configure
•
8500mAh Battery for long term use
1.3 Specification
Micro Controller:
•
MCU: 48Mhz ARM
•
Flash: 256KB
•
RAM: 64KB
Common DC Characteristics:
•
Supply Voltage: 2.5v ~ 3.6v
•
Operating Temperature: -40 ~ 85°C
LoRa Spec:
•
Frequency Range,!Band 1 (HF): 862 ~ 1020 Mhz
•
Max +22 dBm constant RF output vs.
•
RX sensitivity: down to -139 dBm.
•
Excellent blocking immunity
Current Input Measuring :
•
Range: 0 ~ 20mA
•
Accuracy: 0.02mA
•
Resolution: 0.001mA
Voltage Input Measuring:
•
Range: 0 ~ 30v
•
Accuracy: 0.02v
•
Resolution: 0.001v
Battery:

•
Li/SOCI2 un-chargeable battery
•
Capacity: 8500mAh
•
Self-Discharge: <1% / Year @ 25°C
•
Max continuously current: 130mA
•
Max boost current: 2A, 1 second
Power Consumption
•
Sleep Mode: 5uA @ 3.3v
•
LoRa Transmit Mode: 125mA @ 20dBm, 82mA @ 14dBm
1.4 Connect to SDI-12 Sensor

1.5 Sleep mode and working mode
Deep Sleep Mode:!
Sensor doesn't have any LoRaWAN activate. This mode is used for storage and
shipping to save battery life.
Working Mode:!
In this mode, Sensor will work as LoRaWAN Sensor to Join LoRaWAN network and send
out sensor data to server. Between each sampling/tx/rx periodically, sensor will be in IDLE mode), in IDLE
mode, sensor has the same power consumption as Deep Sleep mode.
1.6 Button & LEDs
Behavior on ACT
Function
Action

Pressing ACT between
1s < time < 3s
Send an uplink
If sensor is already Joined to
LoRaWAN network, sensor will
send an uplink packet,
blue
led
will blink once.
Meanwhile, BLE module will be
active and user can connect via
BLE to configure device.
Pressing ACT for more
than 3s
Active Device
Green led
will fast blink 5 times,
device will enter
OTA mode
for 3
seconds. And then start to JOIN
LoRaWAN network.
Green led
will solidly turn on for 5
seconds after joined in network.
Once sensor is active, BLE
module will be active and user can
connect via BLE to configure
device, no matter if device join or
not join LoRaWAN network.
Fast press ACT 5 times.
Deactivate
Device
Red led
will solid on for 5
seconds. Means SDI-12-LB is in
Deep Sleep Mode.
1.7 Pin Mapping

1.8 BLE connection
SDI-12-LB support BLE remote configure.
BLE can be used to configure the parameter of sensor or see the console output from sensor. BLE will be
only activate on below case:
•
Press button to send an uplink
•
Press button to active device.
•
Device Power on or reset.
If there is no activity connection on BLE in 60 seconds, sensor will shut down BLE module to enter low
power mode.
1.9 Mechanical

2. Configure SDI-12 to connect to LoRaWAN
network
2.1 How it works
The SDI-12-LB is configured as
LoRaWAN OTAA Class A
mode by default. It has OTAA keys to join
LoRaWAN network. To connect a local LoRaWAN network, you need to input the OTAA keys in the
LoRaWAN IoT server and activate the SDI-12-LB. It will automatically join the network via OTAA and start
to send the sensor value. The default uplink interval is 20 minutes.

2.2 Quick guide to connect to LoRaWAN server (OTAA)
Following is an example for how to join the
TTN v3 LoRaWAN Network
(
https://console.cloud.thethings.network/
)
. Below is the network structure; we use the
LPS8v2
(
https://www.dragino.com/products/lora-lorawan-gateway/item/228-lps8v2.html
)
!as a LoRaWAN
gateway in this example.!
The LPS8V2 is already set to connected to
TTN network!
(
https://console.cloud.thethings.network/
)
, so
what we need to now is configure the TTN server.
Step 1
: Create a device in TTN with the OTAA keys from SDI-12-LB.
Each SDI-12-LB is shipped with a sticker with the default device EUI as below:
You can enter this key in the LoRaWAN Server portal. Below is TTN screen shot:

Register the device
Add APP EUI and DEV EUI

Add APP EUI in the application

Add APP KEY

Step 2
: Activate on SDI-12-LB
Press the button for 5 seconds to activate the SDI-12-LB.
Green led
will fast blink 5 times, device will enter
OTA mode
!
for 3 seconds. And then start to JOIN
LoRaWAN network.
Green led
will solidly turn on for 5 seconds after joined in network.
2.3 SDI-12 Related Commands
User need to configure SDI-12-LB to communicate with SDI-12 sensors otherwise the uplink payload will
only include a few bytes.

2.3.1 Basic SDI-12 debug command
User can run some basic SDI-12 command to debug the connection to the SDI-12 sensor. These
commands can be sent via AT Command or LoRaWAN downlink command.
If SDI-12 sensor return value after get these commands,
SDI-12-LB
will uplink the return on FPORT=100,
otherwise, if there is no response from SDI-12 sensor.
SDI-12-LB
will uplink NULL (0x 4E 55 4C 4C) to
server.
The following is the display information on the serial port and the server.
al!!-- Get SDI-12 sensor Identification
•
AT Command: !AT+ADDRI=aa
•
LoRaWAN Downlink(prefix 0xAA00): !AA 00 aa
Parameter:!!
aa: ASCII value of SDI-12 sensor address in downlink or HEX value in AT Command)
Example :!!!
AT+ADDRI=0 !( Equal to downlink: 0x AA 00 30)
The following is the display information on the serial port and the server.

aM!,aMC!, aM1!- aM9!, aMC1!- aMC9!
aM!!
: Start Non-Concurrent Measurement
aMC!!
: Start Non-Concurrent Measurement – Request CRC
aM1!- aM9!!
: Additional Measurements
aMC1!- aMC9!
: Additional Measurements – Request CRC
•
AT Command : AT+ADDRM=0,1,0,1!
•
LoRaWAN Downlink(prefix 0xAA01): 0xAA 01 30 01 00 01
Downlink
:
AA 01 aa bb cc dd
aa
: SDI-12 sensor address.
bb
: 0: no CRC, 1: request CRC
cc
: 1-9: Additional Measurement, 0: no additional measurement
dd
: delay (in second) to send
aD0!
to get return.
The following is the display information on the serial port and the server.

aC!, aCC!,!aC1!- aC9!,!aCC1!- aCC9!!
aC!
: Start Concurrent Measurement
aCC!
!
: Start Concurrent Measurement – Request CRC
aC1!- aC9!
: Start Additional Concurrent Measurements
aCC1!- aCC9!
: Start Additional Concurrent Measurements – Request CRC
•
AT Command : AT+ADDRC=0,1,0,1!!
•
LoRaWAN Downlink(0xAA02): 0xAA 02 30 01 00 01
Downlink: AA 02 aa bb cc dd!
aa
: SDI-12 sensor address.
bb
: 0: no CRC, 1: request CRC
cc
: 1-9: Additional Measurement, 0: no additional measurement
dd
: delay (in second) to send
aD0!
!
to get return.

The following is the display information on the serial port and the server.
aR0!- aR9!,!aRC0!- aRC9!
Start Continuous Measurement
Start Continuous Measurement – Request CRC
•
AT Command : AT+ADDRR=0,1,0,1!!
•
LoRaWAN Downlink (0xAA 03): 0xAA 03 30 01 00 01
Downlink: AA 03 aa bb cc dd!
aa
: SDI-12 sensor address.
bb
: 0: no CRC, 1: request CRC
cc
: 1-9: Additional Measurement, 0: no additional measurement
dd
: delay (in second) to send
aD0!
to get return.
The following is the display information on the serial port and the server.

2.3.2!Advance SDI-12 Debug command
This command can be used to debug all SDI-12 command.
LoRaWAN Downlink: A8 aa xx xx xx xx bb cc
aa!
: total SDI-12 command length
xx!
: SDI-12 command
bb!
: Delay to wait for return
cc!
: 0: don't uplink return to LoRaWAN, 1: Uplink return to LoRaWAN on FPORT=100
Example:!
AT+CFGDEV =0RC0!,1
0RC0!!
: SDI-12 Command,
1!
: Delay 1 second.!( 0: 810 mini-second)
Equal Downlink: 0xA8 05 30 52 43 30 21 01 01
The following is the display information on the serial port and the server.
Table of contents
Other Dragino Media Converter manuals