Forum Discussion
Altera_Forum
Honored Contributor
21 years agonon-blocking LWIP Ethernet Socket
Has anyone been able to setup a socket non-blocking with LWIP on uC/OS-II? I have found that the fcntl() is not supported. My application is using the socket as a control channel that I ch...
Altera_Forum
Honored Contributor
21 years agoYou are correct that there is no fcntl() for LWIP. However there is a handy ioctl which will do what you want FIONBIO.
The syntax is to set non blocking int fred = 1; ioctlsocket(your_socket,FIONBIO,&fred) Simply set fred to 0 for blocking. I've not tested this, so caveat emptor