01.06.2013 Views

IPC@CHIP Documentation - SC12 @CHIP-RTOS V1.10

IPC@CHIP Documentation - SC12 @CHIP-RTOS V1.10

IPC@CHIP Documentation - SC12 @CHIP-RTOS V1.10

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Comments<br />

Top of list<br />

Index page<br />

This function is only available in <strong>@CHIP</strong>-<strong>RTOS</strong> version which contain the SNMP MIB feature.<br />

Possible TCP socket states:<br />

0: CLOSED<br />

1: LISTEN<br />

2: SYN_SENT<br />

3: SYN_RECEIVED<br />

4: ESTABLISHED<br />

5: CLOSE_WAIT<br />

6: FIN_WAIT_1<br />

7: CLOSING<br />

8: LAST_ACK<br />

9: FIN_WAIT_2<br />

10: TIME_WAIT<br />

20: INVALID<br />

Interrupt 0xAC service 0x23: API_FINDALL_SOCKETS, Get information about all open sockets.<br />

Parameters<br />

AH<br />

ES:DI<br />

CX<br />

Find/return information about all open sockets at the internal socket table.<br />

0x23 (= API_FINDALL_SOCKETS)<br />

Output Parameter: Pointer to an array of CX SocketInfo structures in the user's memory space into which<br />

this API will report the socket information.<br />

Size of the array (maximum number of table entries reported).<br />

Return Value<br />

Comments<br />

AX holds the number of all open sockets. The user provided array at [ES:DI] holds the socket information for<br />

up to CX sockets (the lesser of two register counts: AX, CX).<br />

This function is only available in <strong>@CHIP</strong>-<strong>RTOS</strong> versions which contain the SNMP MIB feature.<br />

If CX >= AX then all sockets in the socket table have been reported.<br />

Below is an example of using API_FINDALL_SOCKETS with the FindAllOpenSockets C library wrapper<br />

function. This example lists up to 64 current entries in the TCP/IP socket table:<br />

Page 124 / 400

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!