Gx3722ArbReadWaveform

Purpose

Returns the Arb memory specified waveform values to an array.

Syntax

Gx3722ArbReadWaveform (nHandle, nChannel, pvWaveform, pdwWaveformSize, pnStatus)

Parameters

Name
Type
Comments
nHandle
SHORT
Handle to a GX3722 board.
nChannel
SHORT
Channel number:
1.      GX3722_ARB_CH1: Arb channel 1.
2.    GX3722_ARB_CH2: Arb channel 2.
pvWaveform  
PVOID
Buffer to hold the waveform array of Doubles.   
pdwWaveformSize  
PWORD
When calling this function, it should hold the number of elements in pvWaveform. On return, the function will return the actual number of elements copied to the array.
pnStatus
PSHORT
Returned status: 0 on success, negative number on failure.

Comments

Arbitrary Waveform memory cannot not be written to and read from at the same time.  Calling this function will stop any Arb playback in progress, similar to a call to Gx3722ArbStop() API.

Example

The following example writes the waveform for Arb channel 1:

 

SHORT  nStatus;

DOUBLE adWave[]={1.0, 2.0, 3.0, 4.0};

DWORD  dwSize=4;

 

Gx3722ArbWriteWaveform(nHandle, GX3722_ARB_CH1, adWave, dwSize, &nStatus);

Gx3722ArbReadWaveform(nHandle, GX3722_ARB_CH1, adWave, &dwSize, &nStatus);

 

See Also

Gx3722ArbWriteStatic, Gx3722ArbWriteWaveform, Gx3722ArbStart, Gx3722ArbStop, Gx3722ArbLoadWaveform, Gx3722ArbPulseWaveform, Gx3722ArbSetMode, GxFpgaGetErrorString