Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependents: cobaLCDJoyMotor_Thread odometry_omni_3roda_v3 odometry_omni_3roda_v1 odometry_omni_3roda_v2 ... more
mqtt.h File Reference
MQTT client. More...
Go to the source code of this file.
Data Structures | |
| struct | mqtt_connect_client_info_t |
| Client information and connection parameters. More... | |
| struct | mqtt_request_t |
| Pending request item, binds application callback to pending server requests. More... | |
| struct | mqtt_ringbuf_t |
| Ring buffer. More... | |
| struct | mqtt_client_t |
| MQTT client. More... | |
Typedefs | |
| typedef void(* | mqtt_connection_cb_t )(mqtt_client_t *client, void *arg, mqtt_connection_status_t status) |
| Function prototype for mqtt connection status callback. | |
| typedef void(* | mqtt_incoming_data_cb_t )(void *arg, const u8_t *data, u16_t len, u8_t flags) |
| Function prototype for MQTT incoming publish data callback function. | |
| typedef void(* | mqtt_incoming_publish_cb_t )(void *arg, const char *topic, u32_t tot_len) |
| Function prototype for MQTT incoming publish function. | |
| typedef void(* | mqtt_request_cb_t )(void *arg, err_t err) |
| Function prototype for mqtt request callback. | |
Enumerations | |
| enum | mqtt_connection_status_t |
Connection status codes. More... | |
| enum | { MQTT_DATA_FLAG_LAST = 1 } |
Data callback flags. More... | |
Functions | |
| err_t | mqtt_client_connect (mqtt_client_t *client, const ip_addr_t *ipaddr, u16_t port, mqtt_connection_cb_t cb, void *arg, const struct mqtt_connect_client_info_t *client_info) |
| Connect to server. | |
| void | mqtt_disconnect (mqtt_client_t *client) |
| Disconnect from server. | |
| mqtt_client_t * | mqtt_client_new (void) |
| Create new client. | |
| u8_t | mqtt_client_is_connected (mqtt_client_t *client) |
| Check connection status. | |
| void | mqtt_set_inpub_callback (mqtt_client_t *client, mqtt_incoming_publish_cb_t, mqtt_incoming_data_cb_t data_cb, void *arg) |
| Set callback to call for incoming publish. | |
| err_t | mqtt_sub_unsub (mqtt_client_t *client, const char *topic, u8_t qos, mqtt_request_cb_t cb, void *arg, u8_t sub) |
| Common function for subscribe and unsubscribe. | |
| err_t | mqtt_publish (mqtt_client_t *client, const char *topic, const void *payload, u16_t payload_length, u8_t qos, u8_t retain, mqtt_request_cb_t cb, void *arg) |
| Publish data to topic. | |
Detailed Description
MQTT client.
Definition in file mqtt.h.
Generated on Tue Jul 12 2022 13:03:25 by
1.7.2