mirror of
https://github.com/DCC-EX/CommandStation-EX.git
synced 2024-12-23 12:51:24 +01:00
ESP32 do not recycle client handles for now
This commit is contained in:
parent
caca265529
commit
5182bb171d
@ -76,7 +76,14 @@ public:
|
|||||||
return (inUse && wifi.connected());
|
return (inUse && wifi.connected());
|
||||||
};
|
};
|
||||||
bool recycle(WiFiClient c) {
|
bool recycle(WiFiClient c) {
|
||||||
|
|
||||||
if (inUse == true) return false;
|
if (inUse == true) return false;
|
||||||
|
|
||||||
|
// return false here until we have
|
||||||
|
// implemented a LRU timer
|
||||||
|
// if (LRU too recent) return false;
|
||||||
|
return false;
|
||||||
|
|
||||||
wifi = c;
|
wifi = c;
|
||||||
inUse = true;
|
inUse = true;
|
||||||
return true;
|
return true;
|
||||||
@ -111,9 +118,9 @@ bool WifiESP::setup(const char *SSid,
|
|||||||
// disableCoreWDT(0);
|
// disableCoreWDT(0);
|
||||||
|
|
||||||
// clean start
|
// clean start
|
||||||
|
WiFi.mode(WIFI_STA);
|
||||||
WiFi.disconnect(true);
|
WiFi.disconnect(true);
|
||||||
//WiFi.useStaticBuffers(true);
|
//WiFi.useStaticBuffers(true); // does not help either
|
||||||
//WiFi.setTxPower(WIFI_POWER_8_5dBm);
|
|
||||||
|
|
||||||
const char *yourNetwork = "Your network ";
|
const char *yourNetwork = "Your network ";
|
||||||
if (strncmp(yourNetwork, SSid, 13) == 0 || strncmp("", SSid, 13) == 0)
|
if (strncmp(yourNetwork, SSid, 13) == 0 || strncmp("", SSid, 13) == 0)
|
||||||
|
Loading…
Reference in New Issue
Block a user