Gx3722SerialOutGetDataBitsPulseWidth

Purpose

Returns the serial-out data bits pulse width for the logic high and logic low time in microseconds for all 4 serial-out channels.

Syntax

Gx3722SerialOutGetDataBitsPulseWidth (nHandle, pdwLogicHighPulseWidth, pdwLogicLowPulseWidth, pnStatus)

Parameters

Name
Type
Comments
nHandle
SHORT
Handle to a GX3722 board.  
pdwLogicHighPulseWidth
PDWORD
Returns the serial-out data bits pulse width for the logic high time in microseconds for all 4 serial-out channels.  
pdwLogicLowPulseWidth
PDWORD
Returns the serial-out data bits pulse width for the logic low time in microseconds for all 4 serial-out channels.  
pnStatus
PSHORT
Returned status: 0 on success, negative number on failure.

Comments

The function returns the serial-out data bits pulse width for the logic high and logic low time in microseconds for all 4 serial-out channels. Data bits pulse width for the logic high: Each bit transmitted duration is set according to the Gx3722SerialOutSetBitRate() API.

During the time that each transmitted bit with logic level set to high (‘1’), the user can program the time inside the bit rate duration of how long the logic high will stay high before it goes low. For example, if the bit rate is set to 1000uSec (1mSec):

During the time that each transmitted bit with logic level set to low (‘0’), the user can program the time inside the bit rate duration of how long the output will stay high before it goes low. For example, if the bit rate is set to 1000uSec (1mSec):

Channels 0-2 can be programmed to operate as serial-out transmitter or as Static I/O, see Gx3722SerialOutSetMode() API for more details. When any of Channels 0-2 are set to Serial-out, all 4 channels direction is set to output.

Example

See the Gx3722SerialOutGetStatus () API for complete example.

The following example returns the serial-out data bits pulse width for the logic high and logic low time in microseconds for all 4 serial-out channels:

 

SHORT nHandle, nStatus;

DWORD dwLogicHighPulseWidth, dwLogicLowPulseWidth;

 

Gx3722SerialOutGetDataBitsPulseWidth (nHandle, &dwLogicHighPulseWidth, &dwLogicLowPulseWidth, &nStatus);

 

See Also

Gx3722SerialOutReset, Gx3722SerialOutSetArmState, Gx3722SerialOutSetBitRate, Gx3722SerialOutSetData, Gx3722SerialOutSetDataBitsPulseWidth, Gx3722SerialOutGetTriggerSource, Gx3722SerialOutSetMode, Gx3722SerialOutSetNumOfDataBits, Gx3722SerialOutSetShiftMode, Gx3722SerialOutSetTriggerDelay, Gx3722SerialOutTrig, GxFpgaGetErrorString