Disconnected ethernet cable

Is there a method to identify if cable ethernet is disconnected? I have implemented a socket server that waits data from a client (using NS7520 with NetOS 6.0). When I disconnect the cable, server remains blocked by the recv function that doesn’t return. Thanks!!

Hi Cristiano, you have to read the status register from your PHY. A PHY has normally a register which contains this information. We are using the PHY from Intel (LX971A) . For this IC you can find the information in register 17.10 (Link is up/down). Kind regards Alex

Thank you very much!!!