A stack which works with or without an Mbed os library. Provides IPv4 or IPv6 with a full 1500 byte buffer.
Dependents: oldheating gps motorhome heating
Diff: udp/dhcp/dhcp.c
- Revision:
- 132:db2174b36a6d
- Parent:
- 128:79052cb4a41c
- Child:
- 133:a37eb35a03f1
--- a/udp/dhcp/dhcp.c Tue Mar 19 12:12:26 2019 +0000 +++ b/udp/dhcp/dhcp.c Wed Mar 20 10:55:30 2019 +0000 @@ -288,7 +288,7 @@ if (DhcpLocalIp && elapsedTimeMs < (leaseTimeMs >> 1)) return DO_NOTHING; //Do nothing if have address and within T1 //Limit retries with a backoff delay - if (!MsTimerHasElapsed(repeatDelayMsTimer, delayMs)) return DO_NOTHING; //Don't retry within the delay time + if (!MsTimerInterval(repeatDelayMsTimer, delayMs)) return DO_NOTHING; //Don't retry within the delay time delayMs <<= 1; //Backoff (double) the delay time after each attempt if (delayMs > MAX_REPEAT_DELAY_TIME_MS) delayMs = MAX_REPEAT_DELAY_TIME_MS; //Don't go beyond a maximum repeatDelayMsTimer = MsTimerCount; //Start the delay timer