128
SetCommState
int SetCommState(lpdcb)
const DCB FAR * lpdcb;
/* Address of the device control block */
The SetCommState function will set the communication device to the state that is specified by the
device control block.
< Parameter >
lpdcb: Pointer to the DCB structure that stores the communication settings for the device.
Specify the device name for the Id member of the DCB structure.
< Return value >
Returns zero if the function is terminated normally. Otherwise it returns a value less than zero.
Note:
This function will re-initialize all the control items defined by the DCB structure, but will not clear
the transmission and reception queues.
Note on IrDA:
Some of the control items defined by the DCB structure are not supported at present. Some of the
supported functions will operate only if the 9-Wire connection is established or if both the 9-Wire
and 3-Wire connections are established. If at attempt is made to define the functions not supported,
the SetCommState function will be terminated normally. For information about the DCB structure
refer to the next page.