mirror of
https://github.com/espressif/esp-mqtt.git
synced 2025-11-08 11:02:14 +01:00
client: Add support for user events
Also supporting configurable queue size for the internal event loop. Closes https://github.com/espressif/esp-mqtt/issues/230
This commit is contained in:
@@ -9,6 +9,7 @@
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <stdatomic.h>
|
||||
#include "esp_err.h"
|
||||
#include "platform.h"
|
||||
|
||||
@@ -123,6 +124,9 @@ struct esp_mqtt_client {
|
||||
EventGroupHandle_t status_bits;
|
||||
SemaphoreHandle_t api_lock;
|
||||
TaskHandle_t task_handle;
|
||||
#if MQTT_EVENT_QUEUE_SIZE > 1
|
||||
atomic_int queued_events;
|
||||
#endif
|
||||
};
|
||||
|
||||
bool esp_mqtt_set_if_config(char const *const new_config, char **old_config);
|
||||
|
||||
Reference in New Issue
Block a user