Hi
The TCP protocol is not aware of the link status and will still try to transmit. Of course after a few repeats the connection will be closed.
When the link state changes, there is an event generated:
- define INTERRUPT_TASK_PHY to be the name of the task wich you would like to receive the event
- 3 Interrupt events will then be sent to this task (LAN_LINK_DOWN, LAN_LINK_UP_100 and LAN_LINK_UP_10)
In th edemo project this is optionally sent to TASK_NETWORK_INDICATOR and used to control the link LED (LED colour set to indicate link up with a specific speed).
By retaining a variable which is changed depending on these events you will always have a reference to the link's state and so it will not be necessary to poll. When the link goes down (LAN_LINK_DOWN) you can immediately undertake your active connection close.
Regards
Mark