11
PROGRAMMING
To interface with the serial ports on the Fastcom: 232/4-LPCI-335 in a Windows application, your code will use
the standard Win32 COM API. Documentation pertaining to how to use the Win32 API is beyond the scope of
this document. For more information on using the API, refer to the “Using Communications Resources” in the
MSDN.
In addition to the Win32 API, you can also use several special Fastcom specific commands that allow you to
accomplish all of the options from the
Fastcom AsyncPCI-335 Serial Settings
property page. These commands
as well as the custom structures used in them are defined in the fcapi.h header file.
Fastcom AsyncPCI-335 Serial Setting
DeviceIOControl
dwIoControlCode
Clock Generator Frequency
IOCTL_FASTCOM_SET_CLOCK
Rx Echo Cancel
IOCTL_FASTCOM_SET_RXECHO
Sampling Rate
IOCTL_FCPORT_SET_SAMPLING
Digital Output 1 & 2
IOCTL_FCPORT_SET_DIGI_OUT
Digital Input 1 & 2
IOCTL_FCPORT_GET_DIGI_IN
Tx FIFO Trigger Level
IOCTL_FCPORT_SET_RXTX_TRIG
Tx FIFO Trigger Level
IOCTL_FCPORT_SET_RXTX_TRIG
Tx Write Size
IOCTL_FCPORT_SET_RXTX_TRIG
Refer to the AsyncPCI335\examples directory on the Fastcom CD or in the downloaded zip file for some example
C programs that demonstrate how to use the Fastcom specific serial settings as well as give a general sense of
how to use the Win32 API.