Does RTCS_select Implement Write-ability Activity Check?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Does RTCS_select Implement Write-ability Activity Check?

650 Views
pmt
Contributor V

The RTCS documentation concerning RTCS_select/RTCS_selectall seems a little out of date, and in browsing the code it's not clear to me what is fully implemented. 

My question is does RTCS_Select, in addition to connection activity, errors, and data ready to read, also test for write_set?  That is will it unblock when a socket buffer is available to take more data on a write?  This is needed for handlers that need to both read and write data on a socket within a single tasks.

Thanks,

PMT

Labels (1)
0 Kudos
2 Replies

338 Views
Martin_
NXP Employee
NXP Employee

RTCS_selectset() returns also when a send buffer for a stream socket becomes available (writeable) after acknowledge is received. I recommend RTCS_selectset() as RTCS_selectall() has a bug (it will be fixed in next MQX).

By the way, next year we will introduce also select on independent socket sets for read/write, BSD-like select() function.

0 Kudos

338 Views
danieldelatorre
Contributor IV

So it has been over a year, is this ever going to be implemented?  I have had to hack mqx rtos code to have a select-like function for unblocking on uart reads.  I had to do this on 2 different products and would be nice if I didn't have to include this hack when I update to the latest MQX rtos.  At the moment I have a tcp server thread that I would like to have close sockets when the child socket thread gets a disconnection event although I can't seem to find a way to unblock the server thread when it is stuck on RTCS_selectset.  I could use the timeout on the rtcs_select although I don't want it to have to poll... 

0 Kudos