1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-28 23:09:46 +01:00
RIOT/examples/asymcute_mqttsn
Marian Buschsieweke 82d98ed377
examples, tests: update Makefile.ci for AVR8
Ran dist/tools/insufficient_memory for all AVR8 boards.
2023-12-01 19:37:05 +01:00
..
main.c examples: replace sock_udp_str2ep() with sock_udp_name2ep() 2022-03-24 17:11:15 +01:00
Makefile examples,tests: Drop redundant dependency 2023-04-19 16:58:10 +02:00
Makefile.ci examples, tests: update Makefile.ci for AVR8 2023-12-01 19:37:05 +01:00
README.md examples/asymcute_mqttsn: fix target name 2018-08-01 19:49:57 +02:00

About

This example application demonstrates the usage of the Asymcute MQTT-SN client library. It provides a number of shell commands that can be used to trigger selected procedures like connecting to a gateway, registration and subscription of topics, and publishing of data.

Setup

For this application to do anything useful, a running MQTT-SN gateway is needed. If you don't have access to one, RIOT provides a simple way to start one locally by providing a dedicated mosquitto_rsmb make target, type:

make mosquitto_rsmb

This will download, build, and run the Eclipse Mosquitto.rsmb 'Really Small Message Broker' (found here).

Usage

Simply type

help

for a list of available commands.

NOTE 1

The UDP socket handling for IPv6 based endpoints in the Mosquitto.rsmb implementation is buggy when it comes to handling link local addresses, as the implementation does not remember the interface on which data comes in, hindering it from sending out any responses.

Quick workaround: simply use global addresses

NOTE 2

It also seems that the Mosquitto.rsmb implementation has a bug when it comes to subscribing to topics: if a topic name was formerly registered and the same topic name is later used for issuing a subscription request, the gateway will assign a new topic ID to the same topic name, so publish messages to the initially assigned topic ID will not be seen by that subscription.