MQTT API

Yimmo MQTT public API.

Flags

YMO_MQTT_FIXED_HDR_TYPE_MASK

http://docs.oasis-open.org/mqtt/mqtt/v3.1.1/os/mqtt-v3.1.1-os.html#_Toc398718020

Definition
#define YMO_MQTT_FIXED_HDR_TYPE_MASK 0xF0
YMO_MQTT_FIXED_HDR_FLAG_MASK

http://docs.oasis-open.org/mqtt/mqtt/v3.1.1/os/mqtt-v3.1.1-os.html#_Toc398718020

Definition
#define YMO_MQTT_FIXED_HDR_FLAG_MASK 0x0F

Types

type ymo_mqtt_state
Definition
YMO_ENUM8_TYPEDEF(ymo_mqtt_state) {
    YMO_MQTT_STATE_CONNECTING,
    YMO_MQTT_STATE_AWAITING_AUTHENTICATION,
    YMO_MQTT_STATE_CONNECTED,
    YMO_MQTT_STATE_DISCONNECTING,
    YMO_MQTT_STATE_DISCONNECTED
} YMO_ENUM8_AS(ymo_mqtt_state_t);

MQTT Control Packet Type

See http://docs.oasis-open.org/mqtt/mqtt/v3.1.1/os/mqtt-v3.1.1-os.html#_Toc398718021 for more info.

YMO_MQTT_CONNECT
Definition
#define YMO_MQTT_CONNECT        0x10
YMO_MQTT_CONNACK
Definition
#define YMO_MQTT_CONNACK        0x20
YMO_MQTT_PUBLISH
Definition
#define YMO_MQTT_PUBLISH        0x30
YMO_MQTT_PUBACK
Definition
#define YMO_MQTT_PUBACK         0x40
YMO_MQTT_PUBREC
Definition
#define YMO_MQTT_PUBREC         0x50
YMO_MQTT_PUBREL
Definition
#define YMO_MQTT_PUBREL         0x60
YMO_MQTT_PUBCOMP
Definition
#define YMO_MQTT_PUBCOMP        0x70
YMO_MQTT_SUBSCRIBE
Definition
#define YMO_MQTT_SUBSCRIBE      0x80
YMO_MQTT_SUBACK
Definition
#define YMO_MQTT_SUBACK         0x90
YMO_MQTT_UNSUBSCRIBE
Definition
#define YMO_MQTT_UNSUBSCRIBE    0xA0
YMO_MQTT_UNSUBACK
Definition
#define YMO_MQTT_UNSUBACK       0xB0
YMO_MQTT_PINGREQ
Definition
#define YMO_MQTT_PINGREQ        0xC0
YMO_MQTT_PINGRESP
Definition
#define YMO_MQTT_PINGRESP       0xD0
YMO_MQTT_DISCONNECT
Definition
#define YMO_MQTT_DISCONNECT     0xE0

MQTT Protocol Management

ymo_proto_t *ymo_proto_mqtt_create(void)