You can use Arbitrary Sequence mode to load multiple waveforms in the onboard memory of the signal generator.

LabVIEW Example

The procedure below provides the basic steps required to configure Arbitrary Sequence mode. For more detailed examples of the use of Arbitrary Sequence mode in LabVIEW, refer to the Fgen Basic Arb Sequence.vi or the Fgen Arbitrary Sequence.vi examples for LabVIEW.

  1. Call the niFgen Configure Output Mode VI with Output Mode set to Arbitrary Waveform.
  2. (Optional) Call the niFgen Clear Arbitrary Memory VI to clear any previously created arbitrary waveforms, sequences, and scripts from the signal generator memory.

Choose one of the following two options for creating your arbitrary sequence:

Option 1—Allow NI-FGEN to configure the size and allocated space of your waveform.

  1. Call the niFgen Create Waveform (poly) VI. This VI creates a waveform the size of the data you provide.
  2. Call the niFgen Create Arbitrary Sequence VI or the niFgen Create Advanced Arb Sequence VI.
  3. Call the niFgen Configure Arbitrary Sequence VI to configure the gain and offset of the sequence of waveforms.

Option 2—Manually configure the size and allocated space of your waveform.

  1. Call the niFgen Allocate Waveform VI to specify the size of the waveform to allocate in the onboard memory of the signal generator
  2. Call the niFgen Write Waveform (poly) VI to write waveform data to the onboard memory you allocated in step 3.
  3. Call the niFgen Create Arbitrary Sequence VI or the niFgen Create Advanced Arb Sequence VI.
  4. Call the niFgen Configure Arbitrary Sequence VI to configure the gain and offset of the sequence of waveforms.

C Example

The procedure below provides the basic steps required to configure Arbitrary Waveform mode. For a more detailed example of the use of Arbitrary Sequence mode in C, refer to the BasicArbitrarySequence or the ArbitrarySequence examples for CVI.

  1. Call the niFgen_ConfigureOutputMode function with outputMode to NIFGEN_VAL_OUTPUT_SEQ.
  2. (Optional) Call the niFgen_ClearArbMemory function to clear any previously created arbitrary waveforms, sequences, and scripts from the signal generator memory.
  3. Call one of the niFgen Create Waveform functions (niFgen_CreateWaveformF64 , niFgen_CreateWaveformI16 , niFgen_CreateWaveformComplexF64 , or niFgen_CreateWaveformFromFileI16). The function you choose creates a waveform the size and type of the data you choose.
  4. Call the niFgen_CreateArbSequence function or the niFgen_CreateAdvancedArbSequence function.
  5. Call the niFgen_ConfigureArbSequence function to configure the gain and offset of the waveform.