diff --git a/docs/reference/api/connectivity/networksocket/EthInterface.md b/docs/reference/api/connectivity/networksocket/EthInterface.md index b5547d114a..9a19b0aa07 100644 --- a/docs/reference/api/connectivity/networksocket/EthInterface.md +++ b/docs/reference/api/connectivity/networksocket/EthInterface.md @@ -15,12 +15,16 @@ To bring up the network interface: 1. Once you connect the EthInterface, you can use it as a target for opening [network sockets](/docs/v5.7/reference/network-socket.html). -### EthInterface example +### EthInterface examples Here is an example of an HTTP client program. The program brings up Ethernet as the underlying network interface and uses it to perform an HTTP transaction over a TCPSocket: [![View code](https://www.mbed.com/embed/?url=https://os.mbed.com/teams/mbed_example/code/TCPSocket_Example/)](https://os.mbed.com/teams/mbed_example/code/TCPSocket_Example/file/6b383744246e/main.cpp) +Here is an example showing how to register a status callback that gets triggered when connection state changes. This also works with other network interfaces if support is provided. + +[![View code](https://www.mbed.com/embed/?url=https://os.mbed.com/teams/mbed_example/code/TCPSocket_ConnStateCb_Example/)](https://os.mbed.com/teams/mbed_example/code/TCPSocket_ConnStateCb_Example/file/987d54985478/main.cpp/) + ### Related content - [Network socket](/docs/v5.7/reference/network-socket.html) API reference overview.