Coercions of Horizontal Parameters

NI High-Speed Digitizers Help (NI-SCOPE)

Edition Date: January 2017

Part Number: 370592AB-01

View Product Info

DOWNLOAD (Windows Only)


NI-SCOPE (English | Japanese)

The horizontal timing parameters are all inter-related to comply with the IVI-Scope specification. These parameters all appear in the Configure Horizontal Timing function. The fundamental theory is that your time per record is a constant number during an acquisition. This is accomplished with the following parameter coercions:

Min Sample Rate

The min sample rate parameter is coerced up to the next available sample rate that the digitizer supports. The available sample rates change based on the acquisition type (such as normal and Flex Res). The actual sampling rate may be retrieved with the Sample Rate function. This information is also returned by the Fetch function, with the x increment parameter, which is one divided by the actual sampling rate. If the sample rate parameter is set higher than the maximum, NI-SCOPE returns an error.

Enforce Realtime

If the enforce realtime parameter is set to FALSE, the digitizer enters RIS mode when the sampling rate exceeds the maximum real-time sampling rate of the device. In RIS mode, the sampling rate is coerced up to a multiple of the maximum real-time sampling rate.

Min Record Length

The min record length is coerced so that the time per record is constant. The formula is the following:

actual rec length = min rec length/min sample rate x actual sample rate

You can find the actual record length by calling the Actual Record Length function. You can retrieve this value any time after you call Configure Horizontal Timing. Keep in mind that the amount of memory required on the digitizer is generally higher than the actual record length.

Reference Position

The reference position is rounded to the nearest sample. You can use the relative initial x parameter from a Fetch function to determine the actual reference position. If you fetch relative to the pretrigger, and the offset is zero, the initial x value is the first pretrigger point to the trigger. Therefore, the actual reference position is the following:

The following C code shows how NI-SCOPE accomplishes timing coercions:

// Convert minimum sample rate into its corresponding
// time-per-record value
timePerRecord = minRecordLength / minSampleRate;
if (minSampleRate <= maxRealTimeSampleRate)
{
   // For real-time, normal acquisitions, sample rate
   // is an integer divisor of max sample rate
   int divisor = (int) floor (maxRealTimeSampleRate / minSampleRate);
   actualSampleRate = maxRealTimeSampleRate / divisor;
}
else
{
   //In RIS, sample rate is a multiple of max sample rate
   int overSamplingFactor = (int) ceil (minSampleRate / maxRealTimeSampleRate);
   actualSampleRate = overSamplingFactor × maxRealTimeSampleRate;
}
actualRecordLength = (int) ((timePerRecord × actualSampleRate) + 0.5);

WAS THIS ARTICLE HELPFUL?

Not Helpful