DLN_CLOSE_ALL_HANDLES
DLN_CLOSE_ALL_HANDLES Command
The DLN_CLOSE_HANDLE command closes all handles to opened DLN-series adapters (stream).
typedef struct
{
DLN_MSG_HEADER header;
} __PACKED_ATTR DLN_CLOSE_ALL_HANDLES_CMD;
Parameters:
- header
Defines the DLN message header DLN_MSG_HEADER. The header contains several predefined fields and is used to identify and route messages. When sending the command, a user must fill the following fields:
- size - The size of the message. Must be equal to the size of the DLN_CLOSE_ALL_HANDLES_CMD structure.
- msgId - Defines the message. For the DLN_CLOSE_ALL_HANDLES command it must be set to 0x0024. You can use the DLN_MSG_ID_CLOSE_ALL_HANDLES constant.
- echoCounter - Can be used to link a command to a response. The response to the command will have the same echoCounter value. This field can be any numerical value from 0 to 0xFFFF (65536).
- handle - A handle to the DLN-series adapter. For the DLN_CLOSE_ALL_HANDLES command the HDLN_ALL_DEVICES value must be used.
DLN_CLOSE_ALL_HANDLE Response
The adapter sends the DLN_CLOSE_ALL_HANDLES response after the command execution. The result field informs a user if all connections were successfully closed.
typedef struct
{
DLN_MSG_HEADER header;
DLN_RESULT result;
} __PACKED_ATTR DLN_CLOSE_ALL_HANDLES_RSP;
Parameters:
- header
Defines the DLN message header DLN_MSG_HEADER. The response header contains the following fields:
- size - The size of the message. It is equal to the size of the DLN_CLOSE_ALL_HANDLES_RSP structure.
- msgId - Defines the message. For the DLN_CLOSE_ALL_HANDLES response it is set to 0x0024. The DLN_MSG_ID_CLOSE_ALL_HANDLES constant can be used.
- echoCounter - Links a command to a response. The echoCounter value is copied from the respective command header.
- handle - A handle to the DLN-series adapter. For the DLN_CLOSE_ALL_HANDLES response the HDLN_ALL_DEVICES value is used.
- result
Contains the result of the command execution. The following values are available:
- DLN_RES_SUCCESS - the handles to all devices were successfully closed.
2006-2012