Gx3748MeasureGetLastTriggeredData

Purpose

Returns the last triggered data using one of the PXI Trigger Bus lines.

Syntax

Gx3748MeasureGetLastTriggeredData (nHandle, nGroup, nChannel, pdMeasurement, pnStatus)

Parameters

Name
Type
Comments
nHandle
SHORT
Handle for a GX3748 board.
nGroup
SHORT
Group number as follows:
0.      GX3748_GROUP0: J1 input connector pins 2 to 17.
1.      GX3748_GROUP1: J1 input connector pins 23 to 38.
2.    GX3748_GROUP2: J1 input connector pins 44 to 59
pdMeasurement
PDOUBLE
Returns the last triggered data using one of the PXI Trigger Bus lines.  
pnStatus
PSHORT
Returned status: 0 on success, negative number on failure.

Comments

The function returns the last triggered data using one of the PXI Trigger Bus lines, as it was defined by the Gx3748MeasureSetTriggerSource() API.

The user can call Gx3748MeasureGetStatus() API to check when the is a new measurement.

Example

The following example sets the measurement unit 3 channels, one form each group, and takes measurements using PXI Trigger Bus line 0:

 

SHORT nHandle, nStatus;

DOUBLE dMeasurement;

 

// Set channel 0 from group 0

Gx3748MeasureSetInputSource(nHandle, GX3748_GROUP0, GX3748_GROUP_CH0, &nStatus);

// Set channel 1 from group 1

Gx3748MeasureSetInputSource(nHandle, GX3748_GROUP1, GX3748_GROUP_CH1, &nStatus);

// Set channel 2 from group 2

Gx3748MeasureSetInputSource(nHandle, GX3748_GROUP2, GX3748_GROUP_CH2, &nStatus);

// Set PXI Trigger Bus line  0

Gx3748MeasureSetTriggerSource(nHandle, GX3748_CALCULATE_TRIGGER_PXI_TRIGGER_0, &nStatus);

// Read back the measurement

Gx3748MeasureGetLastTriggeredData(nHandle, GX3748_GROUP0, &dMeasurement, &nStatus);

Gx3748MeasureGetLastTriggeredData(nHandle, GX3748_GROUP1, &dMeasurement, &nStatus);

Gx3748MeasureGetLastTriggeredData(nHandle, GX3748_GROUP2, &dMeasurement, &nStatus);

 

See Also

Gx3748MeasureSetInputSource, Gx3748MeasureSetTriggerSource, Gx3748Measure, Gx3748MeasureGetStatus, GxFpgaGetErrorString