diff --git a/EthernetInterface.cpp b/EthernetInterface.cpp index f691f45..48f9002 100644 --- a/EthernetInterface.cpp +++ b/EthernetInterface.cpp @@ -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(); diff --git a/WifiESP32.cpp b/WifiESP32.cpp index 3be3827..22a02ca 100644 --- a/WifiESP32.cpp +++ b/WifiESP32.cpp @@ -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) {