Skip to content

Commit

Permalink
better fix for publishing large messages
Browse files Browse the repository at this point in the history
  • Loading branch information
technyon committed Jun 12, 2022
1 parent 0e44c34 commit 7008cd6
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 6 deletions.
6 changes: 2 additions & 4 deletions Network.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,7 @@ void Network::initialize()
Serial.print(F(":"));
Serial.println(port);
_mqttClient.setServer(_mqttBrokerAddr, port);
_mqttClient.setBufferSize(16384);
}


Expand Down Expand Up @@ -219,11 +220,8 @@ void Network::publishString(const char *topic, const char *value)
{
char path[200] = {0};
buildMqttPath(topic, path);
// Serial.println(path);
// Serial.println(_presenceCsv);

// _mqttClient.publish(path, value);
_mqttClient.publish_P(path, value, true);
_mqttClient.publish(path, value, true);
}


Expand Down
2 changes: 1 addition & 1 deletion Version.h
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
#pragma once

#define blescanner_hub_version "1.3"
#define blescanner_hub_version "1.4"
2 changes: 1 addition & 1 deletion main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ void setupTasks()
{
// configMAX_PRIORITIES is 25

xTaskCreatePinnedToCore(networkTask, "ntw", 32768, nullptr, 3, nullptr, 1);
xTaskCreatePinnedToCore(networkTask, "ntw", 65536, nullptr, 3, nullptr, 1);
xTaskCreatePinnedToCore(presenceDetectionTask, "prdet", 16384, nullptr, 5, nullptr, 1);
xTaskCreatePinnedToCore(bleScannerTask, "blescan", 16384, nullptr, 1, nullptr, 1);
xTaskCreatePinnedToCore(checkMillisTask, "millis", 512, nullptr, 1, nullptr, 1);
Expand Down

0 comments on commit 7008cd6

Please sign in to comment.