GX1110, GX1120
Arbitrary Waveform Generator mode only.
Load the specified file to the board.
GtWaveArbFileLoad (nHandle, nChannel, szFileName, dwFileStart, dwStartAddress, pdwSize, pnStatus)
Name |
Type |
Comments |
nHandle |
SHORT |
Handle to a GX11X0 board. |
nChannel |
SHORT |
Not used, pass as 0. |
szFileName |
LPCSTR |
File name. The saved data format will be determined by the file extension.The driver supports the following file formats: |
dwFileStart |
DWORD |
File start data point. GX1120: Range: 0 to 2097151. GX1120: Range: 0 to 33554431. |
dwStartAddress |
DWORD |
Board start address to fill data. |
pdwSize |
PDWORD |
Specified number of data points to load. If pdwSize=-1, then the function will load all the data from the file to the board. If there are more data points in the file than available memory, i.e. max number of steps less start address, the function returns an error without loading any data.GX1120:Range: 1 to 2097152 (GTWAVE_GX1120_ARB_WAVE_MAX_LENGTH).GX1120: Range: 1 to 33554432 (GTWAVE_GX1120_ARB_WAVE_MAX_LENGTH). |
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 values to 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 highest output amplitude and -2047 (0x800) represents 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 highest output amplitude and 0x8000 represents lowest output amplitude.
The following example loads the “WaveEasy1.WaveEasy” file to the board starting at step 0 in the file, step 0 at the board and all available data in the file:
DWORD dwSize=-1;
GtWaveArbFileLoad(nHandle, GTWAVE_CHANNEL_A, “WaveEasy1.WaveEasy”, 0, 0, &dwSize, &nStatus);
GtWaveArbFileSave, GtWaveArbSetMarker, GtWaveArbSetSampleRate, GtWaveArbSetWaveformLength, GtWaveArbSetSync, GtWaveArbFillPredefinedWaveform, GtWaveArbReadWaveformData, GtWaveArbWriteWaveformData