Share via


IOCTL_SERIAL_SET_BREAK_ON (Compact 2013)

3/26/2014

This I/O control message sets the break state. Send this message with DeviceIoControl.

Syntax

BOOL DeviceIoControl(
    HANDLE hDevice,           // handle to the device
    DWORD dwIoControlCode,    // use IOCTL_SERIAL_SET_BREAK_ON
    LPVOID lpInBuffer,        // pointer to input buffer
    DWORD nInBufferSize,      // input buffer size
    LPVOID lpOutBuffer,       // pointer to output buffer
    DWORD nOutBufferSize,     // output buffer size
    LPDWORD lpBytesReturned,  // number of bytes returned
    OVERLAPPED lpOverlapped   // pointer to OVERLAPPED structure
);

Parameters

  • hDevice
    [in] Handle to the device. To obtain a device handle, call COM_Open.
  • dwIoControlCode
    [in] The control code for the operation. Use IOCTL_SERIAL_SET_BREAK_ON for this operation.
  • lpInBuffer
    Ignored.
  • nInBufferSize
    Ignored.
  • lpOutBuffer
    Ignored.
  • nOutBufferSize
    Ignored.
  • lpBytesReturned
    Ignored.
  • lpOverlapped
    Ignored.

Return Values

Returns TRUE if successful; otherwise, returns FALSE.

Remarks

To get extended error information, call GetLastError. GetLastError may return other standard error messages as appropriate.

Remarks

This IOCTL sets the transmission line to a break state until IOCTL_SERIAL_SET_BREAK_OFF executes.

Requirements

Header

pegdser.h

See Also

Reference

Serial Port Driver IOCTLs
COM_IOControl
COM_Open
DeviceIoControl
IOCTL_SERIAL_SET_BREAK_OFF