The Internet Event
If a socket has been marked for asynchronous operation using Socket_Ioctl the TCP/IP stack will raise a RISC OS event (event 19) when important changes occur which affect the socket. When the event occurs, registers will be set as follows:
R0 = 19
R1 = Event code
R2 = Socket descriptor
Where the socket descriptor is the socket affected by the event, and the event code is on of the following values:
1 Socket has input waiting to be read
2 An urgent event has occured (eg arrival of OOB data )
3 Socket's connection has been broken
This event can be trapped and used to know when to read data from the socket, and when a connection has been closed.
|
|
|