mirror of
https://github.com/meshtastic/firmware.git
synced 2025-04-25 09:42:35 +00:00
Merge pull request #1052 from mc-hamster/StoreAndForward
S&F - Only TX if utilization is below 25%
This commit is contained in:
commit
dd464896ae
@ -27,8 +27,8 @@ int32_t StoreForwardPlugin::runOnce()
|
|||||||
if (this->busy) {
|
if (this->busy) {
|
||||||
|
|
||||||
|
|
||||||
// Only send packets if the channel is less than 50% utilized.
|
// Only send packets if the channel is less than 25% utilized.
|
||||||
if (airTime->channelUtilizationPercent() < 50) {
|
if (airTime->channelUtilizationPercent() < 25) {
|
||||||
|
|
||||||
// DEBUG_MSG("--- --- --- In busy loop 1 %d\n", this->packetHistoryTXQueue_index);
|
// DEBUG_MSG("--- --- --- In busy loop 1 %d\n", this->packetHistoryTXQueue_index);
|
||||||
storeForwardPlugin->sendPayload(this->busyTo, this->packetHistoryTXQueue_index);
|
storeForwardPlugin->sendPayload(this->busyTo, this->packetHistoryTXQueue_index);
|
||||||
@ -424,9 +424,6 @@ StoreForwardPlugin::StoreForwardPlugin()
|
|||||||
// Popupate PSRAM with our data structures.
|
// Popupate PSRAM with our data structures.
|
||||||
this->populatePSRAM();
|
this->populatePSRAM();
|
||||||
|
|
||||||
// this->packetTimeMax = 2000;
|
|
||||||
// DEBUG_MSG("SF Time to Transmit maxPacketSize (%d bytes) %d ms\n", maxPacketSize, this->packetTimeMax);
|
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
DEBUG_MSG("Device has less than 1M of PSRAM free. Aborting startup.\n");
|
DEBUG_MSG("Device has less than 1M of PSRAM free. Aborting startup.\n");
|
||||||
DEBUG_MSG("Store & Forward Plugin - Aborting Startup.\n");
|
DEBUG_MSG("Store & Forward Plugin - Aborting Startup.\n");
|
||||||
|
Loading…
Reference in New Issue
Block a user