Merge pull request #14256 from s-hadinger/apply_mqtt_max_packet

Force `MQTT_MAX_PACKET_SIZE` in PubSub client
This commit is contained in:
s-hadinger 2022-01-03 19:15:22 +01:00 committed by GitHub
commit 2afa88a78b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -188,6 +188,9 @@ void MqttDisableLogging(bool state) {
PubSubClient MqttClient;
void MqttInit(void) {
// Force buffer size since the #define may not be visible from Arduino lib
MqttClient.setBufferSize(MQTT_MAX_PACKET_SIZE);
#ifdef USE_MQTT_AZURE_IOT
Settings->mqtt_port = 8883;
#endif //USE_MQTT_AZURE_IOT