Calculating Wait N Delay in NI-RFSG Script Mode

Updated Oct 22, 2026

Reported In

Hardware

  • PXI Vector Signal Generator
  • PXI Vector Signal Transceiver

Software

  • InstrumentStudio

Driver

  • NI-RFSG

Issue Details

How can I pause the execution for a finite amount of time in NI-RFSG Script Mode?

Solution

You can pause the execution for a finite amount of time using wait N. NI-RFSG Script mode is hardware-timed, which allows you to achieve precise waveform lengths and delays. Because of this, the delay parameter is not specified as a time unit, but is calculated directly in number of samples:

N = Delay x IQ Rate 

For example, if you want to pause 5 µs and IQ rate is 100 MS/s, then N = 5 µs x 100 MS/s = 500 Samples. So, it corresponds to wait 500. 

 

Additional Information

  • For an arbitrary waveform, use the waveform’s effective configured IQ Rate. NI-RFSG may coerce the requested IQ Rate to a value supported by the hardware. Therefore, do not calculate N using only the originally requested value. Read or verify the effective IQ Rate after the RFSG configuration has been applied.
  • Because N is an integer, the wait duration is quantized in increments of one IQ sample period. If Delay x IQ Rate is not an integer, the requested delay cannot be represented exactly; select an integer sample count and account for rounding.
  • For scripts involving multiple waveforms, verify that their IQ rates are consistent before applying a single rate conversion.