Programming Examples
VX4792 User Manual
2-45
Transferring Waveforms
This procedure describes the general approach for transferring waveform data
from a controller to the waveform generator. The procedure assumes that a
waveform file already exists in the computer memory.
1. Specify the file name where the waveform data will be stored within the
waveform generator memory with the following command:
(+%0(,+ /%*-)&1'*
where 2/%*-)&1'* is the filename where the data will be stored. The
filename must have the appropriate extension (1'*).
2. Specify output parameters such as the number of points, output voltage, and
clock frequency, using the .& command. Select the parameters that
apply to your application.
The following example is the complete form of the .& command.
Subcommands that have no argument have been omitted.
$ "$ "$ $
$ "$ !# ! " "
$ " "# ! 3
This example selects the following output parameters:
H Number of points: 512 (see $)
H Amplitude: 5 volts (see " )
H Offset: 2 volts (see "# )
H Clock frequency: 1 MHz (see ! 3)
3. Transfer the waveform data with the & command, followed by the
waveform block data, as shown in the following example:
The block data requires a header string that defines the data length. The data
length is a calculated value based on the number of data bytes. Each
waveform point consists of 12 bits (two bytes). For the 512-point waveform
used in this example, the & command consists of the following:
H The left-most “4” represents the number of digits in the byte count field
H The “1024” represents the number of bytes; this is the byte count field
H The following information (“.....”) is an array of binary data
See page 3–27 for additional details about the & command syntax.