SetSIO
Top  Previous  Next

Description

Sets the configuration of serial input/output (SIO).


Syntax


[VB]
objActiveDcam.SetPIO [Settings]


[C/C++]
HRESULT SetPIO([bstr* Setting ]);


Data Types
[VB]

Settings: String (optional)
Return value: Integer


Parameters
[C/C++]

Settings [in]  
String specifying the serial device's baud rate, parity, data bit, and stop bit attributes. It is composed of four settings and has the following format: "BBBB,P,D,S", where BBBB is the baud rate, P is the parity, D is the number of data bits, and S is the number of stop bits. If this parameter is an empty string or omitted, the following settings will be used: "9600, N, 8, 1".  


Return Values

S_OK  
Success  
E_FAIL  
Failure.  
E_INVALIDARG  
Invalid input arguments.  


Example


The following VB example opens the serial port on the board, writes a command to it and closes the port.

ActiveDcam1.SetPIO 0,"9600,N,8,1"
ActiveDcam1.SerialWrite "ssf 10000\n",1000
 

Remarks


This method is available only for cameras that have the SIO feature compliant with DCAM 1.31 specifications.

The valid baud rates are: 300, 600, 1200, 2400, 4800, 9600, 19200, 38400, 57600, 115200, 230400.
The valid parity values are: E (Even), N (None), O (Odd).    
The valid data bit values are: 7, 8
The valid stop bit values are: 1, 1.5, 2