In our application, we use DHCP to get an IP address. IP connectivity (via wired Ethernet) is essential for our application, so we want to know if the network is ‘up’; i.e. PHY is connected and up, and we have a valid IP address.
We have seen some corner cases in which we got IP address conflicts.
When thinking about this, my conclusion is that we should be able to detect at least the following cases:
- DHCP lease renewal has failed, e.g. because the DCHP server is down;
- IP address conflict is detected; an ARP probe after DHCP grant could be used for this, refer to https://en.wikipedia.org/wiki/Address_Resolution_Protocol#ARP_probe.
As far as I can tell, the +TCP stack does not contain a mechanism for communicating these cases to the application, e.g. via vApplicationIPNetworkEventHook().
I am wondering, do others agree and if so, could these features be added to the +TCP stack?