Sample MQTT program - simple send and receive

Dependencies:   C12832 MQTT

Dependents:   MQTT_G_SENSOR

This program and the MQTT libraries it uses are part of the EclipseTM Paho project; specifically the embedded client.

This example and API are working, but are still in progress. Please give us your feedback.

HelloMQTT is an example of using the MQTT API. The MQTT API is portable across network interface stacks. MQTT is designed to be used with TCP/IP, but any transport with similar characteristics should be suitable.

HelloMQTT uses the NetworkInterface APIs in mbed OS 5 to show how this works. The MQTT library contains an MQTTNetwork.h header, which is a wrapper around the mbed networking interface. To switch between connectivity methods (the default is Ethernet) the easy-connect library is provided in this example application. You can change the connectivity method in mbed_app.json.

Adding new connectivity methods to the program is trivial, as long as they implement the mbed OS 5 NetworkStack API.

Files at this revision

API Documentation at this revision

Comitter:
Jan Jongboom
Date:
Mon Sep 11 16:43:49 2017 +0200
Parent:
21:a68bd76740f9
Child:
23:e38aaf532823
Commit message:
Roll back update to mbed OS 5.5

Changed in this revision

MQTT.lib Show annotated file Show diff for this revision Revisions of this file
easy-connect.lib Show annotated file Show diff for this revision Revisions of this file
mbed-os.lib Show annotated file Show diff for this revision Revisions of this file
--- a/MQTT.lib	Thu Sep 07 10:06:22 2017 +0100
+++ b/MQTT.lib	Mon Sep 11 16:43:49 2017 +0200
@@ -1,1 +1,1 @@
-https://mbed.org/teams/mqtt/code/MQTT/#08571008b958
+https://mbed.org/teams/mqtt/code/MQTT/#c37c8236e84a
--- a/easy-connect.lib	Thu Sep 07 10:06:22 2017 +0100
+++ b/easy-connect.lib	Mon Sep 11 16:43:49 2017 +0200
@@ -1,1 +1,1 @@
-https://github.com/ARMmbed/easy-connect/#4f8e48a4b076bf638c3c02c23995a883e1efa921
+https://github.com/ARMmbed/easy-connect/#cb933fb19cda0a733a64d6b71d271fb6bdaf9e6d
--- a/mbed-os.lib	Thu Sep 07 10:06:22 2017 +0100
+++ b/mbed-os.lib	Mon Sep 11 16:43:49 2017 +0200
@@ -1,1 +1,1 @@
-https://github.com/ARMmbed/mbed-os/#98ba8acb83cfc65f30a8a0771a27c71443ab093a
+https://github.com/ARMmbed/mbed-os/#2885c1b41e63158cb6faf5f107cd821ae06ef26c