I am currently implementing a WiFi driver integration which is supposed to handle blocking and non blocking operations.
Right now I do not understand how the Socket is notified when an API call of the NetworkStack
method i.e. socket_receivefrom
returns NSAPI_ERROR_WOULD_BLOCK
when the operation is actually done. Right now it seems that the UDPSocket x; x.receive(...);
blocks forever with my implementation, which makes sense since there is no notification between the ISR (+ msg decoding + …) received and the Socket state.
How is this done? Can anyone point me to relevant information (besides this which is not sufficient https://os.mbed.com/docs/v5.6/mbed-os-api-doxy/class_u_d_p_socket.html#a5794a2e44ed849bba30570c0b517a95f) ?