<
From version < 1.8 >
edited by Xiaoling
on 2022/05/17 09:14
To version < 1.10 >
edited by Xiaoling
on 2022/05/17 09:17
>
Change comment: There is no comment for this version

Summary

Details

Page properties
Content
... ... @@ -292,22 +292,30 @@
292 292  == 5.1 Introduction ==
293 293  
294 294  (((
295 +(((
295 295  The Application Server exposes an MQTT server to work with streaming events. In order to use the MQTT server you need to create a new API key, which will function as connection password. You can also use an existing API key, as long as it has the necessary rights granted.
296 296  )))
298 +)))
297 297  
298 298  == 5.2 Create device steps at MQTT ==
299 299  
300 300  (((
303 +(((
301 301  The user creates a new API KEY after creating a device on TTN V3.
302 302  )))
306 +)))
303 303  
304 304  (((
309 +(((
305 305  Then copy the password and open MQTT.fx.
306 306  )))
312 +)))
307 307  
308 308  (((
315 +(((
309 309  Fill in Broker Address and Broker port.
310 310  )))
318 +)))
311 311  
312 312  [[image:https://wiki.dragino.com/images/thumb/8/82/V3_MQTT1_.png/600px-V3_MQTT1_.png||alt="V3 MQTT1 .png" height="325" width="600"]]
313 313  
... ... @@ -318,7 +318,9 @@
318 318  
319 319  The Application Server publishes uplink traffic on the following topics:
320 320  
321 -{{{ v3/{application id}@{tenant id}/devices/{device id}/join
329 +(% class="box" %)
330 +(((
331 + v3/{application id}@{tenant id}/devices/{device id}/join
322 322   v3/{application id}@{tenant id}/devices/{device id}/up
323 323   v3/{application id}@{tenant id}/devices/{device id}/down/queued
324 324   v3/{application id}@{tenant id}/devices/{device id}/down/sent
... ... @@ -327,31 +327,41 @@
327 327   v3/{application id}@{tenant id}/devices/{device id}/down/failed
328 328   v3/{application id}@{tenant id}/devices/{device id}/service/data
329 329   v3/{application id}@{tenant id}/devices/{device id}/location/solved
330 -}}}
340 +)))
331 331  
332 332  (((
333 -Note: Remember that the format of these topics for The Things Stack Open Source would contain {application id} instead of {application id}@{tenant id}.
343 +(((
344 +**Note**: Remember that the format of these topics for The Things Stack Open Source would contain {application id} instead of {application id}@{tenant id}.
334 334  )))
346 +)))
335 335  
336 336  [[image:https://wiki.dragino.com/images/thumb/d/dc/V3_MQTT3.png/600px-V3_MQTT3.png||alt="V3 MQTT3.png" height="400" width="600"]]
337 337  
338 338  (((
351 +(((
339 339  While you could subscribe to all of these topics separately, for the simplicity of this tutorial we use # to subscribe to all topics, i.e. to receive all uplink traffic.
340 340  )))
354 +)))
341 341  
342 342  [[image:https://wiki.dragino.com/images/thumb/e/e8/V3_MQTT4.jpg/600px-V3_MQTT4.jpg||alt="V3 MQTT4.jpg" height="326" width="600"]]
343 343  
344 344  (((
359 +(((
345 345  Downlinks can be scheduled by publishing the message to the topic v3/{application id}@{tenant id}/devices/{device id}/down/push.
346 346  )))
362 +)))
347 347  
348 348  (((
365 +(((
349 349  Note: Remember that the format of this topic for The Things Stack Open Source deployment would be v3/{application id}/devices/{device id}/down/push.
350 350  )))
368 +)))
351 351  
352 352  (((
371 +(((
353 353  Instead of /push, you can also use /replace to replace the downlink queue. Replacing with an empty array clears the downlink queue. Example:
354 354  )))
374 +)))
355 355  
356 356  [[image:https://wiki.dragino.com/images/thumb/e/e8/V3_MQTT5.png/600px-V3_MQTT5.png||alt="V3 MQTT5.png" height="289" width="600"]]
357 357  
Copyright ©2010-2024 Dragino Technology Co., LTD. All rights reserved
Dragino Wiki v2.0