Wiki source code of SDI-12-CB -- SDI-12 to NB-IoT/LTE-M Converter User Manual
Last modified by Mengting Qiu on 2025/02/26 17:50
Show last authors
author | version | line-number | content |
---|---|---|---|
1 | |||
2 | |||
3 | (% style="text-align:center" %) | ||
4 | [[image:image-20231020174533-1.png||height="561" width="443"]] | ||
5 | |||
6 | |||
7 | |||
8 | |||
9 | |||
10 | |||
11 | **Table of Contents:** | ||
12 | |||
13 | {{toc/}} | ||
14 | |||
15 | |||
16 | |||
17 | |||
18 | |||
19 | |||
20 | = 1. Introduction = | ||
21 | |||
22 | == 1.1 What is SDI-12 to NB-IoT/LTE-M Converter == | ||
23 | |||
24 | |||
25 | The Dragino (% style="color:blue" %)**SDI-12-CB**(%%) is a (% style="color:blue" %)**SDI-12 to NB-IoT/LYE-M Converter **(%%)designed for Smart Agriculture solution. | ||
26 | |||
27 | SDI-12 (Serial Digital Interface at 1200 baud) is an asynchronous [[serial communications>>url: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. | ||
28 | |||
29 | SDI-12-CB 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 NB-IoT/CAT-M1 wireless protocol. | ||
30 | |||
31 | SDI-12-CB supports different uplink methods including (% style="color:blue" %)**MQTT, MQTTs, UDP, TCP or CoAP**(%%) for different application requirement, and support uplinks to various IoT Servers. | ||
32 | |||
33 | SDI-12-CB (% style="color:blue" %)**supports BLE configure **(%%)and(% style="color:blue" %)** OTA update**(%%) which make user easy to use. | ||
34 | |||
35 | SDI-12-CB is powered by (% style="color:blue" %)**8500mAh Li-SOCI2 battery**(%%), it is designed for long-term use up to several years. | ||
36 | |||
37 | SDI-12-CB has optional built-in SIM card and default IoT server connection version. Which makes it works with simple configuration. | ||
38 | |||
39 | |||
40 | == 1.2 Features == | ||
41 | |||
42 | |||
43 | * For -NB Bands: B1/B2/B3/B4/B5/B8/B12/B13/B17/B18/B19/B20/B25/B28/B66/B70/B85 | ||
44 | * For -CB Bands: B1/B2/B3/B4/B5/B8/B12/B13~/~/B18/B19/B20/B25/B28/B66/B71/B85 | ||
45 | * CAT-M1 / LTE-M Bands: B1/B2/B3/B4/B5/B8/B12/B13/B18/B19/B20/B25/B26/B27/B28/B66/B85 | ||
46 | * Ultra-low power consumption | ||
47 | * Controllable 3.3v, 5v and 12v output to power external sensor | ||
48 | * SDI-12 Protocol to connect to SDI-12 Sensor | ||
49 | * Multiply Sampling and one uplink | ||
50 | * GNSS for Location Report | ||
51 | * Support Bluetooth v5.1 remote configure and update firmware | ||
52 | * Uplink on periodically | ||
53 | * Downlink to change configure | ||
54 | * 8500mAh Battery for long term use | ||
55 | * Uplink via MQTT, MQTTs, TCP, UDP or CoAP | ||
56 | * Nano SIM card slot for NB-IoT SIM | ||
57 | |||
58 | == 1.3 Specification == | ||
59 | |||
60 | |||
61 | (% style="color:blue" %)**Common DC Characteristics:** | ||
62 | |||
63 | * Supply Voltage: 2.6v ~~ 3.6v | ||
64 | * Support current: 5V 300mA, 12V 100mA | ||
65 | * Operating Temperature: -40 ~~ 85°C | ||
66 | |||
67 | (% style="color:blue" %)**Current Input (DC) Measuring :** | ||
68 | |||
69 | * Range: 0 ~~ 20mA | ||
70 | * Accuracy: 0.02mA | ||
71 | * Resolution: 0.001mA | ||
72 | |||
73 | (% style="color:blue" %)**Voltage Input Measuring:** | ||
74 | |||
75 | * Range: 0 ~~ 30v | ||
76 | * Accuracy: 0.02v | ||
77 | * Resolution: 0.001v | ||
78 | |||
79 | (% style="color:blue" %)**NB-IoT Spec:** | ||
80 | |||
81 | (% style="color:#037691" %)**NB-IoT Module: BG95-NGFF** | ||
82 | |||
83 | (% style="color:#037691" %)**Support Bands:** | ||
84 | |||
85 | * B1 @H-FDD: 2100MHz | ||
86 | * B2 @H-FDD: 1900MHz | ||
87 | * B3 @H-FDD: 1800MHz | ||
88 | * B4 @H-FDD: 2100MHz | ||
89 | * B5 @H-FDD: 860MHz | ||
90 | * B8 @H-FDD: 900MHz | ||
91 | * B12 @H-FDD: 720MHz | ||
92 | * B13 @H-FDD: 740MHz | ||
93 | * B17 @H-FDD: 730MHz | ||
94 | * B18 @H-FDD: 870MHz | ||
95 | * B19 @H-FDD: 870MHz | ||
96 | * B20 @H-FDD: 790MHz | ||
97 | * B25 @H-FDD: 1900MHz | ||
98 | * B28 @H-FDD: 750MHz | ||
99 | * B66 @H-FDD: 2000MHz | ||
100 | * B70 @H-FDD: 2000MHz | ||
101 | * B85 @H-FDD: 700MHz | ||
102 | |||
103 | (% style="color:blue" %)**Battery:** | ||
104 | |||
105 | * Li/SOCI2 un-chargeable battery | ||
106 | * Capacity: 8500mAh | ||
107 | * Self Discharge: <1% / Year @ 25°C | ||
108 | * Max continuously current: 130mA | ||
109 | * Max boost current: 2A, 1 second | ||
110 | |||
111 | (% style="color:blue" %)**Power Consumption** | ||
112 | |||
113 | * STOP Mode: 10uA @ 3.3v | ||
114 | * Max transmit power: 350mA@3.3v | ||
115 | |||
116 | == 1.4 Connect to SDI-12 Sensor == | ||
117 | |||
118 | |||
119 | [[image:image-20240729163908-2.png]] | ||
120 | |||
121 | |||
122 | == 1.5 Sleep mode and working mode == | ||
123 | |||
124 | |||
125 | (% style="color:blue" %)**Deep Sleep Mode: **(%%)Sensor doesn't have any NB-IoT activate. This mode is used for storage and shipping to save battery life. | ||
126 | |||
127 | (% style="color:blue" %)**Working Mode:** (%%)In this mode, Sensor will work as NB-IoT Sensor to Join NB-IoT 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. | ||
128 | |||
129 | |||
130 | == 1.6 Button & LEDs == | ||
131 | |||
132 | |||
133 | [[image:Main.User Manual for LoRaWAN End Nodes.D20-LBD22-LBD23-LB_LoRaWAN_Temperature_Sensor_User_Manual.WebHome@1675071855856-879.png]] | ||
134 | |||
135 | |||
136 | (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:510px" %) | ||
137 | |=(% style="width: 167px;background-color:#4F81BD;color:white" %)**Behavior on ACT**|=(% style="width: 117px;background-color:#4F81BD;color:white" %)**Function**|=(% style="width:226px;background-color:#4F81BD;color:white" %)**Action** | ||
138 | |(% style="width:167px" %)Pressing ACT between 1s < time < 3s|(% style="width:117px" %)Send an uplink|(% style="width:225px" %)((( | ||
139 | If sensor has already attached to NB-IoT network, sensor will send an uplink packet, (% style="color:blue" %)**blue led** (%%)will blink once. | ||
140 | Meanwhile, BLE module will be active and user can connect via BLE to configure device. | ||
141 | ))) | ||
142 | |(% style="width:167px" %)Pressing ACT for more than 3s|(% style="width:117px" %)Active Device|(% style="width:225px" %)((( | ||
143 | (% style="color:green" %)**Green led**(%%) will fast blink 5 times, device will enter (% style="color:#037691" %)**OTA mode**(%%) for 3 seconds. And then start to attach NB-IoT network. | ||
144 | (% style="color:green" %)**Green led**(%%) will solidly turn on for 5 seconds after joined in network. | ||
145 | Once sensor is active, BLE module will be active and user can connect via BLE to configure device, no matter if device attach NB-IoT network or not. | ||
146 | ))) | ||
147 | |(% style="width:167px" %)Fast press ACT 5 times.|(% style="width:117px" %)Deactivate Device|(% style="width:225px" %)(% style="color:red" %)**Red led**(%%) will solid on for 5 seconds. Means device is in Deep Sleep Mode. | ||
148 | |||
149 | (% style="color:red" %)**Note: When the device is executing a program, the buttons may become invalid. It is best to press the buttons after the device has completed the program execution.** | ||
150 | |||
151 | |||
152 | == 1.7 BLE connection == | ||
153 | |||
154 | |||
155 | SDI-12-CB support BLE remote configure and firmware update. | ||
156 | |||
157 | |||
158 | 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: | ||
159 | |||
160 | * Press button to send an uplink | ||
161 | * Press button to active device. | ||
162 | * Device Power on or reset. | ||
163 | |||
164 | If there is no activity connection on BLE in 60 seconds, sensor will shut down BLE module to enter low power mode. | ||
165 | |||
166 | |||
167 | == 1.8 Pin Definitions , Switch & SIM Direction == | ||
168 | |||
169 | |||
170 | SDI-12-CB use the mother board which as below. | ||
171 | |||
172 | [[image:image-20240729163436-1.jpeg||height="461" width="700"]] | ||
173 | |||
174 | |||
175 | === 1.8.1 Jumper JP2 === | ||
176 | |||
177 | |||
178 | Power on Device when put this jumper. | ||
179 | |||
180 | |||
181 | === 1.8.2 BOOT MODE / SW1 === | ||
182 | |||
183 | |||
184 | **1)** (% style="color:blue" %)**ISP**(%%): upgrade mode, device won't have any signal in this mode. but ready for upgrade firmware. LED won't work. Firmware won't run. | ||
185 | |||
186 | **2)** (% style="color:blue" %)**Flash**(%%): work mode, device starts to work and send out console output for further debug | ||
187 | |||
188 | |||
189 | === 1.8.3 Reset Button === | ||
190 | |||
191 | |||
192 | Press to reboot the device. | ||
193 | |||
194 | |||
195 | === 1.8.4 SIM Card Direction === | ||
196 | |||
197 | |||
198 | See this link. [[How to insert SIM Card>>url:http://wiki.dragino.com/xwiki/bin/view/Main/General%20Configure%20to%20Connect%20to%20IoT%20server%20for%20-NB%20%26%20-NS%20NB-IoT%20models/#H2.AttachNetwork]]. | ||
199 | |||
200 | |||
201 | == 1.9 Mechanical == | ||
202 | |||
203 | |||
204 | [[image:image-20250224110733-4.png]] | ||
205 | |||
206 | |||
207 | = 2. Use SDI-12-CB to communicate with IoT Server = | ||
208 | |||
209 | == 2.1 Send data to IoT server via NB-IoT/CAT-M1 network == | ||
210 | |||
211 | |||
212 | The SDI-12-CB is equipped with a NB-IoT module, the pre-loaded firmware in SDI-12-CB will get environment data from sensors and send the value to local NB-IoT network via the NB-IoT module. The NB-IoT network will forward this value to IoT server via the protocol defined by SDI-12-CB. | ||
213 | |||
214 | |||
215 | Below shows the network structure: | ||
216 | |||
217 | [[image:image-20240731115407-1.png]] | ||
218 | |||
219 | |||
220 | There are two version: (% style="color:blue" %)**-GE**(%%) and (% style="color:blue" %)**-1T**(%%) version of SDI-12-CB. | ||
221 | |||
222 | |||
223 | (% style="color:blue" %)**GE Version**(%%): This version doesn't include SIM card or point to any IoT server. User needs to use AT Commands to configure below two steps to set SDI-12-CB send data to IoT server. | ||
224 | |||
225 | * Install NB-IoT SIM card and configure APN. See instruction of [[Attach Network>>url:http://wiki.dragino.com/xwiki/bin/view/Main/General%20Configure%20to%20Connect%20to%20IoT%20server%20for%20-NB%20%26%20-NS%20NB-IoT%20models/#H2.AttachNetwork]]. | ||
226 | |||
227 | * Set up sensor to point to IoT Server. See instruction of [[Configure to Connect Different Servers>>url:http://wiki.dragino.com/xwiki/bin/view/Main/General%20Configure%20to%20Connect%20to%20IoT%20server%20for%20-NB%20%26%20-NS%20NB-IoT%20models/#H3.Configuretoconnecttodifferentservers]]. | ||
228 | |||
229 | Below shows result of different server as a glance. | ||
230 | |||
231 | (% border="1" cellspacing="3" style="width:515px" %) | ||
232 | |(% style="background-color:#4f81bd; color:white; width:100px" %)**Servers**|(% style="background-color:#4f81bd; color:white; width:300px" %)**Dash Board**|(% style="background-color:#4f81bd; color:white; width:115px" %)**Comments** | ||
233 | |(% style="width:127px" %)[[Node-Red>>url:http://wiki.dragino.com/xwiki/bin/view/Main/General%20Configure%20to%20Connect%20to%20IoT%20server%20for%20-NB%20%26%20-NS%20NB-IoT%20models/#H3.5A0Node-RedA028viaA0MQTT29]]|(% style="width:385px" %)((( | ||
234 | (% style="text-align:center" %) | ||
235 | [[image:image-20230819113244-8.png||height="183" width="367"]] | ||
236 | )))|(% style="width:170px" %) | ||
237 | |[[ThingSpeak>>url:http://wiki.dragino.com/xwiki/bin/view/Main/General%20Configure%20to%20Connect%20to%20IoT%20server%20for%20-NB%20%26%20-NS%20NB-IoT%20models/#H3.3A0ThingSpeakA028viaA0MQTT29]]|((( | ||
238 | [[image:https://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/S31-CBS31B-CB--NB-IoTLTE-M_Temperature%26Humidity_Sensor_User_Manual/WebHome/image-20230819113244-10.png?width=367&height=104&rev=1.1||alt="image-20230819113244-10.png" height="104" width="367"]] | ||
239 | )))| | ||
240 | |[[ThingsBoard>>url:http://wiki.dragino.com/xwiki/bin/view/Main/General%20Configure%20to%20Connect%20to%20IoT%20server%20for%20-NB%20%26%20-NS%20NB-IoT%20models/#H3.6A0ThingsBoard.CloudA028viaA0MQTT29]]|((( | ||
241 | [[image:https://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/S31-CBS31B-CB--NB-IoTLTE-M_Temperature%26Humidity_Sensor_User_Manual/WebHome/image-20230819113244-11.png?width=367&height=141&rev=1.1||alt="image-20230819113244-11.png" height="141" width="367"]] | ||
242 | )))| | ||
243 | |(% style="width:127px" %)[[Tago.IO>>url:http://wiki.dragino.com/xwiki/bin/view/Main/General%20Configure%20to%20Connect%20to%20IoT%20server%20for%20-NB%20%26%20-NS%20NB-IoT%20models/#H3.7A0Tago.ioA028viaA0MQTT29]]|(% style="width:385px" %) |(% style="width:170px" %) | ||
244 | |(% style="width:127px" %)[[General UDP>>url:http://wiki.dragino.com/xwiki/bin/view/Main/General%20Configure%20to%20Connect%20to%20IoT%20server%20for%20-NB%20%26%20-NS%20NB-IoT%20models/#H3.1GeneralA0UDPA0Connection]]|(% style="width:385px" %)Raw Payload. Need Developer to design Dash Board|(% style="width:170px" %) | ||
245 | |(% style="width:127px" %)[[General MQTT>>url:http://wiki.dragino.com/xwiki/bin/view/Main/General%20Configure%20to%20Connect%20to%20IoT%20server%20for%20-NB%20%26%20-NS%20NB-IoT%20models/#H3.2GeneralA0MQTTA0Connection]]|(% style="width:385px" %)Raw Payload. Need Developer to design Dash Board|(% style="width:170px" %) | ||
246 | |||
247 | (% style="color:blue" %)**1T Version**(%%): This version has 1NCE SIM card pre-installed and configure to send value to ThingsEye. User Just need to select the sensor type in ThingsEyeand Activate SDI-12-CB and user will be able to see data in ThingsEye. See here for [[ThingsEye Config Instruction>>url:https://wiki.thingseye.io/xwiki/bin/view/Main/]]. | ||
248 | |||
249 | |||
250 | == 2.2 Payload Types == | ||
251 | |||
252 | |||
253 | To meet different server requirement, SDI-12-CB supports different payload type. | ||
254 | |||
255 | **Includes:** | ||
256 | |||
257 | * [[General JSON format payload>>||anchor="H2.2.1GeneralJsonFormat28Type3D529"]]. (Type=5) | ||
258 | |||
259 | * [[HEX format Payload>>||anchor="H2.2.2HEXformatPayload28Type3D029"]]. (Type=0) | ||
260 | |||
261 | User can specify the payload type when choose the connection protocol. Example: | ||
262 | |||
263 | (% style="color:#037691" %)**AT+PRO=2,0** (%%) ~/~/ Use UDP Connection & hex Payload | ||
264 | |||
265 | (% style="color:#037691" %)**AT+PRO=2,5** (%%) ~/~/ Use UDP Connection & Json Payload | ||
266 | |||
267 | (% style="color:#037691" %)**AT+PRO=3,0** (%%) ~/~/ Use MQTT Connection & hex Payload | ||
268 | |||
269 | (% style="color:#037691" %)**AT+PRO=3,5 ** (%%) ~/~/ Use MQTT Connection & Json Payload | ||
270 | |||
271 | (% style="color:#037691" %)**AT+PRO=4,0** (%%) ~/~/ Use TCP Connection & hex Payload | ||
272 | |||
273 | (% style="color:#037691" %)**AT+PRO=4,5** (%%) ~/~/ Use TCP Connection & Json Payload | ||
274 | |||
275 | **Since firmware V1.1.0**, (% style="color:#4472c4" %)**IMSI, Pulse_count, VDC_input, IDC_input**(%%) have all been added to the payload. | ||
276 | |||
277 | The following describes the latest payload. | ||
278 | |||
279 | (% style="color:red" %)**Note: The default is AT+GPS=0 ~/~/ The GPS function is not enabled. Therefore, the GPS collection time in the following example paylaod does not follow the system time, and the latitude and longitude are 0.** | ||
280 | |||
281 | |||
282 | === 2.2.1 General Json Format(Type~=5) === | ||
283 | |||
284 | |||
285 | The payload will show Pulse_count, VDC_input, IDC_input only if the corresponding function is enabled. Below is an example with **[[AT+EXT=1,1,1>>||anchor="H3.14addPulse_count2CVDC_input2CIDC_input28SincefirmwareV1.1.029"]]**. | ||
286 | |||
287 | This is the General Json Format. As below: | ||
288 | |||
289 | (% style="color:#4472c4" %)**{"IMEI":"864370064394465","IMSI":"460086860409006","Model":"SDI12-CB","Payload":"01113METER TER12 112T12-00024895\r\n1+1831.34+22.3+1\r\n","pulse_count":0,"vdc_input":3.261,"idc_input":0.000,"interrupt":0,"interrupt_level":0,"battery":3.268,"signal":24,"time":"2025-02-22T01:53:52Z","latitude":0.000000,"longitude":0.000000,"gps_time":"1970-01-01T00:00:00Z","1":[0,0.000,0.000,"01113METER TER12 112T12-00024895\r\n1+1831.27+21.7+1\r\n","2025-02-22T01:02:32Z"],"2":[0,0.000,0.000,"01113METER TER12 112T12-00024895\r\n1+1831.57+21.7+1\r\n","2025-02-22T00:47:32Z"],"3":[0,0.000,0.000,"01113METER TER12 112T12-00024895\r\n1+1832.29+21.2+1\r\n","2025-02-22T00:32:32Z"],"4":[0,0.000,0.000,"01113METER TER12 112T12-00024895\r\n1+1831.49+21.4+1\r\n","2025-02-22T00:17:32Z"],"5":[0,0.000,0.000,"01113METER TER12 112T12-00024895\r\n1+1831.64+21.4+1\r\n","2025-02-22T00:02:32Z"],"6":[0,0.000,0.000,"01113METER TER12 112T12-00024895\r\n1+1831.65+21.4+1\r\n","2025-02-21T23:47:32Z"],"7":[0,0.000,0.000,"01113METER TER12 112T12-00024895\r\n1+1831.43+21.4+1\r\n","2025-02-21T23:32:32Z"],"8":[0,0.000,0.000,"01113METER TER12 112T12-00024895\r\n1+1832.08+21.4+1\r\n","2025-02-21T23:17:32Z"]}** | ||
290 | |||
291 | [[image:image-20250222112308-1.png||height="666" width="830"]] | ||
292 | |||
293 | (% style="color:red" %)**Notice, from above payload:** | ||
294 | |||
295 | * Payload, pulse_count, vdc_input, idc_input, Interrupt, Interrupt_level, Battery, Signal, time, latitude, longitude & GPS time are the value at uplink time. | ||
296 | |||
297 | * Json entry 1 ~~ 8 are the last 1 ~~ 8 sampling data as specify by (% style="color:#4472c4" %)**AT+CLOCKLOG=1,65535,15,8 **(%%)Command. Each entry includes (from left to right): pulse_count, vdc_input, idc_input, payload & Sampling time. | ||
298 | |||
299 | If the corresponding mode is not enabled, such as **AT+EXT=0,0,0**, then the payload: | ||
300 | |||
301 | * Payload, Interrupt, Interrupt_level, Battery, Signal, time, latitude, longitude & GPS time are the value at uplink time. | ||
302 | |||
303 | * Json entry 1 ~~ 8 are the last 1 ~~ 8 sampling data as specify by (% style="color:#4472c4" %)**AT+CLOCKLOG=1,65535,15,8 **(%%)Command. Each entry includes (from left to right): payload, Sampling time. | ||
304 | |||
305 | === 2.2.2 HEX format Payload(Type~=0) === | ||
306 | |||
307 | |||
308 | The payload will show Pulse_count, VDC_input, IDC_input only if the corresponding function is enabled. Below is an example with **[[AT+EXT=1,1,1>>||anchor="H3.14addPulse_count2CVDC_input2CIDC_input28SincefirmwareV1.1.029"]]**. | ||
309 | |||
310 | This is the HEX Format. As below: | ||
311 | |||
312 | (% style="color:#4472c4" %)**f864370064394465f460086860409006476e0c8c1a000000000000000000000000000067b92c7a000000000c900000013131334d455445522020205445523132203131325431322d30303032343839350d0a312b313833312e30352b32322e332b310d0a67b922280000000000000000013131334d455445522020205445523132203131325431322d30303032343839350d0a312b313833312e32372b32312e372b310d0a67b91ea40000000000000000013131334d455445522020205445523132203131325431322d30303032343839350d0a312b313833312e35372b32312e372b310d0a67b91b200000000000000000013131334d455445522020205445523132203131325431322d30303032343839350d0a312b313833322e32392b32312e322b310d0a67b9179c0000000000000000013131334d455445522020205445523132203131325431322d30303032343839350d0a312b313833312e34392b32312e342b310d0a67b914180000000000000000013131334d455445522020205445523132203131325431322d30303032343839350d0a312b313833312e36342b32312e342b310d0a67b910940000000000000000013131334d455445522020205445523132203131325431322d30303032343839350d0a312b313833312e36352b32312e342b310d0a67b90d100000000000000000013131334d455445522020205445523132203131325431322d30303032343839350d0a312b313833312e34332b32312e342b310d0a67b9098c0000000000000000013131334d455445522020205445523132203131325431322d30303032343839350d0a312b313833322e30382b32312e342b310d0a** | ||
313 | |||
314 | [[image:image-20250222112324-2.png]] | ||
315 | |||
316 | [[image:image-20250222113257-5.png||height="660" width="827"]] | ||
317 | |||
318 | |||
319 | (% style="color:blue" %)**Device ID(f+IMEI):**(%%)** **f864370064394465 = 864370064394465 | ||
320 | |||
321 | |||
322 | (% style="color:blue" %)**SIM Card ID(f+IMSI):**(%%)** **f460086860409006 = 460086860409006 | ||
323 | |||
324 | |||
325 | (% style="color:blue" %)**Version:** | ||
326 | |||
327 | These bytes include the hardware and software version. | ||
328 | |||
329 | (% style="color:#037691" %)**Higher byte:**(%%) Specify Sensor Model: 0x47 for SDI-12-CB | ||
330 | |||
331 | (% style="color:#037691" %)**Lower byte:**(%%) Specify the software version: 0x6e=110, means firmware version 1.1.0 | ||
332 | |||
333 | |||
334 | (% style="color:blue" %)**BAT (Battery Info):** | ||
335 | |||
336 | Check the battery voltage for SDI-12-CB. | ||
337 | |||
338 | Ex1: 0x0c8c = 3212mV | ||
339 | |||
340 | Ex2: 0x0B49 = 2889mV | ||
341 | |||
342 | |||
343 | (% style="color:blue" %)**Signal Strength:** | ||
344 | |||
345 | NB-IoT Network signal Strength. | ||
346 | |||
347 | **Ex1: 0x1a = 26** | ||
348 | |||
349 | **0** -113dBm or less | ||
350 | |||
351 | **1** -111dBm | ||
352 | |||
353 | **2...30** -109dBm... -53dBm | ||
354 | |||
355 | **31** -51dBm or greater | ||
356 | |||
357 | **99** Not known or not detectable | ||
358 | |||
359 | |||
360 | (% style="color:blue" %)**Interrupt:** | ||
361 | |||
362 | This data field shows if this packet is generated by interrupt or not. | ||
363 | |||
364 | (% style="color:#037691" %)**Example:** | ||
365 | |||
366 | 0x00: Normal uplink packet. | ||
367 | |||
368 | 0x01: Interrupt Uplink Packet. | ||
369 | |||
370 | |||
371 | (% style="color:blue" %)**Interrupt_level:** | ||
372 | |||
373 | GPIO_EXTI is used as Interrupt Pin. | ||
374 | |||
375 | This byte shows whether the interrupt is triggered by a high or low level. | ||
376 | |||
377 | (% style="color:#037691" %)**Example**: | ||
378 | |||
379 | 01(H): GPIO_EXTI pin is high level. | ||
380 | |||
381 | 00(L): GPIO_EXTI pin is low level | ||
382 | |||
383 | |||
384 | (% style="color:blue" %)**Latitude:** | ||
385 | |||
386 | EX1:** **0x00000000 ~/~/ Locating fails or is not enabled. | ||
387 | |||
388 | EX2:** **0x015a771e(H)=22705950(D)=22.705950 | ||
389 | |||
390 | |||
391 | (% style="color:blue" %)**Longitude:** | ||
392 | |||
393 | EX1:** **0x00000000 ~/~/ Locating fails or is not enabled. | ||
394 | |||
395 | EX2:** **0x114242500(H)=114242500(D)=114.242500 | ||
396 | |||
397 | |||
398 | (% style="color:blue" %)**GPS_Timestamp:** | ||
399 | |||
400 | EX1: 0x00000000 ~/~/ The value is "1970-01-01T00:00:00Z" in JSON format. The initial GPS time is not refreshed if GPS positioning is disabled or fails. | ||
401 | |||
402 | EX2: 0x6682595d =1719818589 = 2024-07-01 15:23:09 | ||
403 | |||
404 | |||
405 | (% style="color:blue" %)**TimeStamp:**(%%)** ** | ||
406 | |||
407 | Unit TimeStamp Example: 67b92c7a(H) = 1740188794(D) | ||
408 | |||
409 | Put the decimal value into this link([[https:~~/~~/www.epochconverter.com/)>>url:https://www.epochconverter.com/)]] to get the time. | ||
410 | |||
411 | |||
412 | (% style="color:blue" %)**Pulse count:** | ||
413 | |||
414 | The GPIO_EXTI pin is also used for the counting function. | ||
415 | |||
416 | When the pulse counting function is enabled using the AT+EXT command, the GPIO_EXTI pin is used for counting instead of interrupting. | ||
417 | |||
418 | (% style="color:#037691" %)**Example:** | ||
419 | |||
420 | 0x00000230(H)=560(D) | ||
421 | |||
422 | |||
423 | (% style="color:blue" %)**VDC input:** | ||
424 | |||
425 | Measure the voltage value. The range is 0 to 30V. | ||
426 | |||
427 | (% style="color:#037691" %)**Example:** | ||
428 | |||
429 | 0c90(H) = 3216(D)/1000= 3.216V | ||
430 | |||
431 | |||
432 | (% style="color:blue" %)**IDC input:** | ||
433 | |||
434 | Measure the current value. The range is 0 to 20mA. | ||
435 | |||
436 | (% style="color:#037691" %)**Example:** | ||
437 | |||
438 | 27AE(H) = 10158 (D)/1000 = 10.158mA. | ||
439 | |||
440 | |||
441 | (% style="color:blue" %)**Payload_version: ** | ||
442 | |||
443 | The payload version number is used to parse different decodes. | ||
444 | |||
445 | |||
446 | (% style="color:blue" %)**SDI12_sensor_data:** | ||
447 | |||
448 | The data returned by the SDI-12 sensor or UART sensor needs to be cut out the AT+DATACUTx or AT+ALLDATAMOD commands. | ||
449 | |||
450 | |||
451 | If the corresponding mode is not enabled, such as **AT+EXT=0,0,0**, then the payload: | ||
452 | |||
453 | [[image:image-20250222115909-6.png]] | ||
454 | |||
455 | |||
456 | = 3. Configure SDI-12-CB = | ||
457 | |||
458 | == 3.1 Configure Methods == | ||
459 | |||
460 | |||
461 | SDI-12-CB supports below configure method: | ||
462 | |||
463 | * AT Command via Bluetooth Connection (**Recommended**): [[BLE Configure Instruction>>http://wiki.dragino.com/xwiki/bin/view/Main/BLE%20Bluetooth%20Remote%20Configure/]]. | ||
464 | |||
465 | * AT Command via UART Connection : See [[UART Connection>>http://wiki.dragino.com/xwiki/bin/view/Main/UART%20Access%20for%20LoRa%20ST%20v4%20base%20model/#H2.3UARTConnectionforSN50v3basemotherboard]]. | ||
466 | |||
467 | == 3.2 Serial Access Password == | ||
468 | |||
469 | |||
470 | After the Bluetooth or UART connection is successful, use the Serial Access Password to enter the AT command window. | ||
471 | |||
472 | The label on the box of the node will print the initial password: AT+PIN=**xxxxxx**, and directly use the six-digit password to access the AT instruction window. | ||
473 | |||
474 | [[image:https://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/RS485-NB%2C-NS_RS485%2CUART_to_NB-IoT_Converter_User_Manual/WebHome/image-20250226165815-1.png?rev=1.1||alt="image-20250226165815-1.png"]] | ||
475 | |||
476 | |||
477 | If you need to change the password, use **AT+PWORD=**xxxxxx (6 characters), -CB nodes only support lowercase letters. | ||
478 | |||
479 | [[image:image-20240826183633-3.png]] | ||
480 | |||
481 | |||
482 | (% style="color:red" %)**Note: After entering the command, you need to add a line break, and you can also set automatic line breaks in the Bluetooth tool or UART connection tool.** | ||
483 | |||
484 | [[image:image-20240826183639-4.png]] | ||
485 | |||
486 | |||
487 | == 3.3 AT Commands Set == | ||
488 | |||
489 | |||
490 | AT+<CMD>? : Help on <CMD> | ||
491 | |||
492 | AT+<CMD> : Run <CMD> | ||
493 | |||
494 | AT+<CMD>=<value> : Set the value | ||
495 | |||
496 | AT+<CMD>=? : Get the value | ||
497 | |||
498 | |||
499 | (% style="color:blue" %)**General Commands** | ||
500 | |||
501 | AT : Attention | ||
502 | |||
503 | AT? : Short Help | ||
504 | |||
505 | AT+MODEL : Get module information | ||
506 | |||
507 | ATZ : Trig a reset of the MCU | ||
508 | |||
509 | AT+DEUI : Get or set the Device ID | ||
510 | |||
511 | AT+SLEEP : Get or set the sleep status | ||
512 | |||
513 | AT+DEBUG : Set more info output | ||
514 | |||
515 | AT+SERVADDR: Get or Set the Server address | ||
516 | |||
517 | AT+TDC : Get or set the application data transmission interval in s | ||
518 | |||
519 | AT+APN : Get or set the APN | ||
520 | |||
521 | AT+12VT : Get or Set extend the time of 12V power | ||
522 | |||
523 | AT+5VT : Get or Set extend the time of 5V power | ||
524 | |||
525 | AT+3V3T : Get or Set extend the time of 3V3 power | ||
526 | |||
527 | AT+INTMOD : Get or Set the trigger interrupt mode (0:input,1:falling or rising,2:falling,3:rising) | ||
528 | |||
529 | AT+PRO : Get or Set usage agreement (1:COAP,2:UDP,3:MQTT,4:TCP) | ||
530 | |||
531 | AT+RXDL : Get or Set the receiving time | ||
532 | |||
533 | AT+CDP : Read or Clear cached data | ||
534 | |||
535 | AT+GETSENSORVALUE : Returns the current sensor measurement | ||
536 | |||
537 | AT+DNSCFG : Get or Set DNS Server | ||
538 | |||
539 | AT+CSQTIME : Get or Set the time to join the network | ||
540 | |||
541 | AT+GDNS : Get or Set the DNS | ||
542 | |||
543 | AT+TLSMOD : Get or Set the TLS mode | ||
544 | |||
545 | AT+MQOS : Set the QoS level of MQTT | ||
546 | |||
547 | AT+IPTYPE : Set the IPv4 or IPv6 | ||
548 | |||
549 | AT+QSW : Power on and power off BG95 module | ||
550 | |||
551 | AT+ADDRI: Send aI command to SDI12 sensor | ||
552 | |||
553 | AT+ADDRM: Send aM command to SDI12 sensor | ||
554 | |||
555 | AT+ADDRC: Send aC command to SDI12 sensor | ||
556 | |||
557 | AT+ADDRR: Send aR command to SDI12 sensor | ||
558 | |||
559 | AT+CMDEAR: Erase command(number of begin to number of ending) | ||
560 | |||
561 | AT+PAYVER: Get or Set payload version | ||
562 | |||
563 | AT+ALLDATAMOD: Get or Set mode of all data is cuted | ||
564 | |||
565 | AT+CONVFORM: Conversion between characters and their ASCII | ||
566 | |||
567 | AT+COMMAND: Send data of command1-15 to SDI12 deceive for payload | ||
568 | |||
569 | AT+DATACUT: Cut receive data after use command1-15 | ||
570 | |||
571 | AT+CFGDEV: Send data to SDI12 deceive | ||
572 | |||
573 | AT+CLOCKLOG: Enable or Disable Clock Logging | ||
574 | |||
575 | AT+TIMESTAMP : Get or Set UNIX timestamp in second | ||
576 | |||
577 | AT+GETLOG : Print serial port logs | ||
578 | |||
579 | AT+CFG : Print all settings | ||
580 | |||
581 | |||
582 | (% style="color:blue" %)**MQTT Management** | ||
583 | |||
584 | AT+CLIENT : Get or Set the MQTT clientID | ||
585 | |||
586 | AT+UNAME : Get or Set the MQTT Username | ||
587 | |||
588 | AT+PWD : Get or Set the MQTT password | ||
589 | |||
590 | AT+PUBTOPIC: Get or set MQTT publishing topic | ||
591 | |||
592 | AT+SUBTOPIC: Get or set MQTT subscription topic | ||
593 | |||
594 | |||
595 | (% style="color:blue" %)**Coap Management** | ||
596 | |||
597 | AT+URI1: Get or set CoAP option 1 | ||
598 | |||
599 | AT+URI2: Get or set CoAP option 2 | ||
600 | |||
601 | AT+URI3: Get or set CoAP option 3 | ||
602 | |||
603 | AT+URI4: Get or set CoAP option 4 | ||
604 | |||
605 | AT+URI5: Get or set CoAP option 5 | ||
606 | |||
607 | AT+URI6: Get or set CoAP option 6 | ||
608 | |||
609 | AT+URI7: Get or set CoAP option 7 | ||
610 | |||
611 | AT+URI8: Get or set CoAP option 8 | ||
612 | |||
613 | |||
614 | (% style="color:blue" %)**GPS** | ||
615 | |||
616 | AT+GNSST : Extend the time to turn on GNSS | ||
617 | |||
618 | AT+GPS : Turn off and on GPS | ||
619 | |||
620 | AT+GTDC : Get or set GPS positioning interval in units of h | ||
621 | |||
622 | |||
623 | (% style="color:blue" %)**Information** | ||
624 | |||
625 | AT+FDR1 : Reset parameters to factory default values except for passwords | ||
626 | |||
627 | AT+FDR : Reset Parameters to Factory Default | ||
628 | |||
629 | AT+PWORD : Get or set the System password | ||
630 | |||
631 | AT+LDATA : Get the last upload data | ||
632 | |||
633 | |||
634 | == 3.4 SDI-12 Related Commands == | ||
635 | |||
636 | |||
637 | User need to configure SDI-12-CB to communicate with SDI-12 sensors otherwise the uplink payload will only include a few bytes. | ||
638 | |||
639 | |||
640 | === 3.4.1 Basic SDI-12 debug command === | ||
641 | |||
642 | |||
643 | 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 NB-IoT downlink command. | ||
644 | |||
645 | If SDI-12 sensor return value after get these commands, //SDI-12-CB// will uplink the return on FPORT=100, otherwise, if there is no response from SDI-12 sensor. //SDI-12-CB// will uplink NULL (0x 4E 55 4C 4C) to server. | ||
646 | |||
647 | The following is the display information on the serial port and the server. | ||
648 | |||
649 | |||
650 | [[image:image-20231102163336-2.png||height="287" width="500"]] | ||
651 | |||
652 | |||
653 | [[image:image-20231102163417-5.png||height="83" width="772"]] | ||
654 | |||
655 | |||
656 | |||
657 | ==== (% style="color:blue" %)**al! ~-~- Get SDI-12 sensor Identification**(%%) ==== | ||
658 | |||
659 | |||
660 | * AT Command: AT+ADDRI=aa | ||
661 | * NB-IoT Downlink(prefix 0xAA00): AA 00 aa | ||
662 | |||
663 | (% style="color:#037691" %)**Parameter: **(%%)aa: ASCII value of SDI-12 sensor address in downlink or HEX value in AT Command) | ||
664 | |||
665 | (% style="color:blue" %)**Example : **(%%)AT+ADDRI=0 ( Equal to downlink: 0x AA 00 30) | ||
666 | |||
667 | |||
668 | The following is the display information on the serial port and the server. | ||
669 | |||
670 | |||
671 | [[image:image-20231030170258-5.png]] | ||
672 | |||
673 | |||
674 | [[image:image-20231030170155-4.png||height="400" width="1192"]] | ||
675 | |||
676 | (% style="display:none" %) (%%) | ||
677 | |||
678 | |||
679 | ==== (% style="color:blue" %)**aM!,aMC!, aM1!- aM9!, aMC1!- aMC9!**(%%) ==== | ||
680 | |||
681 | |||
682 | (% style="color:red" %)**aM! **(%%): Start Non-Concurrent Measurement | ||
683 | |||
684 | (% style="color:red" %)**aMC! **(%%): Start Non-Concurrent Measurement – Request CRC | ||
685 | |||
686 | (% style="color:red" %)**aM1!- aM9! **(%%): Additional Measurements | ||
687 | |||
688 | (% style="color:red" %)**aMC1!- aMC9!**(%%) : Additional Measurements – Request CRC | ||
689 | |||
690 | |||
691 | * AT Command : AT+ADDRM=0,1,0,1 | ||
692 | |||
693 | (% style="color:#037691" %)**aa**(%%): SDI-12 sensor address. | ||
694 | |||
695 | (% style="color:#037691" %)**bb**(%%): 0: no CRC, 1: request CRC | ||
696 | |||
697 | (% style="color:#037691" %)**cc**(%%): 1-9: Additional Measurement, 0: no additional measurement | ||
698 | |||
699 | (% style="color:#037691" %)**dd**(%%): delay (in second) to send (% style="color:#037691" %)__**aD0!**__(%%) to get return. | ||
700 | |||
701 | |||
702 | The following is the display information on the serial port and the server. | ||
703 | |||
704 | |||
705 | [[image:image-20231030173023-6.png]] | ||
706 | |||
707 | |||
708 | [[image:image-20231030173128-7.png||height="253" width="1114"]] | ||
709 | |||
710 | |||
711 | |||
712 | ==== (% style="color:blue" %)**aC!, aCC!, aC1!- aC9!, aCC1!- aCC9! **(%%) ==== | ||
713 | |||
714 | |||
715 | (% style="color:red" %)**aC!**(%%) : Start Concurrent Measurement | ||
716 | |||
717 | (% style="color:red" %)**aCC!** (%%): Start Concurrent Measurement – Request CRC | ||
718 | |||
719 | (% style="color:red" %)**aC1!- aC9!**(%%) : Start Additional Concurrent Measurements | ||
720 | |||
721 | (% style="color:red" %)**aCC1!- aCC9!**(%%) : Start Additional Concurrent Measurements – Request CRC | ||
722 | |||
723 | |||
724 | * AT Command : AT+ADDRC=0,1,0,1 | ||
725 | |||
726 | (% style="color:#037691" %)**aa**(%%): SDI-12 sensor address. | ||
727 | |||
728 | (% style="color:#037691" %)**bb**(%%): 0: no CRC, 1: request CRC | ||
729 | |||
730 | (% style="color:#037691" %)**cc**(%%): 1-9: Additional Measurement, 0: no additional measurement | ||
731 | |||
732 | (% style="color:#037691" %)**dd**(%%): delay (in second) to send (% style="color:#037691" %)__**aD0!**__(%%)__ __to get return. | ||
733 | |||
734 | |||
735 | The following is the display information on the serial port and the server. | ||
736 | |||
737 | |||
738 | [[image:image-20231030173510-8.png]] | ||
739 | |||
740 | |||
741 | [[image:image-20231030173533-9.png||height="231" width="1159"]] | ||
742 | |||
743 | |||
744 | |||
745 | ==== (% style="color:blue" %)**aR0!- aR9!, aRC0!- aRC9!**(%%) ==== | ||
746 | |||
747 | |||
748 | Start Continuous Measurement | ||
749 | |||
750 | Start Continuous Measurement – Request CRC | ||
751 | |||
752 | |||
753 | * AT Command : AT+ADDRR=0,1,0,1 | ||
754 | |||
755 | (% style="color:#037691" %)**aa**(%%): SDI-12 sensor address. | ||
756 | |||
757 | (% style="color:#037691" %)**bb**(%%): 0: no CRC, 1: request CRC | ||
758 | |||
759 | (% style="color:#037691" %)**cc**(%%): 1-9: Additional Measurement, 0: no additional measurement | ||
760 | |||
761 | (% style="color:#037691" %)**dd**(%%): delay (in second) to send (% style="color:#037691" %)__**aD0!**__(%%) to get return. | ||
762 | |||
763 | |||
764 | The following is the display information on the serial port and the server. | ||
765 | |||
766 | |||
767 | [[image:image-20231030173727-10.png]] | ||
768 | |||
769 | |||
770 | [[image:image-20231030173747-11.png||height="237" width="1194"]] | ||
771 | |||
772 | |||
773 | === 3.4.2 Advance SDI-12 Debug command === | ||
774 | |||
775 | |||
776 | This command can be used to debug all SDI-12 command.(% style="display:none" %) | ||
777 | |||
778 | (% style="color:blue" %)**Example1: **(%%) AT+CFGDEV =0RC0!,1 | ||
779 | |||
780 | (% style="color:#037691" %)**0RC0! **(%%): SDI-12 Command, | ||
781 | |||
782 | (% style="color:#037691" %)**1 **(%%): Delay 1 second. ( 0: 810 mini-second) | ||
783 | |||
784 | The following is the display information on the serial port and the server. | ||
785 | |||
786 | [[image:image-20231030174559-13.png]] | ||
787 | |||
788 | (% style="display:none" %) (%%) | ||
789 | |||
790 | (% style="color:blue" %)**Example2: **(%%) AT+CFGDEV =0M!,1,1 | ||
791 | |||
792 | (% style="color:#037691" %)**0M! **(%%): SDI-12 Command, | ||
793 | |||
794 | (% style="color:#037691" %)**1 **(%%): Delay 1 second. ( 0: 810 mini-second) | ||
795 | |||
796 | (% style="color:#037691" %)**1 **(%%): Use aD0! command access. | ||
797 | |||
798 | |||
799 | The following is the display information on the serial port and the server. | ||
800 | |||
801 | [[image:image-20231030174626-14.png]] | ||
802 | |||
803 | |||
804 | === 3.4.3 Convert ASCII to String === | ||
805 | |||
806 | |||
807 | This command is used to convert between ASCII and String format. | ||
808 | |||
809 | AT+CONVFORM ( Max length: 80 bytes) | ||
810 | |||
811 | |||
812 | (% style="color:blue" %)**Example:** | ||
813 | |||
814 | 1) AT+CONVFORM=0, string Convert String from String to ASCII | ||
815 | |||
816 | [[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SDI-12-LB%20--%20SDI-12%20to%20LoRaWAN%20Converter%20User%20Manual/WebHome/1675214845056-885.png?rev=1.1||alt="1675214845056-885.png"]] | ||
817 | |||
818 | |||
819 | 2) AT+CONVFORM=1, ASCII Convert ASCII to String. | ||
820 | |||
821 | [[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SDI-12-LB%20--%20SDI-12%20to%20LoRaWAN%20Converter%20User%20Manual/WebHome/1675214856590-846.png?rev=1.1||alt="1675214856590-846.png"]] | ||
822 | |||
823 | |||
824 | === 3.4.4 Define periodically SDI-12 commands and uplink. === | ||
825 | |||
826 | |||
827 | AT+COMMANDx & AT+DATACUTx | ||
828 | |||
829 | User can define max 15 SDI-12 Commands (AT+COMMAND1 ~~ AT+COMMANDF). On each uplink period (TDC time, default 20 minutes), SDI-12-CB will send these SDI-12 commands and wait for return from SDI-12 sensors. SDI-12-CB will then combine these returns and uplink via NB-IoT. | ||
830 | |||
831 | |||
832 | * (% style="color:blue" %)**AT Command:** | ||
833 | |||
834 | (% style="color:#037691" %)**AT+COMMANDx=var1,var2,var3,var4.** | ||
835 | |||
836 | (% style="color:red" %)**var1**(%%): SDI-12 command , for example: 0RC0! | ||
837 | |||
838 | (% style="color:red" %)**var2**(%%): Wait timeout for return. (unit: second) | ||
839 | |||
840 | (% style="color:red" %)**var3**(%%): Whether to send //addrD0!// to get return after var2 timeout. 0: Don't Send //addrD0! //; 1: Send //addrD0!//. | ||
841 | |||
842 | (% style="color:red" %)**var4**(%%): validation check for return. If return invalid, SDI-12-CB will resend this command. Max 3 retries. | ||
843 | |||
844 | (% style="color:red" %)**0 **(%%) No validation check; | ||
845 | |||
846 | (% style="color:red" %)**1** (%%) Check if return chars are printable char(0x20 ~~ 0x7E); | ||
847 | |||
848 | (% style="color:red" %)**2**(%%) Check if there is return from SDI-12 sensor | ||
849 | |||
850 | (% style="color:red" %)**3** (%%) Check if return pass CRC check ( SDI-12 command var1 must include CRC request); | ||
851 | |||
852 | |||
853 | Each AT+COMMANDx is followed by a (% style="color:blue" %)**AT+DATACUT**(%%) command. AT+DATACUT command is used to take the useful string from the SDI-12 sensor so the final payload will have the minimum length to uplink. | ||
854 | |||
855 | |||
856 | (% style="color:blue" %)**AT+DATACUTx**(%%) : This command defines how to handle the return from AT+COMMANDx, max return length is 100 bytes. | ||
857 | |||
858 | (% border="1" style="width:433px" %) | ||
859 | |(% style="background-color:#f2f2f2; width:433px" %)((( | ||
860 | (% style="color:#0070c0" %)**AT+DATACUTx=a,b,c** | ||
861 | |||
862 | **a**: length for the return of AT+COMMAND | ||
863 | |||
864 | **b**: 1: grab valid value by byte, max 6 bytes. 2: grab valid value by bytes section, max 3 sections. | ||
865 | |||
866 | **c**: define the position for valid value. | ||
867 | ))) | ||
868 | |||
869 | For example, if return from AT+COMMAND1 is “013METER TER12 112T12-00024895<CR><LF>” , Below AT+DATACUT1 will get different result to combine payload: | ||
870 | |||
871 | |||
872 | (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:510px" %) | ||
873 | |=(% style="width: 164px;background-color:#4F81BD;color:white" %)**AT+DATACUT1 value**|=(% style="width: 346px;background-color:#4F81BD;color:white" %)**Final Result to combine Payload** | ||
874 | |(% style="background-color:#f2f2f2; width:164px" %)34,1,1+2+3|(% style="background-color:#f2f2f2; width:344px" %)0D 00 01 30 31 33 | ||
875 | |(% style="background-color:#f2f2f2; width:164px" %)34,2,1~~8+12~~16|(% style="background-color:#f2f2f2; width:344px" %)0D 00 01 30 31 33 4D 45 54 45 52 54 45 52 31 32 | ||
876 | |(% style="background-color:#f2f2f2; width:164px" %)34,2,1~~34|(% style="background-color:#f2f2f2; width:344px" %)0D 00 01 30 31 33 4D 45 54 45 52 20 20 20 54 45 52 31 32 20 31 31 32 54 31 32 2D 30 30 30 32 34 38 39 35 0D 0A | ||
877 | |||
878 | (% style="color:red" %)**Note : if user use AT+COMMANDx to add a new command, he also need to send AT+DATACUTx downlink.** | ||
879 | |||
880 | |||
881 | (% style="color:blue" %)**Clear SDI12 Command** | ||
882 | |||
883 | The AT+COMMANDx and AT+DATACUTx settings are stored in special location, user can use below command to clear them. | ||
884 | |||
885 | |||
886 | * (% style="color:#037691" %)**AT Command:** | ||
887 | |||
888 | (% style="color:#4f81bd" %)**AT+CMDEAR=mm,nn** (%%) mm: start position of erase ,nn: stop position of erase | ||
889 | |||
890 | |||
891 | **Etc.** AT+CMDEAR=1,10 means erase AT+COMMAND1/AT+DATACUT1 to AT+COMMAND10/AT+DATACUT10 | ||
892 | |||
893 | |||
894 | (% style="color:blue" %)**command combination** | ||
895 | |||
896 | Below shows a screen shot how the results combines together to a uplink payload. | ||
897 | |||
898 | (% style="display:none" %) (%%) | ||
899 | |||
900 | [[image:image-20231102172455-6.png||height="909" width="1014"]] | ||
901 | |||
902 | If user don't want to use DATACUT for some command, he simply want to uplink all returns. AT+ALLDATAMOD can be set to 1. | ||
903 | |||
904 | (% style="color:blue" %)**AT+ALLDATAMOD**(%%) will simply get all return and don't do CRC check as result for SDI-12 command. AT+DATACUTx command has higher priority, if AT+DATACUTx has been set, AT+ALLDATAMOD will be ignore for this SDI-12 command. | ||
905 | |||
906 | |||
907 | (% style="color:#4f81bd" %)**For example: **(%%) as below photo, AT+ALLDATAMOD=1, but AT+DATACUT1&2 has been set, AT+DATACUT1 &2will be still effect the result. | ||
908 | |||
909 | |||
910 | [[image:image-20231102172516-7.png||height="819" width="1074"]](% style="display:none" %) | ||
911 | |||
912 | If AT+ALLDATAMOD=1, (% style="color:#4f81bd" %)**FX,X**(%%) will be added in the payload, (% style="color:#4f81bd" %)**FX**(%%) specify which command is used and (% style="color:#4f81bd" %)**X**(%%) specify the length of return(Hex format), (% style="color:#4f81bd" %)**(X) **(%%)in JSON format will be added to the payload, where (% style="color:#4f81bd" %)**X**(%%) represents the command number. | ||
913 | |||
914 | for example in above screen, F1 23 means the return is from AT+COMMAND1 and the return is 35 bytes. | ||
915 | |||
916 | |||
917 | == 3.5 Examples To Set SDI commands == | ||
918 | |||
919 | |||
920 | (% style="color:red" %)**Note: The reading sensor command method of the NB series SDI12 converter is the same as that of the LORA series SDI12 converter.** | ||
921 | |||
922 | |||
923 | === 3.5.1 Examples 1 ~-~- General Example === | ||
924 | |||
925 | |||
926 | COM port and SDI-12 sensor communication converted to SDI-12-CB and SDI-12 sensor communication. | ||
927 | |||
928 | [[image:image-20250224111224-5.jpeg]] | ||
929 | |||
930 | |||
931 | (% style="color:blue" %)**1) The AT+COMMANDx command is applied to the red arrow part, and sends the SDI12 command to the SDI12 sensor:** | ||
932 | |||
933 | a. Send the first command and get the first reply: | ||
934 | |||
935 | (% style="color:#037691" %)**AT+COMMANDx=1I!,0,0,1** | ||
936 | |||
937 | b. Send the second command and get the second reply: | ||
938 | |||
939 | (% style="color:#037691" %)**AT+COMMANDx=2I!,0,0,1** | ||
940 | |||
941 | c. Send the third command and get the third reply: | ||
942 | |||
943 | (% style="color:#037691" %)**AT+COMMANDx=3I!,0,0,1** | ||
944 | |||
945 | d. Send the fourth command and get the fourth reply: | ||
946 | |||
947 | (% style="color:#037691" %)**AT+COMMANDx=4I!,0,0,1** | ||
948 | |||
949 | e. Send the fifth command plus the sixth command, get the sixth reply: | ||
950 | |||
951 | (% style="color:#037691" %)**AT+COMMANDx=1M!,2,1,1** | ||
952 | |||
953 | f. Send the seventh command plus the eighth command, get the eighth reply: | ||
954 | |||
955 | (% style="color:#037691" %)**AT+COMMANDx=2M!,2,1,1** | ||
956 | |||
957 | g. Send the ninth command plus the tenth command, get the tenth reply: | ||
958 | |||
959 | (% style="color:#037691" %)**AT+COMMANDx=3M!,1,1,1** | ||
960 | |||
961 | h. Send the eleventh command plus the twelfth command, get the twelfth reply: | ||
962 | |||
963 | (% style="color:#037691" %)**AT+COMMANDx=4M!,1,1,1** | ||
964 | |||
965 | |||
966 | (% style="color:blue" %)**2) The AT+DATACUTx command is applied to the green arrow part, receiving and cut out data from the SDI12 sensor:** | ||
967 | |||
968 | a. The first reply, all 34 characters: "113TRUEBNERSMT100038220303182331<CR><LF>" | ||
969 | |||
970 | Cut out all characters: (% _mstmutation="1" style="color:#037691" %)**AT+ALLDATAMOD=1 or AT+DATACUTx=34,2,1~~34**(% style="color:#037691" %); | ||
971 | |||
972 | b. The sixth reply, all 31 characters:"1+19210+1.04+0.00+22.49+11.75<CR><LF>" | ||
973 | |||
974 | Cut out all characters: (% _mstmutation="1" style="color:#037691" %)**AT+ALLDATAMOD=1 or AT+DATACUTx=31,2,1~~31**(% style="color:#037691" %); | ||
975 | |||
976 | c. The eighth reply, all 31 characters:"2+18990+1.08+0.00+22.24+11.80<CR><LF>" | ||
977 | |||
978 | Cut out all characters: (% _mstmutation="1" style="color:#037691" %)**AT+ALLDATAMOD=1 or AT+DATACUTx=31,2,1~~31**(% style="color:#037691" %); | ||
979 | |||
980 | d. The tenth reply, all 15 characters:”3-2919.8+24.0<CR><LF>” | ||
981 | |||
982 | Cut out all characters: (% _mstmutation="1" style="color:#037691" %)**AT+ALLDATAMOD=1 or AT+DATACUTx=15,2,1~~15**(% style="color:#037691" %); | ||
983 | |||
984 | e. The twelfth reply, all 25 characters:"4+30.8+22.84+4.7+954.38<CR><LF>" | ||
985 | |||
986 | Partial cut, the cut sensor address and the first two parameters: (% style="color:#037691" %)**AT+DATACUTx=25,2,1~~12, cut out the character field " 4+30.8+22.84"**. | ||
987 | |||
988 | |||
989 | === 3.5.2 Example 2 ~-~- Connect to Hygrovue10 === | ||
990 | |||
991 | ==== 3.5.2.1 Reference Manual and Command ==== | ||
992 | |||
993 | |||
994 | * [[Hygrovue10 Product Page>>https://www.campbellsci.com/hygrovue10]] | ||
995 | |||
996 | * Commands to be used in PC and output. | ||
997 | |||
998 | ~1. check device address | ||
999 | |||
1000 | 2. change device address | ||
1001 | |||
1002 | 3. check device ID | ||
1003 | |||
1004 | 4. start measure | ||
1005 | |||
1006 | 5. Get Meausre result | ||
1007 | |||
1008 | [[image:image-20250224111807-6.jpeg]] | ||
1009 | |||
1010 | |||
1011 | ==== 3.5.2.2 Hardware Connection to SDI-12-CB ==== | ||
1012 | |||
1013 | [[image:image-20250224111830-7.jpeg]] | ||
1014 | |||
1015 | |||
1016 | ==== 3.5.2.3 Commands set in SDI-12-CB and uplink payload ==== | ||
1017 | |||
1018 | [[image:image-20250224112150-8.jpeg]] | ||
1019 | |||
1020 | [[image:image-20250224112244-9.jpeg]] | ||
1021 | |||
1022 | |||
1023 | === 3.5.3 Example 3 ~-~- Connect to SIL-400 === | ||
1024 | |||
1025 | ==== 3.5.3.1 Reference Manual and Command ==== | ||
1026 | |||
1027 | |||
1028 | * [[SIL-400 Product Page>>https://www.apogeeinstruments.com/sil-411-commercial-grade-sdi-12-digital-output-standard-field-of-view-infrared-radiometer-sensor/]] | ||
1029 | |||
1030 | * Commands to be used in PC and output. | ||
1031 | |||
1032 | ~1. check device address | ||
1033 | |||
1034 | 2. change device address | ||
1035 | |||
1036 | 3. check device ID | ||
1037 | |||
1038 | 4. start measure | ||
1039 | |||
1040 | 5. Get Meausre result | ||
1041 | |||
1042 | [[image:image-20250224112349-10.jpeg]] | ||
1043 | |||
1044 | |||
1045 | ==== 3.5.3.2 Hardware Connection to SDI-12-CB ==== | ||
1046 | |||
1047 | |||
1048 | [[image:image-20250224112742-13.jpeg]] | ||
1049 | |||
1050 | |||
1051 | ==== 3.5.3.3 Commands set in SDI-12-CB and uplink payload ==== | ||
1052 | |||
1053 | |||
1054 | [[image:image-20250224112808-14.jpeg]] | ||
1055 | |||
1056 | [[image:image-20250224112834-15.jpeg]] | ||
1057 | |||
1058 | |||
1059 | === 3.5.4 Example 4 ~-~- Connect to TEROS-12 === | ||
1060 | |||
1061 | ==== 3.5.4.1 Reference Manual and Command ==== | ||
1062 | |||
1063 | |||
1064 | * [[TEROS-12 Product Page>>https://www.metergroup.com/en/meter-environment/products/teros-12-soil-moisture-sensor]] | ||
1065 | |||
1066 | * Commands to be used in PC and output. | ||
1067 | |||
1068 | 1.check device address | ||
1069 | |||
1070 | 2.change device address | ||
1071 | |||
1072 | 3.check device ID | ||
1073 | |||
1074 | 4.start measure | ||
1075 | |||
1076 | 5.Get Meausre result | ||
1077 | |||
1078 | [[image:image-20250224112906-16.jpeg]] | ||
1079 | |||
1080 | |||
1081 | ==== 3.5.4.2 Hardware Connection to SDI-12-CB ==== | ||
1082 | |||
1083 | |||
1084 | [[image:image-20250224112924-17.jpeg]] | ||
1085 | |||
1086 | |||
1087 | ==== 3.5.4.3 Commands set in SDI-12-CB and uplink payload ==== | ||
1088 | |||
1089 | |||
1090 | [[image:image-20250224112944-18.jpeg]] | ||
1091 | |||
1092 | [[image:image-20250224113000-19.jpeg]] | ||
1093 | |||
1094 | |||
1095 | === 3.5.5 Example 5 ~-~- Connect to SIL-400/TEROS-12 & Hygrovue10 === | ||
1096 | |||
1097 | ==== 3.5.5.1 Important Notice! ==== | ||
1098 | |||
1099 | |||
1100 | * The product page and reference command see above example 2,3,4 | ||
1101 | |||
1102 | * All of these SDI-12 sensors use the same address (address 0) by default. So we need to change their address to different address, by using **aAb!** command. See above example. | ||
1103 | |||
1104 | * The sensor needs to be powered to a steady statue. So the 12VT time need to be set to the maximum stable time for the sensors. in this example, it is 13 seconds. | ||
1105 | |||
1106 | * If these SDI-12 sensors are powered by external power source. It will add 300uA in the total current in SDI-12-CB. | ||
1107 | |||
1108 | (% style="display:none" %) | ||
1109 | |||
1110 | |||
1111 | |||
1112 | ==== 3.5.5.2 Hardware Connection to SDI-12-CB ==== | ||
1113 | |||
1114 | |||
1115 | [[image:image-20250224113030-20.jpeg]] | ||
1116 | |||
1117 | |||
1118 | ==== 3.5.5.3 Commands set in SDI-12-CB and uplink payload ==== | ||
1119 | |||
1120 | |||
1121 | [[image:image-20250224113056-21.jpeg]] | ||
1122 | |||
1123 | [[image:image-20250224113115-22.jpeg]] | ||
1124 | |||
1125 | |||
1126 | === 3.6.6 Example 6 ~-~- Connect to ENTELECHY-EP_SDI-12 === | ||
1127 | |||
1128 | ==== 3.6.6.1 Reference Manual and Command ==== | ||
1129 | |||
1130 | |||
1131 | * [[https:~~/~~/enviroprosoilprobes.com/wp-content/uploads/2019/11/ENTELECHY-EP_SDI-12-Commands.pdf>>url:https://enviroprosoilprobes.com/wp-content/uploads/2019/11/ENTELECHY-EP_SDI-12-Commands.pdf]] | ||
1132 | |||
1133 | * Commands to be used in PC and output. | ||
1134 | |||
1135 | 1.check device address | ||
1136 | |||
1137 | 2.change device address | ||
1138 | |||
1139 | 3.check device ID | ||
1140 | |||
1141 | 4.start measure | ||
1142 | |||
1143 | 5.Get Meausre result | ||
1144 | |||
1145 | [[image:image-20250224113144-23.jpeg]] | ||
1146 | |||
1147 | |||
1148 | ==== 3.6.6.2 Hardware Connection to SDI-12-CB ==== | ||
1149 | |||
1150 | |||
1151 | [[image:image-20250224113203-24.jpeg]] | ||
1152 | |||
1153 | |||
1154 | ==== 3.6.6.3 Commands set in SDI-12-CB and uplink payload ==== | ||
1155 | |||
1156 | |||
1157 | [[image:image-20250224113224-25.jpeg]] | ||
1158 | |||
1159 | [[image:image-20250224113241-26.jpeg]] | ||
1160 | |||
1161 | |||
1162 | == 3.7 Test Uplink and Change Update Interval == | ||
1163 | |||
1164 | |||
1165 | By default, Sensor will send uplinks (% style="color:blue" %)**every 2 hours** | ||
1166 | |||
1167 | User can use below commands to change the (% style="color:blue" %)**uplink interval**. | ||
1168 | |||
1169 | (% style="color:#037691" %)**AT+TDC=7200 ** (%%) ~/~/ Set Update Interval to 7200s | ||
1170 | |||
1171 | User can also push the button for more than 1 seconds to activate an uplink. | ||
1172 | |||
1173 | |||
1174 | == 3.8 Trggier an uplink by external interrupt == | ||
1175 | |||
1176 | |||
1177 | SDI-12-CB has an external trigger interrupt function. Users can use the GPIO_EXTI pin to trigger the upload of data packets. | ||
1178 | |||
1179 | (% style="color:blue" %)**AT command:** | ||
1180 | |||
1181 | * (% style="color:#037691" %)**AT+INTMOD **(%%) ~/~/ Set the trigger interrupt mode | ||
1182 | |||
1183 | * (% style="color:#037691" %)**AT+INTMOD=0 **(%%) ~/~/ Disable Interrupt,as a digital input pin | ||
1184 | |||
1185 | * (% style="color:#037691" %)**AT+INTMOD=1 **(%%) ~/~/ Trigger by rising and falling edge | ||
1186 | |||
1187 | * (% style="color:#037691" %)**AT+INTMOD=2 **(%%) ~/~/ Trigger by falling edge | ||
1188 | |||
1189 | * (% style="color:#037691" %)**AT+INTMOD=3 **(%%) ~/~/ Trigger by rising edge | ||
1190 | |||
1191 | (% style="color:blue" %)**Downlink command:**(%%)** (% style="color:#037691" %)0x06(%%)** | ||
1192 | |||
1193 | Format: Command Code (0x06) followed by 3 bytes. | ||
1194 | |||
1195 | This means that the interrupt mode of the end node is set to 0x000003=3 (rising edge trigger), and the type code is 06. | ||
1196 | |||
1197 | * Example 1: Downlink Payload: 06000000 ~/~/ Turn off interrupt mode | ||
1198 | * Example 2: Downlink Payload: 06000003 ~/~/ Set the interrupt mode to rising edge trigger | ||
1199 | |||
1200 | == 3.9 Set the output time == | ||
1201 | |||
1202 | |||
1203 | Feature, Control the output 3V3 , 5V or 12V. | ||
1204 | |||
1205 | (% style="color:blue" %)**AT Command: AT+3V3T** | ||
1206 | |||
1207 | (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:474px" %) | ||
1208 | |=(% style="width: 154px;background-color:#4F81BD;color:white" %)**Command Example**|=(% style="width: 201px;background-color:#4F81BD;color:white" %)**Function**|=(% style="width: 119px;background-color:#4F81BD;color:white" %)**Response** | ||
1209 | |(% style="background-color:#f2f2f2; width:154px" %)AT+3V3T=?|(% style="background-color:#f2f2f2; width:201px" %)Show 3V3 open time.|(% style="background-color:#f2f2f2; width:116px" %)((( | ||
1210 | 0 | ||
1211 | OK | ||
1212 | ))) | ||
1213 | |(% style="background-color:#f2f2f2; width:154px" %)AT+3V3T=0|(% style="background-color:#f2f2f2; width:201px" %)Normally open 3V3 power supply.|(% style="background-color:#f2f2f2; width:116px" %)((( | ||
1214 | OK | ||
1215 | default setting | ||
1216 | ))) | ||
1217 | |(% style="background-color:#f2f2f2; width:154px" %)AT+3V3T=1000|(% style="background-color:#f2f2f2; width:201px" %)Close after a delay of 1000 milliseconds.|(% style="background-color:#f2f2f2; width:116px" %)((( | ||
1218 | OK | ||
1219 | ))) | ||
1220 | |(% style="background-color:#f2f2f2; width:154px" %)AT+3V3T=65535|(% style="background-color:#f2f2f2; width:201px" %)Normally closed 3V3 power supply.|(% style="background-color:#f2f2f2; width:116px" %)((( | ||
1221 | OK | ||
1222 | ))) | ||
1223 | |||
1224 | (% style="color:blue" %)**AT Command: AT+5VT** | ||
1225 | |||
1226 | (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:470px" %) | ||
1227 | |=(% style="width: 155px;background-color:#4F81BD;color:white" %)**Command Example**|=(% style="width: 196px;background-color:#4F81BD;color:white" %)**Function**|=(% style="width: 119px;background-color:#4F81BD;color:white" %)**Response** | ||
1228 | |(% style="background-color:#f2f2f2; width:155px" %)AT+5VT=?|(% style="background-color:#f2f2f2; width:196px" %)Show 5V open time.|(% style="background-color:#f2f2f2; width:114px" %)((( | ||
1229 | 0 | ||
1230 | OK | ||
1231 | ))) | ||
1232 | |(% style="background-color:#f2f2f2; width:155px" %)AT+5VT=0|(% style="background-color:#f2f2f2; width:196px" %)Normally closed 5V power supply.|(% style="background-color:#f2f2f2; width:114px" %)((( | ||
1233 | OK | ||
1234 | default setting | ||
1235 | ))) | ||
1236 | |(% style="background-color:#f2f2f2; width:155px" %)AT+5VT=1000|(% style="background-color:#f2f2f2; width:196px" %)Close after a delay of 1000 milliseconds.|(% style="background-color:#f2f2f2; width:114px" %)((( | ||
1237 | OK | ||
1238 | ))) | ||
1239 | |(% style="background-color:#f2f2f2; width:155px" %)AT+5VT=65535|(% style="background-color:#f2f2f2; width:196px" %)Normally open 5V power supply.|(% style="background-color:#f2f2f2; width:114px" %)((( | ||
1240 | OK | ||
1241 | ))) | ||
1242 | |||
1243 | (% style="color:blue" %)**AT Command: AT+12VT ** | ||
1244 | |||
1245 | (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:443px" %) | ||
1246 | |=(% style="width: 156px;background-color:#4F81BD;color:white" %)**Command Example**|=(% style="width: 199px;background-color:#4F81BD;color:white" %)**Function**|=(% style="width: 88px;background-color:#4F81BD;color:white" %)**Response** | ||
1247 | |(% style="background-color:#f2f2f2; width:156px" %)AT+12VT=?|(% style="background-color:#f2f2f2; width:199px" %)Show 12V open time.|(% style="background-color:#f2f2f2; width:83px" %)((( | ||
1248 | 0 | ||
1249 | OK | ||
1250 | ))) | ||
1251 | |(% style="background-color:#f2f2f2; width:156px" %)AT+12VT=0|(% style="background-color:#f2f2f2; width:199px" %)Normally closed 12V power supply.|(% style="background-color:#f2f2f2; width:83px" %)OK | ||
1252 | |(% style="background-color:#f2f2f2; width:156px" %)AT+12VT=500|(% style="background-color:#f2f2f2; width:199px" %)Close after a delay of 500 milliseconds.|(% style="background-color:#f2f2f2; width:83px" %)((( | ||
1253 | OK | ||
1254 | ))) | ||
1255 | |||
1256 | == 3.10 Set the all data mode == | ||
1257 | |||
1258 | |||
1259 | Feature, Set the all data mode. | ||
1260 | |||
1261 | (% style="color:blue" %)**AT Command: AT+ALLDATAMOD** | ||
1262 | |||
1263 | (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:437px" %) | ||
1264 | |=(% style="background-color:#4F81BD;color:white" %)**Command Example**|=(% style="background-color:#4F81BD;color:white" %)**Function**|=(% style="background-color:#4F81BD;color:white" %)**Response** | ||
1265 | |(% style="background-color:#f2f2f2" %)AT+ALLDATAMOD=?|(% style="background-color:#f2f2f2" %)Show current all data mode|(% style="background-color:#f2f2f2" %)((( | ||
1266 | 0 | ||
1267 | OK | ||
1268 | ))) | ||
1269 | |(% style="background-color:#f2f2f2" %)AT+ALLDATAMOD=1|(% style="background-color:#f2f2f2" %)Set all data mode is 1.|(% style="background-color:#f2f2f2" %)OK | ||
1270 | |||
1271 | == 3.11 Set the payload version == | ||
1272 | |||
1273 | |||
1274 | Feature, Set the payload version. | ||
1275 | |||
1276 | (% style="color:blue" %)**AT Command: AT+PAYVER** | ||
1277 | |||
1278 | (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:437px" %) | ||
1279 | |=(% style="width: 158px;background-color:#4F81BD;color:white" %)**Command Example**|=(% style="width: 192px;background-color:#4F81BD;color:white" %)**Function**|=(% style="width: 87px;background-color:#4F81BD;color:white" %)**Response** | ||
1280 | |(% style="background-color:#f2f2f2; width:158px" %)AT+PAYVER=?|(% style="background-color:#f2f2f2; width:192px" %)Show current payload version|(% style="background-color:#f2f2f2" %)((( | ||
1281 | 1 | ||
1282 | OK | ||
1283 | ))) | ||
1284 | |(% style="background-color:#f2f2f2; width:158px" %)AT+PAYVER=5|(% style="background-color:#f2f2f2; width:192px" %)Set payload version is 5.|(% style="background-color:#f2f2f2" %)OK | ||
1285 | |||
1286 | == 3.12 Scheduled domain name resolution == | ||
1287 | |||
1288 | |||
1289 | This command is used to set up scheduled domain name resolution | ||
1290 | |||
1291 | (% style="color:blue" %)**AT Command:** | ||
1292 | |||
1293 | * (% style="color:#037691" %)**AT+DNSTIMER=XX**(%%)** **~/~/ Unit: hour | ||
1294 | |||
1295 | After setting this command, domain name resolution will be performed regularly. | ||
1296 | |||
1297 | |||
1298 | == 3.13 Clock logging == | ||
1299 | |||
1300 | |||
1301 | Sometimes when we deploy lots of end nodes in field. We want all sensors sample data at the same time, and upload these data together for analyze. In such case, we can use clock loging feature. | ||
1302 | |||
1303 | We can use this command to set the start time of data recording and the time interval to meet the requirements of the specific collection time of data. | ||
1304 | |||
1305 | * (% style="color:blue" %)**AT Command:**(%%) (% style="color:#037691" %)**AT+CLOCKLOG=a,b,c,d** | ||
1306 | |||
1307 | (% style="color:#037691" %)**a:**(%%)** 0:** Disable Clock logging. ** 1: **Enable Clock Logging | ||
1308 | |||
1309 | (% style="color:#037691" %)**b:**(%%)** **Specify First sampling start second: range **(0 ~~ 3599, 65535) ** ~/~/ (% style="color:red" %)**Note:**(%%)** **If parameter b is set to 65535, the log period starts after the node accesses the network and sends packets. | ||
1310 | |||
1311 | (% style="color:#037691" %)**c:**(%%)** **Specify the sampling interval: range **(0 ~~ 255 minutes)** | ||
1312 | |||
1313 | (% style="color:#037691" %)**d:**(%%)** **How many entries should be uplink on every TDC **(max 32)** | ||
1314 | |||
1315 | (% style="color:red" %)**Note: To disable clock recording, set the following parameters: AT+CLOCKLOG=1,65535,0,0** | ||
1316 | |||
1317 | [[image:http://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/SPH01-NB_NB-IoT_Soil_pH_Sensor_User_Manual/WebHome/image-20240315141254-1.png?rev=1.1||alt="image-20240315141254-1.png"]] | ||
1318 | |||
1319 | **Example:** | ||
1320 | |||
1321 | **AT+CLOCKLOG=1,65535,1,5** | ||
1322 | |||
1323 | After the node sends the first packet, data is recorded to the memory at intervals of 1 minute. For each TDC uplink, the uplink load will include: battery information + the last 5 memory records (payload + timestamp). | ||
1324 | |||
1325 | [[image:image-20240730151506-2.png||height="586" width="718"]] | ||
1326 | |||
1327 | (% style="color:red" %)**Note: Users need to synchronize the server time before configuring this command. If the server time is not synchronized before this command is configured, the command takes effect only after the node is reset.** | ||
1328 | |||
1329 | |||
1330 | == 3.14 add Pulse_count, VDC_input, IDC_input (Since firmware V1.1.0) == | ||
1331 | |||
1332 | |||
1333 | Feature, set to add Pulse counting, voltage acquisition, current acquisition. | ||
1334 | |||
1335 | (% style="color:red" %)**Note: When the pulse counting function is enabled using the AT+EXT command, the GPIO_EXTI pin will be used for counting rather than interrupting.** | ||
1336 | |||
1337 | (% style="color:blue" %)**AT Command:**(%%) (% style="color:#037691" %)**AT+EXT** | ||
1338 | |||
1339 | (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:437px" %) | ||
1340 | |=(% style="width: 169px; background-color: rgb(79, 129, 189); color: white;" %)**Command Example**|=(% style="width: 162px; background-color: rgb(79, 129, 189); color: white;" %)**Function**|=(% style="width: 106px;background-color:#4F81BD;color:white" %)**Response** | ||
1341 | |(% style="background-color:#f2f2f2; width:169px" %)AT+EXT=?|(% style="background-color:#f2f2f2; width:162px" %)Show the current EXT configuration|(% style="background-color:#f2f2f2" %)((( | ||
1342 | 0,0,0(default) | ||
1343 | |||
1344 | |||
1345 | OK | ||
1346 | ))) | ||
1347 | |(% style="background-color:#f2f2f2; width:169px" %)AT+EXT=1,0,0|(% style="background-color:#f2f2f2; width:162px" %)Set to add Pulse counting|(% style="background-color:#f2f2f2" %)OK | ||
1348 | |||
1349 | (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:510px" %) | ||
1350 | |=(% style="width: 163px; background-color: rgb(79, 129, 189); color: white;" %)**Command Example**|=(% style="width: 173px; background-color: rgb(79, 129, 189); color: white;" %)**Parameters**|=(% style="width: 174px; background-color: rgb(79, 129, 189); color: white;" %)**Explanation** | ||
1351 | |(% colspan="1" rowspan="3" style="background-color:#f2f2f2; width:163px" %)((( | ||
1352 | |||
1353 | |||
1354 | |||
1355 | |||
1356 | |||
1357 | AT+EXT=a,b,c | ||
1358 | )))|(% style="background-color:#f2f2f2; width:173px" %)((( | ||
1359 | |||
1360 | |||
1361 | a: used to add pulse counting function. | ||
1362 | )))|(% style="background-color:#f2f2f2; width:170px" %)((( | ||
1363 | 0: Disable pulse counting | ||
1364 | 1: Enable pulse counting | ||
1365 | ))) | ||
1366 | |(% style="background-color:#f2f2f2; width:173px" %)b: used to add voltage acquisition function.|(% style="background-color:#f2f2f2; width:170px" %)0: Disables voltage acquisition | ||
1367 | 1: Enable voltage acquisition | ||
1368 | |(% style="background-color:#f2f2f2; width:173px" %)c: used to add current acquisition function.|(% style="background-color:#f2f2f2; width:170px" %)((( | ||
1369 | 0: Disable current acquisition | ||
1370 | 1: Enable current acquisition | ||
1371 | ))) | ||
1372 | |||
1373 | (% style="color:blue" %)**Downlink Command:**(%%) (% style="color:#037691" %)**0xAD aa bb cc** | ||
1374 | |||
1375 | Format: Command Code (0xAD) followed by 3 bytes, aa,bb,cc correspond one-to-one to the parameters of AT+EXT=a,b,c. | ||
1376 | |||
1377 | **Example:** | ||
1378 | |||
1379 | * Downlink paylaod: AD 00 00 00 ~/~/Equal to AT+EXT=0,0,0 Pulse counting, voltage acquisition, and current acquisition are not enabled. | ||
1380 | * Downlink paylaod: AD 01 00 00 ~/~/Equal to AT+EXT=1,0,0 Enable pulse counting. | ||
1381 | * Downlink paylaod: AD 01 01 01 ~/~/Equal to AT+EXT=1,1,1 Pulse counting, voltage acquisition, and current acquisition are enabled. | ||
1382 | |||
1383 | == 3.15 Set the pulse count value (Since firmware V1.1.0) == | ||
1384 | |||
1385 | |||
1386 | Feature, set the initial value of the pulse count. | ||
1387 | |||
1388 | (% style="color:blue" %)**AT Command:**(%%) (% style="color:#037691" %)**AT+SETCNT** | ||
1389 | |||
1390 | (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:437px" %) | ||
1391 | |=(% style="width: 169px; background-color: rgb(79, 129, 189); color: white;" %)**Command Example**|=(% style="width: 172px; background-color: rgb(79, 129, 189); color: white;" %)**Function**|=(% style="width: 96px;background-color:#4F81BD;color:white" %)**Response** | ||
1392 | |(% style="background-color:#f2f2f2; width:169px" %)AT+SETCNT=10|(% style="background-color:#f2f2f2; width:162px" %)((( | ||
1393 | Initialize the pulse count value to 10. | ||
1394 | )))|(% style="background-color:#f2f2f2" %)OK | ||
1395 | |(% style="background-color:#f2f2f2; width:169px" %)AT+SETCNT=50|(% style="background-color:#f2f2f2; width:162px" %)Initialize the pulse count value to 50.|(% style="background-color:#f2f2f2" %)OK | ||
1396 | |||
1397 | (% style="color:blue" %)**Downlink Command:**(%%) (% style="color:#037691" %)**0xA9** | ||
1398 | |||
1399 | Format: Command Code (0xA9) followed by 4 bytes. | ||
1400 | |||
1401 | **Example:** | ||
1402 | |||
1403 | * Downlink paylaod: A9 00 00 0A ~/~/Equal to AT+SETCNT=10 | ||
1404 | * Downlink paylaod: A9 00 00 32 ~/~/Equal to AT+SETCNT=50 | ||
1405 | |||
1406 | == 3.16 Set the downlink debugging mode(Since firmware v1.1.0) == | ||
1407 | |||
1408 | |||
1409 | Feature: Set the conversion between the standard version and 1T version downlinks. | ||
1410 | |||
1411 | (% style="color:blue" %)**AT command: AT+DOWNTE** | ||
1412 | |||
1413 | (% border="1" cellspacing="3" style="background-color:#f2f2f2; width:510px" %) | ||
1414 | |=(% style="width: 138px; background-color: rgb(79, 129, 189); color: white;" %)**Command Example**|=(% style="width: 143px; background-color: rgb(79, 129, 189); color: white;" %)**Function/Parameters**|=(% style="width: 229px; background-color: rgb(79, 129, 189); color: white;" %)**Response/Explanation** | ||
1415 | |(% style="width:134px" %)AT+DOWNTE=?|(% style="width:143px" %)Get current Settings|(% style="width:229px" %)((( | ||
1416 | 0,0 (default) | ||
1417 | OK | ||
1418 | ))) | ||
1419 | |(% colspan="1" rowspan="2" style="width:134px" %)((( | ||
1420 | |||
1421 | |||
1422 | |||
1423 | |||
1424 | AT+DOWNTE=a,b | ||
1425 | )))|(% style="width:143px" %)**a**: Set the conversion between the downlink of the standard version and 1T version|(% style="width:229px" %)((( | ||
1426 | **0**: Set the downlink of the standard version. | ||
1427 | **1**: Set the downlink of the 1T version(ThingsEye platform) | ||
1428 | ))) | ||
1429 | |(% style="width:143px" %)**b**: Enable/Disable downlink debugging|(% style="width:229px" %)((( | ||
1430 | **0**: Disable downlink debugging mode. | ||
1431 | **1**: Enable downlink debugging mode, users can see the original downlink reception. | ||
1432 | ))) | ||
1433 | |||
1434 | **Example:** | ||
1435 | |||
1436 | * AT+DOWNTE=0,1 ~/~/ Set to standard version downlink, and enable downlink debugging. | ||
1437 | * AT+DOWNTE=1,1 ~/~/ Set to 1T version downlink, and enable downlink debugging. | ||
1438 | |||
1439 | (% style="color:blue" %)**Downlink Command: ** | ||
1440 | |||
1441 | No downlink commands for feature | ||
1442 | |||
1443 | |||
1444 | = 4. Battery & Power Consumption = | ||
1445 | |||
1446 | |||
1447 | SDI-12-CB use ER26500 + SPC1520 battery pack. See below link for detail information about the battery info and how to replace. | ||
1448 | |||
1449 | [[**Battery Info & Power Consumption Analyze**>>http://wiki.dragino.com/xwiki/bin/view/Main/How%20to%20calculate%20the%20battery%20life%20of%20Dragino%20sensors%3F/]] . | ||
1450 | |||
1451 | |||
1452 | = 5. Firmware update = | ||
1453 | |||
1454 | |||
1455 | User can change device firmware to:: | ||
1456 | |||
1457 | * Update with new features. | ||
1458 | |||
1459 | * Fix bugs. | ||
1460 | |||
1461 | Firmware and changelog can be downloaded from : **[[Firmware download link>>https://www.dropbox.com/scl/fo/1mzflb9p9kx15btnc11gr/ALbRqWUdMNWLJGI2hdDviKI/SDI-12-CB?dl=0&rlkey=ku98jt8u30coqy66saebai2co&subfolder_nav_tracking=1]]** | ||
1462 | |||
1463 | Methods to Update Firmware: | ||
1464 | |||
1465 | * (Recommended way) OTA firmware update via BLE: [[**Instruction**>>url:http://wiki.dragino.com/xwiki/bin/view/Main/BLE_Firmware_Update_NB_Sensors_BC660K-GL/]]. | ||
1466 | |||
1467 | * Update through UART TTL interface : **[[Instruction>>http://wiki.dragino.com/xwiki/bin/view/Main/UART_Access_for_NB_ST_BC660K-GL/#H4.2UpdateFirmware28Assumethedevicealreadyhaveabootloader29]]**. | ||
1468 | |||
1469 | = 6. FAQ = | ||
1470 | |||
1471 | == 6.1 How can I access the BG95-NGFF AT Commands? == | ||
1472 | |||
1473 | |||
1474 | User can access to BG95-NGFF directly and send AT Commands. | ||
1475 | |||
1476 | [[See BG95-NGFF AT Command set>>https://www.dropbox.com/scl/fo/1mzflb9p9kx15btnc11gr/ALDWTvDjuVoXvDJuYWCRh5U/Vendor%20Datasheet/BG95?dl=0&rlkey=ku98jt8u30coqy66saebai2co&subfolder_nav_tracking=1]] | ||
1477 | |||
1478 | |||
1479 | == 6.2 How to configure the device through the MQTT subscription function? == | ||
1480 | |||
1481 | |||
1482 | Subscription content: {AT COMMAND} | ||
1483 | |||
1484 | (% style="color:#037691" %)**Example:** | ||
1485 | |||
1486 | Setting AT+5VT=500 through Node-RED requires MQTT to send the content {AT+5VT=500}. | ||
1487 | |||
1488 | [[image:https://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/RS485-NB%2C-NS_RS485%2CUART_to_NB-IoT_Converter_User_Manual/WebHome/1698140180821-486.png?rev=1.1||alt="1698140180821-486.png"]] | ||
1489 | |||
1490 | The serial port displays: | ||
1491 | |||
1492 | [[image:https://wiki.dragino.com/xwiki/bin/download/Main/User%20Manual%20for%20LoRaWAN%20End%20Nodes/RS485-NB%2C-NS_RS485%2CUART_to_NB-IoT_Converter_User_Manual/WebHome/image-20231024174641-2.png?width=531&height=267&rev=1.1||alt="image-20231024174641-2.png"]] | ||
1493 | |||
1494 | |||
1495 | == 6.3 General Manual for -CB , -CS models == | ||
1496 | |||
1497 | |||
1498 | Users can follow the instructions in this [[link>>url:http://wiki.dragino.com/xwiki/bin/view/Main/General%20Manual%20for%20-CB%20%2C%20-CS%20models/]] to see how to configure to connect to different servers. | ||
1499 | |||
1500 | |||
1501 | = 7. Order Info = | ||
1502 | |||
1503 | |||
1504 | Part Number: (% style="color:blue" %)**SDI-12-CB-XX-YY** | ||
1505 | |||
1506 | (% style="color:red" %)**XX:** | ||
1507 | |||
1508 | * (% style="color:#037691" %)**GE**(%%): General version ( Exclude SIM card) | ||
1509 | |||
1510 | * (% style="color:#037691" %)**1T**(%%): with 1NCE* 10 years 500MB SIM card and Pre-configure to ThingsEye server | ||
1511 | |||
1512 | (% style="color:blue" %)**YY: The grand connector hole size** | ||
1513 | |||
1514 | * M12: M12 hole | ||
1515 | |||
1516 | * M16: M16 hole | ||
1517 | |||
1518 | = 8. Packing Info = | ||
1519 | |||
1520 | |||
1521 | (% style="color:#037691" %)**Package Includes**: | ||
1522 | |||
1523 | * SDI-12-CB SDI-12 to NB-IoT/LTE-M Converter x 1 | ||
1524 | |||
1525 | * External antenna x 1 | ||
1526 | |||
1527 | (% style="color:#037691" %)**Dimension and weight**: | ||
1528 | |||
1529 | * Device Size: cm | ||
1530 | |||
1531 | * Device Weight: g | ||
1532 | |||
1533 | * Package Size / pcs : cm | ||
1534 | |||
1535 | * Weight / pcs : g | ||
1536 | |||
1537 | = 9. Support = | ||
1538 | |||
1539 | |||
1540 | * Support is provided Monday to Friday, from 09:00 to 18:00 GMT+8. Due to different timezones we cannot offer live support. However, your questions will be answered as soon as possible in the before-mentioned schedule. | ||
1541 | |||
1542 | * Provide as much information as possible regarding your enquiry (product models, accurately describe your problem and steps to replicate it etc) and send a mail to [[Support@dragino.cc>>mailto:Support@dragino.cc]]. | ||
1543 | |||
1544 | (% style="display:none" %) (%%) |