Espressif ESP32-S2 Programming Manual page 527

Table of Contents

Advertisement

Chapter 2. API Reference
esp_mqtt_transport_t
overrides URI transport
int refresh_connection_after_ms
Refresh connection after this value (in milliseconds)
const struct
psk_key_hint
Pointer to PSK struct defined in esp_tls.h to enable PSK authentication (as alternative to certificate veri-
fication). If not NULL and server/client certificates are NULL, PSK is enabled
bool use_global_ca_store
Use a global ca_store for all the connections in which this bool is set.
esp_err_t
(*crt_bundle_attach)(void *conf)
Pointer to ESP x509 Certificate Bundle attach function for the usage of certification bundles in mqtts
int reconnect_timeout_ms
Reconnect to the broker after this value in miliseconds if auto reconnect is not disabled (defaults to 10s)
const char **alpn_protos
NULL-terminated list of supported application protocols to be used for ALPN
const char *clientkey_password
Client key decryption password string
int clientkey_password_len
String length of the password pointed to by clientkey_password
esp_mqtt_protocol_ver_t
MQTT protocol version used for connection, defaults to value from menuconfig
int out_buffer_size
size of MQTT output buffer. If not defined, both output and input buffers have the same size defined as
buffer_size
bool skip_cert_common_name_check
Skip any validation of server certificate CN field, this reduces the security of TLS and makes the mqtt
client susceptible to MITM attacks
bool use_secure_element
enable secure element for enabling SSL connection
void *ds_data
carrier of handle for digital signature parameters
int network_timeout_ms
Abort network operation if it is not completed after this value, in milliseconds (defaults to 10s)
bool disable_keepalive
Set disable_keepalive=true to turn off keep-alive mechanism, false by default (keepalive is active by
default). Note: setting the config value keepalive to 0 doesn't disable keepalive feature, but uses a
default keepalive period
const char *path
Path in the URI
int message_retransmit_timeout
timeout for retansmit of failded packet
Macros
MQTT_ERROR_TYPE_ESP_TLS
MQTT_ERROR_TYPE_TCP_TRANSPORT error type hold all sorts of transport layer errors, including ESP-
TLS error, but in the past only the errors from MQTT_ERROR_TYPE_ESP_TLS layer were reported, so the
ESP-TLS error type is re-defined here for backward compatibility
Espressif Systems
transport
*psk_hint_key
protocol_ver
Submit Document Feedback
516
Release v4.4

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the ESP32-S2 and is the answer not in the manual?

Table of Contents

Save PDF