Files
aqhomecontrol/aqhome/mqtt/msg_mqtt_connack.h
2023-03-29 00:42:49 +02:00

42 lines
1.1 KiB
C

/****************************************************************************
* This file is part of the project AqHome.
* AqHome (c) by 2023 Martin Preuss, all rights reserved.
*
* The license for this file can be found in the file COPYING which you
* should have received along with this file.
****************************************************************************/
#ifndef AQH_MSG_MQTT_CONNACK_H
#define AQH_MSG_MQTT_CONNACK_H
#include <aqhome/api.h>
#include <aqhome/mqtt/msg_mqtt.h>
#include <gwenhywfar/msg.h>
#include <gwenhywfar/buffer.h>
#define AQH_MQTTMSG_CONNACK_FLAGS_HAVE_SESSION 0x01u
#define AQH_MQTTMSG_CONNACK_RESULT_ACCEPTED 0x00u
#define AQH_MQTTMSG_CONNACK_RESULT_BAD_PROTO 0x01u
#define AQH_MQTTMSG_CONNACK_RESULT_BAD_CLIENTID 0x02u
#define AQH_MQTTMSG_CONNACK_RESULT_UNAVAILABLE 0x03u
#define AQH_MQTTMSG_CONNACK_RESULT_BAD_CREDENTIALS 0x04u
#define AQH_MQTTMSG_CONNACK_RESULT_UNAUTHORIZED 0x05u
AQHOME_API GWEN_MSG *GWEN_ConnAckMqttMsg_new(uint8_t flags, uint8_t result);
AQHOME_API void AQH_ConnAckMqttMsg_DumpToBuffer(const GWEN_MSG *msg, GWEN_BUFFER *dbuf, const char *sText);
#endif