Gx3756SerialOutGetDataBitsPulseWidth

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

Gx3756SerialOutGetDataBitsPulseWidth (nHandle, pdwLogicHighPulseWidth, pdwLogicLowPulseWidth, pnStatus)

Parameters

Name
Type
Comments
nHandle
SHORT
Handle to a GX3756 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 Gx3756SerialOutSetBitRate() 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-3 (Group 0) can be programmed to operate as serial-out transmitter or as Static I/O, see Gx3756SerialOutSetMode() API for more details. When any of Channels 0-3 (Group 0) are set to Serial Out, all 4 channels direction is set to output.

Channels 3-7 (Group 1) can be programmed as an external trigger source to channels 0-3 (Group 0), when they are set to serial-out operation mode. See Gx3756SerialOutSetMode(), and Gx3756SerialOutGetTriggerSource() APIs for more details.

Example

See the Gx3756SerialOutGetStatus () 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;

 

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

 

See Also

Gx3756SerialOutReset, Gx3756SerialOutSetArmState, Gx3756SerialOutSetBitRate, Gx3756SerialOutSetData, Gx3756SerialOutSetDataBitsPulseWidth, Gx3756SerialOutSetTriggerSource, Gx3756SerialOutSetMode,

Gx3756SerialOutSetNumOfDataBits, Gx3756SerialOutSetShiftMode, Gx3756SerialOutSetTriggerDelay, Gx3756SerialOutSetTriggerSource, Gx3756SerialOutTrig, GxFpgaGetErrorString