1
0
mirror of https://github.com/DCC-EX/CommandStation-EX.git synced 2024-11-26 09:36:13 +01:00

loop over WiThrottle so that broadcast commands get into outbound ring and get sent

This commit is contained in:
Harald Barth 2022-08-06 00:34:35 +02:00
parent 7551c2d2f6
commit 012d427c6e
2 changed files with 6 additions and 0 deletions

View File

@ -26,6 +26,7 @@
#include "EthernetInterface.h"
#include "DIAG.h"
#include "CommandDistributor.h"
#include "WiThrottle.h"
#include "DCCTimer.h"
EthernetInterface * EthernetInterface::singleton=NULL;
@ -178,6 +179,8 @@ void EthernetInterface::loop()
if (Diag::ETHERNET) DIAG(F("Ethernet: disconnect %d "), socket);
}
}
WiThrottle::loop(outboundRing);
// handle at most 1 outbound transmission
int socketOut=outboundRing->read();

View File

@ -26,6 +26,7 @@
#include "DIAG.h"
#include "RingStream.h"
#include "CommandDistributor.h"
#include "WiThrottle.h"
/*
#include "soc/rtc_wdt.h"
#include "esp_task_wdt.h"
@ -228,6 +229,8 @@ void WifiESP::loop() {
}
} // all clients
WiThrottle::loop(outboundRing);
// something to write out?
clientId=outboundRing->peek();
if (clientId >= 0) {