GX1110, GX1120
Arbitrary Waveform Generator mode only.
Read an array of data from the board’s waveform memory.
GtWaveArbReadWaveformData (nHandle, nChannel, dwStartAddress, dwSize, pnData, pnStatus)
Name |
Type |
Comments |
nHandle |
SHORT |
Handle to a GX11X0 board. |
nChannel |
SHORT |
Not used, pass as 0. |
dwStartAddress |
DWORD |
GX1120: Waveform start address, any even value between 0 and 2097151.GX1120: Waveform start address, any even value between 0 and 33554431. |
dwSize |
DWORD |
GX1120: Any value between 1 and 2097152.GX1120: Any value between 1 and 33554432. |
pnData |
DWORD |
Pointer to an array containing waveform data |
pnStatus |
PSHORT |
Returned status: 0 on success, negative number on failure. |
GX1120:
Since there is only one channel, there is no meaning to the channel number.
When calling this function, the function will cast all the array values to a 12-bit wide value and will clear all Marker and Sync bits previously set at the specified memory range.
Data point value of 2047 (0x7FF) represents the highest output amplitude and -2047 (0x800) represents the lowest output amplitude.
The following equation represents the relative output amplitude voltage:
Output voltage = amplitude setting (peak-to-peak)* (data point value)/4096+ offset
GX1120:
Since the memory is shared by both channels, there is no meaning to the channel number.
Data point value of 0x7FFF represents the highest output amplitude and 0x8000 represents the lowest output amplitude.
The following example reads an array of 4096 data points from the board’s waveform memory stating at address 0:
GtWaveArbReadWaveformData (nHandle, GTWAVE_CHANNEL_A, 0, 4096, pnData, &nStatus);
GtWaveArbWriteWaveformData, GtWaveArbSetMarker, GtWaveArbSetSampleRate, GtWaveArbSetWaveformLength, GtWaveArbSetSync, GtWaveArbFillPredefinedWaveform, GtWaveArbClearWaveformMemory, GtWaveArbFileLoad, GtWaveArbFileSave