This member of RFAuxPort Object is supported on Windows Mobile, Windows CE, Palm, and DOS.
The ConfigurePort method allows you to configure the basic UART settings for a RF device’s serial port before calling the QueryPort method.
VB
bStatus = object.ConfigurePort (nPort, nBaud, nDataBits, nStopBits, nParity, nFlowControl)
VC++
HRESULT hr = object->ConfigurePort(short nPort, short nBaud, short nDataBits, short nStopBits, short nParity, short nFlowControl, BOOL *bStatus);
Return Value
bStatus |
The status of the function returned as Boolean True or False values. Use the RFGetLastError method to return any error value. |
Parameters
nPort |
The serial port of the RF device which UART settings you wish to configure (WLCOM1 or WLCOM2). The possible values for nPort are: WLCOM1 - Com port 1 WLCOM2 - Com port 2 |
nBaud |
The UART Baud rate of the serial port. The possible values for nBaud are: BAUD150 - 150 BBS Baud BAUD300 - 300 BBS Baud BAUD600 - 600 BBS Baud BAUD1200 - 1200 BBS Baud BAUD1350 - 1350 BBS Baud BAUD2400 - 2400 BBS Baud BAUD4800 - 4800 BBS Baud BAUD9600 - 9600 BBS Baud BAUD19200 - 19200 BBS Baud BAUD38400 - 38400 BBS Baud BAUD110000 - 110000 BBS Baud |
nDataBits |
The UART data bit setting of the serial port. The possible values for nDataBits are: DATABITS5 - 5 data bits DATABITS6 - 6 data bits DATABITS7 - 7 data bits DATABITS8 - 8 data bits DATABITS4 - 4 data bits |
nStopBits |
The UART stop bit setting of the serial port (STOPBITS1 or STOPBITS2). The possible values for nStopBits are: STOPBITS1 - 1 stop bit STOPBITS2 - 2 stop bits |
nParity |
The UART parity setting of the serial port. The possible values for nParity are: PARITYEVEN - Even parity PARITYODD - Odd parity PARITYMARK - Mark parity PARITYSPACE - Space parity PARITYNONE - No parity |
nFlowControl |
The UART flow control setting of the serial port. The possible values for nFlowControl are: NOFLOWCTL - No flow control SOFTWAREFLOWCTL - Software based flow control HARDWAREFLOWCTL - Hardware based flow control |
Remarks
A serial port must first be configured using the ConfigurePort method before the port may be queried for input using the QueryPort Method.
See the Constant Values for the numeric equates returned by the function.
Example
See RFAuxPort Samples.
Was this article useful?
The topic was:
Inaccurate
Incomplete
Not what I expected
Other