User`s manual
Software Manual • EKF Intelligent I/O Controller Family On
CompactPCI
- 32 -
EKF Elektronik GmbH * Philipp-Reis-Str. 4 * D-59065 HAMM (Germany)
Tel. +49 (0)2381/6890-0 * Fax. +49 (0)2381/6890-90 * E-Mail info@ekf.de * Internet http://www.ekf.de
Get Port Baud Rate: IOCTL_SERIAL_GET_BAUD_RATE
This I/O control request returns the baud rate that is currently set on a serial or CANbus port.
Call: DeviceIoControl(
handle, // handle returned by
CreateFile
IOCTL_SERIAL_GET_BAUD_RATE,
NULL,
0,
pBaudStruct, // pointer to a SERIAL_BAUD_RATE structure
1
)
sizeof(*pBaudStruct),
&unused, // pointer to a DWORD variable
pOverlapped // optional pointer to overlapped buffer (may be NULL)
);
Note:
1
) The baud rate value is returned in this structure. It is defined in the C header file
“ntddekf.h” delivered with the driver installation package.
An alternative way to get the current baud rate is to use the C function
Ekf960GetBaudRate
coming with the library “ekf960si1.lib”. See also the source file of
Ekf960GetBaudRate
“getbaud.c” that is delivered with the driver installation package.
Get Special Characters: IOCTL_SERIAL_GET_CHARS
This I/O control request returns the special characters (e.g. XON and XOFF characters) that
are currently set on a serial port.
Call: DeviceIoControl(
handle, // handle returned by
CreateFile
IOCTL_SERIAL_GET_CHARS,
NULL,
0,
pChars, // pointer to a SERIAL_CHARS structure
1
)
sizeof(*pChars),
&unused, // pointer to a DWORD variable
pOverlapped // optional pointer to overlapped buffer (may be NULL)
);
Note:
1
) The special characters are returned in this structure. It is defined in the C header file
“ntddekf.h” delivered with the driver installation package. See also description in section
“
SERIAL_CHARS
”










