Sfsdaf
Sfsdaf
2025-04-20
NI-SCOPE
Contents
Welcome to the NI-SCOPE User Manual . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
Features Supported by NI-SCOPE Instruments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
NI-SCOPE Requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38
NI-SCOPE New Features and Changes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
NI-SCOPE 2023 Q3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
NI-SCOPE 2023 Q1.1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
NI-SCOPE 2023 Q1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40
NI-SCOPE 2022 Q3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40
Getting Started . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42
Operating System Support . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42
Creating an Application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42
Creating an Application with LabVIEW . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43
LabVIEW Real-Time Module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44
Creating an Application with LabWindows™/CVI™ . . . . . . . . . . . . . . . . . . . . . . . . . . . 46
Creating an Application with Microsoft Visual C and C++ . . . . . . . . . . . . . . . . . . . . . 47
Creating an Application with Visual Basic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50
Creating an Application Using Visual C# or Visual Basic .NET . . . . . . . . . . . . . . . . . 51
Forms of Device Synchronization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51
Supported Synchronization Methods by Device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54
NI-SCOPE Tutorial . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55
Instrument Drivers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56
Initialize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58
Configure the Application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60
Configuring an Acquisition Using Auto_Setup. . . . . . . . . . . . . . . . . . . . . . . . . . 62
Configuring an Acquisition Using Configuration Functions . . . . . . . . . . . . . . 62
Acquiring the Data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63
Retrieving Error Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65
Closing the Session . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66
NI-SCOPE and InstrumentStudio . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67
NI-SCOPE Examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67
Fundamentals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 70
Bandwidth . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 70
2 ni.com
NI-SCOPE
Flatness . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71
Resolution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71
Sample Rate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72
Nyquist Theorem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73
Aliasing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75
Oversampling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75
Undersampling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 76
Record Length . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 76
Vertical Range and Offset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 76
Input Coupling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77
Impedance and Impedance Matching . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77
Probes and Their Effects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 80
Probe Compensation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82
Accuracy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83
Noise . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 86
PCI and PXI Ground Loop Noise . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 86
Thermal Shutdown . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 87
Triggering . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 89
Trigger Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 90
Immediate Triggers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 91
Software Triggers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 91
Edge Triggers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 92
Glitch Triggers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 92
Hysteresis Triggers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 93
Runt Triggers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 94
Video Triggers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 95
Width Triggers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 96
Window Triggers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97
Digital Triggers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97
Burst Triggers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98
Trigger Parameters. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99
Trigger Holdoff . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99
Trigger Delay . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 100
Trigger Coupling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101
Sample Clock . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 102
Reference Clock/Phase-Lock Loop. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 103
© National Instruments 3
NI-SCOPE
4 ni.com
NI-SCOPE
© National Instruments 5
NI-SCOPE
6 ni.com
NI-SCOPE
© National Instruments 7
NI-SCOPE
8 ni.com
NI-SCOPE
© National Instruments 9
NI-SCOPE
10 ni.com
NI-SCOPE
Related information:
© National Instruments 11
NI-SCOPE
Note
• Instruments with multiple bus type variants (for example, PXIe and PXI)
are shown separately only when the bus type affects the available
features.
• These instruments are configurable in Measurement & Automation
Explorer (MAX). Refer to the getting started guide for each instrument
for configuration information.
• Refer to the specifications for each instrument for detailed information
on the supported features.
PXIe/PXI/
8
• 50 Ω
±3 V
±15
✕ • AC2 60 MHz 24 MHz -
PCI-5105 • 1 MΩ V • DC
12 ni.com
NI-SCOPE
Maximum
Input 3 dB Bandwidth1
Input Input Range DC Input
Instrument
Channels Impedance Offset? Coupling Digital
Analog
50 Ω 1 MΩ Unfiltered FIR
Filter
Filter
• 20
MHz
• 35
PXIe/PXI/ • 50 Ω ±10 • AC2 MHz
2 ±5 V ✔ • DC 100 MHz -
PCI-5122 • 1 MΩ V • 20
• GND MHz
• 60
PXI/ • 50 Ω ±10 • AC2 MHz
2 ±5 V ✔ • DC 150 MHz -
PCI-5124 • 1 MΩ V • 20
• GND MHz
USB-5132
• AC
±20
2 1 MΩ - ✔ • DC 50 MHz 20 MHz -
USB-5133 V
• GND
• 35
PXI/ • 50 Ω ±10 • AC2 MHz
2 ±5 V ✔ • DC 100 MHz -
PCI-5142 • 1 MΩ V • 20
• GND MHz
PXI/ • 50 Ω
±5 V ±5 V ✔ • AC 300 MHz 20 MHz -
PCI-5152 • 1 MΩ
2 • DC
• GND
PXI/ ±2.5
50 Ω - ✕ 500 MHz 20 MHz -
PCI-5153 V
© National Instruments 13
NI-SCOPE
Maximum
Input 3 dB Bandwidth1
Input Input Range DC Input
Instrument
Channels Impedance Offset? Coupling Digital
Analog
50 Ω 1 MΩ Unfiltered FIR
Filter
Filter
PXI/
1 GHz 20 MHz -
PCI-5154
• 175
• 50 Ω: 500 MHz MHz
PXIe-5160 -
• 1 MΩ: 300 MHz • 20
MHz
• 50 Ω ±2.5 ±25 • AC
2 or 4 ✔
• 1 MΩ V V • DC
• 175
• 50 Ω: 1.5 GHz MHz
PXIe-5162 -
• 1 MΩ: 300 MHz • 20
MHz
• 150
MHz
• 30
MHz
• 20
• 50 Ω ±2.5 ±50 • AC
2 ✕ • 50 Ω: 400 MHz MHz
PXIe-5164 • 1 MΩ V V • DC -
• 1 MΩ: 300 MHz
High-
pass:
• 450
Hz
• 90
Hz
14 ni.com
NI-SCOPE
Maximum
Input 3 dB Bandwidth1
Input Input Range DC Input
Instrument
Channels Impedance Offset? Coupling Digital
Analog
50 Ω 1 MΩ Unfiltered FIR
Filter
Filter
MHz
• 40
• 1 MΩ MHz
• 20
MHz
• 50 Ω: 3 GHz
PXIe-51853 • 1 MΩ: 500 MHz
2
• 50 Ω ±0.5
±5 V ✔ • AC2 - -
• 1 MΩ V • DC
• 50 Ω: 5 GHz
PXIe-51863 • 1 MΩ: 500 MHz
• Direct path: 3
MHz to 250 MHz
±1.4 • AC
PXIe-5622 1 50 Ω - ✕ • Bandpass path: - -
V • GND
162.5 MHz to
212.5 MHz
• AC
PXI/ • 50 Ω 0.4 × Sample Rate (6
2 ±5 V ±5 V ✕ • DC - -
PCI-5922 • 1 MΩ MHz maximum)
• GND
Table 2. Timing
Maximum Sample Rate Time Stamps
Instrument Real-Time Time-Interleaved Random Interleaved
Absolute Relative
Sampling Sampling (TIS) Sampling (RIS)
PXIe/PXI/
60 MS/s - - ✔ ✔
PCI-5105
PXIe-5110 500 MS/s 1 GS/s - ✔ ✔
© National Instruments 15
NI-SCOPE
16 ni.com
NI-SCOPE
Table 3. Clocking
Reference Clock External Sample Clock Sample
Instrument Clock
Frequency Input Sources Outputs Frequency Sources Outputs
• PFI 1
PXIe-5105 PFI 1
• PXI_CLK10
5 MHz to • PFI 1
PXI-5105 PFI 1
20 MHz, 1 • PXI_CLK10 4 MHz to • PFI 1
MHz 65 MHz • PXI Star PFI 14
increments
• PFI 1
• PFI 1
• RTSI
PCI-5105 • RTSI clock
clock
(RTSI 7)
(RTSI 7)
PXIe-5110
PXIe-5111 100 MHz PXI_CLK100 - - - -
PXIe-5113
• PFI
• CLK IN <0..1>
PXIe-5114
5 MHz to • PXI_CLK10 • PXI_Trig
20 MHz, 1 <0..6> 50 MHz to
CLK IN -
MHz 250 MHz
increments
• CLK IN • PFI
PXI-5114
• PXI_CLK10 <0..1>
© National Instruments 17
NI-SCOPE
• PXI_Trig
<0..6>
• PFI
• CLK IN <0..1>
PCI-5114 • RTSI clock • RTSI
(RTSI 7) clock
(RTSI 7)
• CLK
OUT
• CLK IN • PFI
PXIe-5122
• PXI_CLK10 <0..1>
• PXI_Trig
<0..6>
• CLK
• CLK
OUT
5 MHz to OUT
• CLK IN • PFI
PXI-5122 20 MHz, 1 30 MHz to • CLK IN • PFI
• PXI_CLK10 <0..1>
MHz 105 MHz • PXI Star <0..1>
• PXI_Trig
increments • RTSI
<0..6>
<0..6>
• CLK
OUT
• CLK IN • PFI
PCI-5122 • RTSI clock <0..1>
(RTSI 7) • RTSI
clock
(RTSI 7)
18 ni.com
NI-SCOPE
• CLK
OUT
• CLK IN • PFI
PXI-5124
• PXI_CLK10 <0..1>
• PXI_Trig
<0..6> • CLK
5 MHz to OUT
20 MHz, 1 50 MHz to • CLK IN • PFI
MHz 210 MHz • PXI Star <0..1>
increments • CLK • RTSI
OUT <0..6>
• CLK IN • PFI
PCI-5124 • RTSI clock <0..1>
(RTSI 7) • RTSI
clock
(RTSI 7)
1 MHz to
USB-5132
50 MHz
- - - PFI 1 -
1 MHz to
USB-5133
100 MHz
• CLK
OUT
• CLK IN • PFI
PXI-5142
• PXI_CLK10 <0..1>
• PXI_Trig
<0..6>
5 MHz to • CLK
20 MHz, 1 30 MHz to • CLK IN OUT
MHz 105 MHz • PXI Star • PFI
increments • CLK <0..1>
OUT
• CLK IN • PFI
PCI-5142 • RTSI clock <0..1>
(RTSI 7) • RTSI
clock
(RTSI 7)
© National Instruments 19
NI-SCOPE
• PFI 1
• PFI 0
PXI-5152 • PXI_Trig
• PXI_CLK10
<0..6>
• PFI 1
• PFI 0
• RTSI
PCI-5152 • RTSI clock
clock
(RTSI 7)
(RTSI 7)
• PFI 1
• PFI 0
PXI-5153 • PXI_Trig
• PXI_CLK10
<0..6>
1 MHz to
20 MHz, 1 350 MHz
PFI 0 -
MHz to 1 GHz
increments • PFI 1
• PFI 0
• RTSI
PCI-5153 • RTSI clock
clock
(RTSI 7)
(RTSI 7)
• PFI 1
• PFI 0
PXI-5154 • PXI_Trig
• PXI_CLK10
<0..6>
• PFI 1
• PFI 0
• RTSI
PCI-5154 • RTSI clock
clock
(RTSI 7)
(RTSI 7)
PXIe-5160
• CLK IN 1.25 GHz
10 MHz CLK OUT CLK IN -
PXIe-5162 • PXI_CLK10 to 2.5 GHz
20 ni.com
NI-SCOPE
PXIe-5170
• AUX 0CLK
PXIe-5171 • AUX 0CLK 150 MHz
AUX 0 CLK IN
10 MHz IN to 250 -
OUT • PXIe_DSTAR
• PXI_CLK10 MHz
PXIe-5172 A
PXIe-5185
• 10
MHz • REF CLK 1.6 GHz to
- CLK IN -
PXIe-5186 • 100 • PXI_CLK100 3.125 GHz
MHz
1 MHz to
100 MHz, 1 • CLK IN 20 MHz to
PXIe-5622 CLK OUT CLK IN CLK OUT
MHz • PXI_CLK100 150 MHz
increments
• CLK
OUT
• CLK IN • PFI
PXI-5922
• PXI_CLK10 <0..1>
• PXI_Trig
1 MHz to <0..6>
20 MHz, 1
- - -
MHz
increments • CLK
OUT
• CLK IN
• PFI
PCI-5922 • RTSI clock
<0..1>
(RTSI 7)
• RTSI
clock
© National Instruments 21
NI-SCOPE
(RTSI 7)
22 ni.com
NI-SCOPE
PXIe-5110
• Same as
PXIe-5111 input
• CH <0..1>
channel - -
• PFI <0..3>
• HF reject
PXIe-5113
• LF reject
• AC
• DC
• Same as
• LF
• CH <0..1> input
PXIe/PXI/ reject
• PFI <0..1> channel 1 MΩ
PCI-5114 • HF
• TRIG • HF reject
reject
• LF reject
• AC + HF
reject
• AC
• DC
• Same as
• LF
• CH <0..1> input
PXIe/PXI/ reject
• PFI <0..1> channel 1 MΩ
PCI-5122 • HF
• TRIG • HF reject
reject
• LF reject
• AC + HF
reject
© National Instruments 23
NI-SCOPE
Trigger Coupling
Reference Trigger Sources External TRIG Input
Instrument Analog Input External
(Bus-Independent) Impedance
Channel TRIG Input
• AC
• DC
• Same as
• LF
• CH <0..1> input
PXI/ reject
• PFI <0..1> channel 1 MΩ
PCI-5124 • HF
• TRIG • HF reject
reject
• LF reject
• AC + HF
reject
USB-5132
• CH <0..1> Same as input
- -
USB-5133 • PFI 1 channel
• AC
• DC
• Same as
• LF
• CH <0..1> input
PXI/ reject
• PFI <0..1> channel 1 MΩ
PCI-5142 • HF
• TRIG • HF reject
reject
• LF reject
• AC + HF
reject
• AC
• DC
• LF
• CH <0..1>
PXI/ reject
• PFI <0..1> • Same as 1 MΩ
PCI-5152 • HF
• TRIG input reject
channel • AC + HF
• HF reject reject
• LF reject
PXI/ • CH <0..1> • DC
2.25 kΩ
PCI-5153 • PFI <0..1> • LF
24 ni.com
NI-SCOPE
Trigger Coupling
Reference Trigger Sources External TRIG Input
Instrument Analog Input External
(Bus-Independent) Impedance
Channel TRIG Input
• TRIG
reject
• HF
• CH <0..1> reject
PXI/
• PFI <0..1>
PCI-5154
• TRIG
PXIe-5160
• AC
• DC
• Same as
• LF
• CH <0..n> input
reject Software selectable:
• PFI <0..1> channel
PXIe-5162 • HF 50 Ω or 1 MΩ
• TRIG • HF reject
reject
• LF reject
• AC + HF
reject
PXIe-5163
• Same as
• CH <0..1> input
• SMB PFI 0 channel - -
PXIe-5164 • AUX 0 PFI <0..7> • HF reject
• LF reject
PXIe-5170
• CH <0..n> Same as input
PXIe-5171 - -
• PFI <0..7> channel
PXIe-5172
PXIe-5185
• CH <0..1> Same as input
DC 50 Ω
PXIe-5186 • TRIG channel
PXIe-5622 IF IN - - -
© National Instruments 25
NI-SCOPE
Trigger Coupling
Reference Trigger Sources External TRIG Input
Instrument Analog Input External
(Bus-Independent) Impedance
Channel TRIG Input
• CH <0..1>
PXI/ Same as input
• PFI <0..1> DC 1 MΩ
PCI-5922 channel
• TRIG
Note Some reference trigger sources are available across all instruments of
a given bus type.
• PFI 1 • PFI 1
PXIe-5105 • PXI_Trig • RTSI
<0..7> • PFI 1 <0..7>
• PXI Star • PFI 1
• RTSI • RTSI <0..6>
<0..7>
• PFI 1 • PFI 1
PXI-5105
• PXI_Trig • PXI Star
26 ni.com
NI-SCOPE
<0..7> • RTSI
• PXI Star <0..7>
• PFI 1 • PFI 1
PCI-5105 • RTSI • RTSI
<0..7> <0..7>
PXIe-5110
• PFI • PFI • PFI
PXIe-5111 <0..3> <0..3> <0..3> • PFI <0..3>
• PXI_Trig • PXI_Trig • PXI_Trig • PXI_Trig <0..6>
PXIe-5113 <0..7> <0..7> <0..7>
• PFI • PFI
<0..1> <0..1>
PXIe-5114
• PXI_Trig • RTSI
<0..7> <0..7>
• PFI • PFI
<0..1> • PFI <0..1>
PXI-5114 • PXI_Trig <0..1> • PXI Star
• PFI <0..1>
<0..7> • PXI Star • RTSI
• RTSI <0..6>
• PXI Star • RTSI <0..7>
<0..7>
• PFI
<0..1> • PFI
• PXI_Trig <0..1>
PCI-5114
<0..7> • RTSI
• RTSI <0..7>
<0..7>
© National Instruments 27
NI-SCOPE
• PFI • PFI
<0..1> <0..1>
PXIe-5122
• PXI_Trig • RTSI
<0..7> <0..7>
• PFI • PFI
<0..1> • PFI <0..1>
PXI-5122 • PXI_Trig <0..1> • PXI Star
• PFI <0..1>
<0..7> • PXI Star • RTSI
• RTSI <0..6>
• PXI Star • RTSI <0..7>
<0..7>
• PFI
<0..1> • PFI
• PXI_Trig <0..1>
PCI-5122
<0..7> • RTSI
• RTSI <0..7>
<0..7>
• PFI • PFI
<0..1> <0..1>
PXI-5124 • PXI_Trig • PXI Star
<0..7> • RTSI
• PXI Star • PFI <0..7>
<0..1>
• PFI <0..1>
• PXI Star
• RTSI <0..6>
• PFI • RTSI
<0..1> <0..7> • PFI
• PXI_Trig <0..1>
PCI-5124
<0..7> • RTSI
• RTSI <0..7>
<0..7>
28 ni.com
NI-SCOPE
• PFI • PFI
<0..1> <0..1>
PXI-5142 • PXI_Trig • PXI Star
<0..7> • RTSI
• PXI Star • PFI <0..7>
<0..1>
• PFI <0..1>
• PXI Star
• RTSI <0..6>
• PFI • RTSI
<0..1> <0..7> • PFI
• PXI_Trig <0..1>
PCI-5142
<0..7> • RTSI
• RTSI <0..7>
<0..7>
• PFI • PFI
<0..1> <0..1>
PXI-5152 • PXI_Trig • PXI Star
<0..7> • RTSI
• PXI Star <0..7>
• PFI
• PFI <0..1>
• PFI <0..1>
<0..1> • PXI Star • PFI
• RTSI <0..6>
• PXI_Trig • RTSI <0..1>
PCI-5152
<0..7> <0..7> • RTSI
• RTSI <0..7>
<0..7>
• PFI • PFI
PXI-5153
<0..1> <0..1>
© National Instruments 29
NI-SCOPE
• PFI
<0..1> • PFI
• PXI_Trig <0..1>
PCI-5153
<0..7> • RTSI
• RTSI <0..7>
<0..7>
• PFI • PFI
<0..1> <0..1>
PXI-5154 • PXI_Trig • PXI Star
<0..7> • RTSI
• PXI Star <0..7>
• PFI
<0..1> • PFI
• PXI_Trig <0..1>
PCI-5154
<0..7> • RTSI
• RTSI <0..7>
<0..7>
PXIe-5160
• PFI • PFI • PFI
<0..1> <0..1> <0..1> • PFI <0..1>
PXIe-5162 • PXI_Trig • PXI_Trig • PXI_Trig • PXI_Trig <0..6>
<0..7> <0..7> <0..7>
PXIe-5163
• PFI • PFI • PFI • PFI <0..7>
PXIe-5164
30 ni.com
NI-SCOPE
PXIe-5170
• PFI • PFI • PFI
PXIe-5171 <0..7> <0..7> <0..7> • PFI <0..7>
• PXI_Trig • PXI_Trig • PXI_Trig • PXI_Trig <0..6>
PXIe-5172 <0..7> <0..7> <0..7>
• PFI • PFI
<0..1> <0..1>
PXI-5922 • PXI_Trig • PXI Star
<0..7> • PFI • RTSI
• PXI Star <0..1> <0..7>
• PFI <0..1>
• PXI Star
• PXI_Trig <0..6>
• RTSI
• PFI <0..7> • PFI
<0..1> <0..1>
PCI-5922
• RTSI • RTSI
<0..7> <0..7>
© National Instruments 31
NI-SCOPE
Table 7. Acquisition
Multiple Record Continuous DDC Acquisition
Instrument Resolution
Acquisitions? Acquisition? Mode?
PXIe/PXI/
12 bits ✔ ✔ ✕
PCI-5105
PXIe-5110
PXIe-5111 8 bits ✔ ✔ ✕
PXIe-5113
PXIe/PXI/
8 bits ✔ ✔ ✕
PCI-5114
PXIe/PXI/
14 bits ✔ ✔ ✕
PCI-5122
PXI/
12 bits ✔ ✔ ✕
PCI-5124
USB-5132
8 bits ✕ ✔ ✕
USB-5133
PXI/
14 bits ✔ ✔ ✔
PCI-5142
PXI/
PCI-5152
PXI/
8 bits ✔ ✔ ✕
PCI-5153
PXI/
PCI-5154
PXIe-5160
10 bits ✔ ✔ ✕
PXIe-5162
PXIe-5163
14 bits ✔ ✔ ✕
PXIe-5164
PXIe-5170
PXIe-5171 14 bits ✔ ✔ ✕
PXIe-5172
32 ni.com
NI-SCOPE
Table 8. Miscellaneous
Probe Onboard
LabVIEW Onboard
Self- Compensation Signal Reconfigurable CableSenseT Memory
Instrument Real-Time
Calibration? Signal Processing FPGA? Capable?8
Support?7 Options9
Output6 Support?
• 16
MB
PXIe/PXI/ • 128
✔ PFI 1 ✔ ✕ ✕ ✕
PCI-5105 MB
• 512
MB
PXIe-5110
• 64
PXIe-5111 Probe
MB
✔ compensation ✕ ✕ ✕ ✔
• 512
terminals
PXIe-5113 MB
• 8
MB
PXIe/PXI/ • 64
✔ PFI 1 ✔ ✕ ✕ ✕
PCI-5114 MB
• 256
MB
PXIe-5122 ✔ PFI 1 ✔ ✕ ✕ ✕ • 8
© National Instruments 33
NI-SCOPE
Probe Onboard
LabVIEW Onboard
Self- Compensation Signal Reconfigurable CableSenseT Memory
Instrument Real-Time
Calibration? Signal Processing FPGA? Capable?8
Support?7 Options9
Output6 Support?
MB
• 64
MB
• 256
MB
• 8
MB
• 32
MB
PXI-5122
• 256
MB
• 512
MB
• 8
MB
• 32
PCI-5122
MB
• 256
MB
• 8
MB
• 32
PXI/ MB
✔ PFI 1 ✔ ✕ ✕ ✕
PCI-5124 • 256
MB
• 512
MB
34 ni.com
NI-SCOPE
Probe Onboard
LabVIEW Onboard
Self- Compensation Signal Reconfigurable CableSenseT Memory
Instrument Real-Time
Calibration? Signal Processing FPGA? Capable?8
Support?7 Options9
Output6 Support?
USB-5132
• 8
MB
✔10 PFI 1 ✕ ✕ ✕ ✕
• 64
USB-5133
MB
• 64
PXI/ MB
✔ PFI 1 ✔ ✔ ✕ ✕
PCI-5142 • 256
MB
PXI/
PCI-5152 • 16
MB
PXI/ • 128
PCI-5153 ✔ PFI 1 ✔ ✕ ✕ ✕
MB
• 512
PXI/
MB
PCI-5154
PXIe-5160
• 64
✔ PFI 1 ✔ ✕ ✕ ✔ MB
PXIe-5162 • 2 GB
PXIe-5163 ✕ 512 MB
✔ SMB PFI 0 ✕ ✕ ✕
PXIe-5164 ✔ 1.5 GB
• 0.75
GB
PXIe-5170
✔ - ✕ ✕ ✔ ✕ • 1.5
GB
PXIe-5171 1.5 GB
© National Instruments 35
NI-SCOPE
Probe Onboard
LabVIEW Onboard
Self- Compensation Signal Reconfigurable CableSenseT Memory
Instrument Real-Time
Calibration? Signal Processing FPGA? Capable?8
Support?7 Options9
Output6 Support?
• 0.75
GB
PXIe-5172
• 1.5
GB
PXIe-5185
• 32
11 - ✔ ✕ ✕ ✕ MB
✔
PXIe-5186 • 1 GB
• 64
MB
PXIe-5622 ✔ - ✔ ✔ ✕ ✕
• 256
MB
• 16
MB
PXI/ • 64
PCI-5922 ✔11 - ✔ ✕ ✕ ✕
MB
• 512
MB
1
All filters are low-pass unless otherwise noted.
2
Available on 1 MΩ input impedance only.
3
1 MΩ available on modules with part numbers as follows:
• PXIe-5185: 152962x-0zL
• PXIe-5186: 152961x-0zL
36 ni.com
NI-SCOPE
4
Sample clock may be exported only at full rate.
5
Can simultaneously export or import a maximum of four triggers or events.
6
1 kHz square wave.
7
Applies to instruments with PXIe and PXI bus types only.
8
CableSense-capable instruments may not include the CableSense option. To use
CableSense, you must purchase a CableSense-capable instrument that includes the
CableSense option.
9
Total module memory. The maximum memory available to each channel in a session
is the module total divided by the number of channels enabled in the session.
10
Self-calibration of DC offset only.
11
Self-calibration not supported on Linux systems.
Related concepts:
© National Instruments 37
NI-SCOPE
NI-SCOPE Requirements
NI-SCOPE has the following requirements:
• Windows 11
• Windows 10
• Windows Server 2022
• Windows Server 2019
• Windows Server 2016
• NI Linux® Real-Time1
38 ni.com
NI-SCOPE
NI-SCOPE 2023 Q3
Behavior Changes
The NI-SCOPE Soft Front Panel has been replaced by InstrumentStudio, which is
automatically installed when you install the NI-SCOPE driver. You can access
InstrumentStudio in one of the following ways:
Note The deprecated NI-SCOPE Soft Front Panel remains available for
download. Visit Legacy Soft Front Panels for NI-SCOPE for more information.
Related information:
Behavior Changes
The NI-SCOPE Soft Front Panel has been replaced by InstrumentStudio, which is
automatically installed when you install the NI-SCOPE driver. You can access
© National Instruments 39
NI-SCOPE
Note The deprecated NI-SCOPE Soft Front Panel remains available for
download. Visit Legacy Soft Front Panels for NI-SCOPE for more information.
NI-SCOPE 2023 Q1
Behavior Changes
The NI-SCOPE Soft Front Panel has been replaced by InstrumentStudio, which is
automatically installed when you install the NI-SCOPE driver. You can access
InstrumentStudio in one of the following ways:
Note The deprecated NI-SCOPE Soft Front Panel remains available for
download. Visit Legacy Soft Front Panels for NI-SCOPE for more information.
NI-SCOPE 2022 Q3
New Features
40 ni.com
NI-SCOPE
Behavior Changes
Note The deprecated NI-SCOPE Soft Front Panel remains available for
download.
© National Instruments 41
NI-SCOPE
Getting Started
To get started using your NI-SCOPE device and driver software, refer to the getting
started guide for your device. The getting started guide explains how to complete the
following tasks:
The getting started guide for your device is printed in your hardware kit, installed with
the driver software, and available at ni.com/manuals.
Tip Complete the getting started guide for your device before using the
information in this help file.
Related concepts:
For information about the supported operating system (OS) for your device, refer to
the NI-SCOPE Readme at Start»All Programs»National Instruments»NI-
SCOPE»Documentation.
Creating an Application
42 ni.com
NI-SCOPE
Each section includes basic information on how to create an application and how to
find and use examples for each ADE.
Related concepts:
1. Launch LabVIEW.
2. Open an existing LabVIEW VI or create a new VI.
3. Make sure you are on the block diagram screen.
4. Open the NI-SCOPE palette. In LabVIEW 7.1 and later, the path to the palette
depends on the current palette view in Tools»Options. In the Express palette view
(default) the path is Input»Instrument Drivers»NI SCOPE.
5. Build your application using the appropriate programming flow steps.
LabVIEW Examples
© National Instruments 43
NI-SCOPE
Several forms of help are available for these examples. You can find an overall
description of the purpose of the example by going to File»VI Properties and selecting
Documentation from the Category listbox. For help on individual front-panel controls,
activate the LabVIEW help window by selecting Help»Show Context Help, and placing
the cursor over the control you want more information about. The block diagrams of
the examples are documented with step-by-step descriptions of what the example
does.
NI Example Finder
LabVIEW 7.0 or later users can use the NI Example Finder to search or browse
examples. NI-SCOPE examples are classified by keyword, so you can search for a
particular device or measurement function. To browse for NI-SCOPE examples, launch
LabVIEW, select Help»Find Examples, then navigate to Hardware Input and
Output»Modular Instruments» NI-SCOPE (High-Speed Digitizers).
Related concepts:
You can use the NI‑SCOPE VIs on a LabVIEW Real-Time execution target. To develop an
NI‑SCOPE application in the LabVIEW Real-Time Module, follow the same steps used
for developing any application in the LabVIEW Real-Time Module, with the addition of
using NI‑SCOPE VIs, as follows:
1. From the Function Palette, locate the NI-SCOPE VIs at Instrument I/O Instrument
Drivers»NI-SCOPE.
2. Select the VIs that you want to use and drop them on the block diagram to build
your application.
44 ni.com
NI-SCOPE
Most NI high-speed digitizers are supported under the LabVIEW Real-Time Module.
The following devices are not supported under the LabVIEW Real-Time Module:
• PXIe‑5110/5111/5113
• PXIe‑5163
• PXIe‑5164
• PXIe‑5170/5171
• PXIe‑5172
Unsupported Features
When using NI high-speed digitizers with the LabVIEW Real-Time Module, the
NI‑SCOPE Soft Front Panel is not supported.
Example Programs
You can use the LabVIEW Example Finder to search or browse through examples.
NI‑SCOPE examples are classified by keyword, so you can search for a particular device
or measurement function. You can reach the NI‑SCOPE examples from LabVIEW
Example Finder (Help»Find Examples). Click the Browse tab, browse according to
Task, and navigate to Hardware Input and Output/Modular
Instruments/NI-SCOPE (High-Speed Digitizers). You can use all of the
NI‑SCOPE examples on a LabVIEW Real-Time execution target provided that the
example is not specific to an unsupported hardware module.
Related Documentation
• For configuration instructions for remote systems, refer to the Remote Systems
Help in Measurement & Automation Explorer (MAX) by selecting Help»Help
Topics»Remote Systems in MAX.
• For more information on the LabVIEW Real-Time Module, refer to the LabVIEW
Real-Time Module User Manual at ni.com/manuals.
© National Instruments 45
NI-SCOPE
1. Launch LabWindows/CVI.
2. Open an existing or new source file (.c).
3. Include the NI-SCOPE header file, niscope.h, in your source code files
(#include "niscope.h").
4. Go to Instrument»Load, and select niscope.fp. You can find the installed
location of this file in the NI-SCOPE Readme.
5. Add the source file to the project.
6. Build your application using the appropriate programming flow steps.
LabWindows/CVI Examples
Open the project file for the example you want to run. You can find shortcuts to the
project files at Start»All Programs»National Instruments»NI-SCOPE»Examples. The
source code for these examples is heavily documented, and all input and output
values are documented to facilitate changing the code to perform different
acquisitions. Each example also has a Readme file that provides an overall description
of the example.
To find documentation for functions used in the examples, complete the following
steps:
1. Double-click niScope.fp.
2. Select the function or function class you need more information about.
3. Click Help.
NI Example Finder
LabWindows/CVI 7.0 or later users can use the NI Example Finder to search or browse
examples. NI-SCOPE examples are classified by keyword, so you can search for a
particular device or measurement function. To browse for NI-SCOPE examples, launch
LabWindows/CVI, select Help»Find Examples, then navigate to Hardware Input and
Output»Modular Instruments» NI-SCOPE (High-Speed Digitizers).
46 ni.com
NI-SCOPE
Related concepts:
This topic assumes that you are using the Microsoft Visual C or C++ ADE to manage
your code development and that you are familiar with the following ADEs:
To develop an NI-SCOPE application with Microsoft Visual C++ 6.0, follow these general
steps:
1. Open an existing or new Visual C/C++ project to manage your application code.
2. Create source code files of type .c (C) or .cpp (C++).
3. Add the source code files to the project.
4. Add the following code in the source code files:
#include "niscope.h"
5. Add the NI-SCOPE include and library files to the project. <IVIROOTDIR32> is an
alias to a specific National Instruments file folder location. Refer to the NI-SCOPE
Readme for more information about installed file locations.
© National Instruments 47
NI-SCOPE
To develop an NI-SCOPE application with Microsoft Visual Studio 2010, follow these
general steps:
1. Open an existing or new Visual C/C++ project to manage your application code.
2. Create source code files of type .c (C) or .cpp (C++).
3. Add the source code files to the project.
4. Add the following code in the source code files:
#include "niscope.h"
5. Add the NI-SCOPE include and library files to the project. <IVIROOTDIR32> is an
alias to a specific National Instruments file folder location. Refer to the NI-SCOPE
Readme for more information about installed file locations.
48 ni.com
NI-SCOPE
Two sets of examples for Visual C/C++ exist. You can find the installed location of these
examples in the NI-SCOPE Readme.
• The examples in the first set are C-based console applications that illustrate the NI-
SCOPE function calls but have no provision for data display.
• The examples in the second set are C++ examples. They use Microsoft Foundation
Classes (MFC) along with Measurement Studio tools for Visual C++. To compile
these examples, you need these tools. The source code for these examples is
documented, so you can change the code to fit your needs.
The C examples were built and tested using Microsoft Visual C++ 6.0 with Service Pack
5.0. These examples are console-based with no graphical interface.
To build the examples in Microsoft Visual C++ 6.0 using the Microsoft NMAKE utility,
complete the following steps:
To build the examples in Microsoft Visual C++ 6.0 using the Microsoft Developer Studio
workspace, complete the following steps:
© National Instruments 49
NI-SCOPE
3. Add the include directory and lib\msc directories to the project. You can find
the installed location of these examples in the NI-SCOPE Readme. To build the
examples, the INCLUDE and LIB search paths might need to be modified to find
niscope.h and niscope.lib (Tools»Options»Directories or
Project»Settings).
4. Build the example.
Related concepts:
To develop an NI-SCOPE application with Visual Basic, complete the following steps:
The Visual Basic examples use an evaluation version of the NI Measurement Studio
ActiveX UI controls. The examples were built and tested using Microsoft Visual Basic
6.0. For each example, there is a project file (.vbp) that launches Developer Studio.
If you have problems getting the examples to load or run, complete the following
steps:
1. Make sure the NI-SCOPE reference is loaded (go to Project»References, and load
\bin\niscope_32.dll. You can find the installed location of this file in the NI-
SCOPE Readme.
50 ni.com
NI-SCOPE
2. Make sure the National Instruments Measurement Studio UI controls are loaded
(go to Project»Components, and load cwui.ocx from the Windows system
directory).
3. Install Service Pack 5 for Microsoft Visual Studio.
The source code for these examples is heavily documented, and all input and output
values are documented to facilitate changing the code to perform different
acquisitions.
Related concepts:
To develop an NI-SCOPE application with Visual C# or Visual Basic .NET, complete the
following steps:
Note
© National Instruments 51
NI-SCOPE
Software-Based Synchronization
You can send a synchronization software command from a host computer to a device.
Synchronizing events by software is not deterministic on operating systems such as
Windows or Mac.
Time-Based Synchronization
Note You can use a time-based protocol, such as GPS, 1588, or IRIG-B, to
coordinate events at large distances, typically greater than 10 m.
Signal-Based Synchronization
PXI Trigger or RTSI Trigger Routing (SCOPE, FGEN, HSDIO, RF)
You can send an electrical signal from one device (master) to another (slave) to signal
an event using the trigger routing available from a PXI chassis or RTSI cable. The
devices dictate the level of determinism. The signal path length mainly determines the
52 ni.com
NI-SCOPE
synchronization accuracy.
External Triggering
Note In this case, external refers to triggering external to your PXI chassis or
external to the device for other device form factors, for example USB and
PCIe.
You can send triggers to each device through PFI, channel, or other I/O lines on the
device front panel. When trigger lines have matched signal path lengths, measured
synchronization results may improve.
You can use NI-TClk to programmatically phase align clocks and coordinate triggers
between devices and multiple chassis. NI-TClk is an advanced synchronization
method, and is not supported by all devices.
Related concepts:
Related information:
•
•
•
© National Instruments 53
NI-SCOPE
•
•
•
•
•
•
•
• Introduction to NI Clock Disciplining for PXI Express
• PXI_Clk10 Disciplining and Synchronization across Multiple PXIe Chassis
• Timing and Synchronization Systems
• Synchronization Products
• Synchronization Explained (trigger routing and sharing clocks and triggers)
• Triggers Offered by PXI Standard
• PXI Star Trigger Line
• Improving System Clock Error
• When to Use External Sample Clock
• National Instruments T-Clock Technology for Timing and Synchronization of
Modular Instruments
PXIe‑5110/
Yes Yes Yes Yes
5111/5113
PXIe/PXI/
Yes Yes Yes Yes
PCI‑5114
PXIe/PXI/
Yes Yes Yes Yes
PCI‑5122
USB‑5132/
Yes No Yes No
5133
54 ni.com
NI-SCOPE
PXIe‑5160/
Yes Yes Yes Yes
5162
PXIe-5163 Yes Yes Yes Yes
PXIe-5164 Yes Yes Yes Yes
PXIe‑5170/
Yes Yes Yes Yes
5171
PXIe‑5185/
Yes Yes Yes Yes
5186
NI-SCOPE Tutorial
Example Programs
NI-SCOPE ships with several examples that demonstrate some basic digitizer
applications. You can find these examples at Start»All Programs»National
Instruments»NI-SCOPE»Examples.
Note The NI-SCOPE examples assume that you are already familiar with
your ADE. If you are unfamiliar with your ADE, consult an introductory text on
the ADE before you begin the Getting Started example.
© National Instruments 55
NI-SCOPE
Basic Steps
After you finish the NI-SCOPE Tutorial, you can find more advanced information in the
following sections:
• Acquisition Functions
• Configuration Functions
• Attributes and Attribute Functions
Related concepts:
• Initialize
• Configure the Application
• Acquiring the Data
• Retrieving Error Information
• Closing the Session
• Acquisition Functions
• Configuration Functions
• Attributes and Attribute Functions
Instrument Drivers
56 ni.com
NI-SCOPE
All instrument drivers have the same basic hierarchy. Instrument drivers are written
from low-level components that are used to program instruments. These component
functions fit into six categories—Initialize, Configuration, Action/Status, Data, Utility,
and Close.
Initialize
All instrument drivers have an Initialize function. It is the first instrument driver
function called and establishes communication with instruments. Optionally, it can
also perform instrument identification query and reset operations. Initialization also
places instruments in a specific state, usually the default power on state.
Configuration
Action/Status
The Action/Status category contains two types of functions. Action functions cause
instruments to initiate or terminate test and measurement operations such as arming
the triggering system or generating a stimulus. Action functions differ from
Configuration functions in that they do not change instrument settings; instead, they
order the instrument to carry out an action based on its current configuration settings.
Status functions return the current status of instruments or of pending operations.
Specific routines in this category and the actual operations they perform are at the
discretion of the instrument driver developer, and are usually created as required by
other functions.
Data
Data functions include calls to transfer data to or from instruments. Examples of Data
function operations include reading a measured value or waveform from a
measurement instrument, and downloading waveforms or digital patterns to a source
© National Instruments 57
NI-SCOPE
Utility
Close
All instrument drivers include a Close function. The Close function terminates the
software connection to instruments and deallocates system resources used during that
instrument session.
Initialize
Because you can have multiple digitizers connected to your computer, you must tell
NI-SCOPE which digitizer(s) to communicate with by opening a session to the digitizer
or digitizers with an Initialize function.
What Is a Session?
A session establishes a connection between digitizers and your application. After this
connection is established, the digitizer(s) can transmit data to your application.
Sessions allow the driver to cache previous settings, which greatly improves
performance.
You can create sessions that include multiple instruments of the same model and in
the same chassis. This automatically synchronizes all channels of the included
instruments, simplifying your test program development and maintenance. To create a
session to multiple digitizers, enter the instrument names as a comma-delimited list of
58 ni.com
NI-SCOPE
strings in the form PXI1Slot3,PXI1Slot4 for the Resource Name input parameter of an
Initialize function.
C Example—Initializing a Session
Note
• When you run your application, you must use the resource name
assigned by Measurement & Automation Explorer (MAX). Find or set the
resource name for your digitizers by launching MAX and selecting
Devices and Interfaces.
• Setting the ID Query parameter to TRUE has no effect with NI-SCOPE.
NI-SCOPE automatically verifies that the digitizer(s) you initialize are
supported—therefore, setting this parameter to TRUE is not necessary.
• Setting the Reset Device parameter to TRUE resets digitizers during
initialization.
Caution Resetting digitizers may cause wear on the relays, so you should
reset only when necessary.
© National Instruments 59
NI-SCOPE
After you have opened a session to the digitizer(s) with an Initialize function, you need
to configure your application. For example, you might want to set input parameters
(also known as controls and constants in LabVIEW) such as the vertical range,
minimum sample rate, and triggering options.
You can use one of the following two methods to configure an application:
Programming Flow
The following diagram shows the basic programming flow for using either Auto Setup
or configuration functions.
60 ni.com
NI-SCOPE
Initialize
Opens a session
Have NI-SCOPE
No automatically configure Yes
the settings?
Configure Acquisition
Configures how digitizer
acquires data
Configure Vertical
Configures the vertical
subsystem like range
Error Handler
(not required for LabVIEW)
Close
Related concepts:
© National Instruments 61
NI-SCOPE
After you have opened a session to the digitizer(s), you need to configure your
application. For the Getting Started example, we use the Auto Setup function
to configure the digitizer. The Auto Setup function senses the input signal and
automatically configures many of the instrument settings, such as the vertical range,
sample rate, minimum record length, and trigger levels.
C Example—Configuring An Acquisition
niScope_AutoSetup (vi);
If you want to customize sample rates, change triggers, or alter the offset, you must
use the Configuration functions such as Configure Vertical and Configure
Horizontal Timing instead of the Auto Setup function.
Related concepts:
62 ni.com
NI-SCOPE
As an alternative to using the Auto_Setup function, you can use the Configuration
functions to set up an acquisition in which you want to set triggers, input impedance,
DC offset, vertical range, sampling rate, and so on.
Configuration Example
Related Topics
Related concepts:
NI-SCOPE has two kinds of functions that acquire data—Read and Fetch functions. For
simplicity, this example uses a Read function.
© National Instruments 63
NI-SCOPE
The channels input parameter specifies the channel or channels that NI-SCOPE
acquires data from.
This example includes additional functions and parameters not needed in LabVIEW.
You need to call niScope_ActualRecordLength to get the actual record length
that NI-SCOPE uses so you can create enough space for the waveform array. You can
then initiate the acquisition and fetch the data with niScope_Read. After fetching
the data, you need to pass a pointer to extract and plot the acquired data. The method
you use to do this varies depending on your ADE.
64 ni.com
NI-SCOPE
!wfmInfoPtr)
return NISCOPE_ERROR_INSUFFICIENT_MEMORY;
The channelList parameter specifies the channel or channels that NI-SCOPE acquires
data from. The wfmInfoPtr parameter returns the values needed to display a
waveform: relative initial x is the time of the first point in the waveform with respect
to the trigger and is expressed in seconds; absolute initial x is the absolute timestamp
of the first point in the waveform; and x increment is the length of time between
points in the waveform in seconds. The wfmPtr parameter is a buffer into which NI-
SCOPE stores the waveform it reads. The units for the individual array elements are
volts.
LabVIEW
Make sure that you have wired the Error In and Error Out parameters for each VI in
your application, so the VI (unless it is a Close, Abort, or Reset VI) does not execute if
there is an error. The Error Description parameter displays messages for any errors
encountered when running the application.
© National Instruments 65
NI-SCOPE
Other ADEs
The Error Handler function translates error codes into explanations to help you
debug your application.
The closing step closes the session and deallocates any resources the session used.
Closing the session is important because it releases any temporary buffers that were
created to transfer data between the digitizer and the host memory.
66 ni.com
NI-SCOPE
When you install NI‑SCOPE on a 64‑bit system, you can monitor, control, and record
measurements from supported devices using InstrumentStudio. InstrumentStudio is a
software-based front panel application that allows you to perform interactive
measurements on several different device types, including oscilloscopes, in a single
program.
InstrumentStudio is automatically installed when you install the NI‑SCOPE driver. You
can access InstrumentStudio in one of the following ways:
‑
• From the Windows start menu, select National Instruments»NI‑SCOPE Soft Front
Panel. This launches InstrumentStudio and runs a soft front panel populated with
NI‑SCOPE devices.
• From the Windows start menu, select National Instruments»InstrumentStudio
[year]. This launches InstrumentStudio and runs a soft front panel populated with
devices detected on your system.
• From Measurement & Automation Explorer (MAX), select a device and then click
Test Panels.... This launches InstrumentStudio and runs a soft front panel for the
device you selected.
For more information, refer to NI-SCOPE Soft Front Panel and InstrumentStudio.
Related concepts:
NI-SCOPE Examples
© National Instruments 67
NI-SCOPE
your device and can serve as interactive tools, programming models, and building
blocks for your own applications.
NI Example Finder
The NI Example Finder is a utility that organizes examples into categories and allows
you to browse and search installed examples. For example, search for "SCOPE" to
locate all NI Digitizers signal generator examples. You can see descriptions and
compatible hardware models for each example or see all the examples compatible
with one particular hardware model.
Software
Installed Example Locations
Application
<LabVIEW>\examples\instr\niScope, where <LabVIEW> is the
LabVIEW
LabVIEW directory for the specific LabVIEW version you installed on your system.
LabWindows/ Program Files\IVI Foundation\IVI\Drivers\niScope\
CVI Examples\CVI
<NIDocDir>\NI-SCOPE\examples, where <NIDocDir> is one of the
following directories:
ANSI C or
• Windows 8/7/Vista—Users\Public\Documents\National
Microsoft Visual
Instruments
C/C++
• Windows XP—Documents and Settings\All Users\Shared
Documents\National Instruments
68 ni.com
NI-SCOPE
NI-
SCOPE Description
Example
niScope EX This example opens a session to the NI-SCOPE driver and uses the Auto
Getting Setup VI to optimally configure the session properties and displays the
Started.vi acquired channel data.
This example opens and configures an NI-SCOPE session and allows you
to experiment with numerous configurations, including acquisition types
niScope EX
and triggering modes, since it supports nearly the entire functionality of
Quick Start.vi
NI-SCOPE. It is designed so that if the recommended input signal is used,
most configurations will return valid results.
This example configures all the digitizer's vertical, horizontal, and
niScope EX triggering properties before every acquisition. It allows you to
Configured experiment with numerous configurations, including acquisition types
Acquisition.vi and triggering modes, since it supports nearly the entire functionality of
NI-SCOPE.
niScope EX
This example demonstrates using continuous acquisition to fetch an
Fetch
infinite record of data (until you press "Stop").
Forever.vi
niScope EX
Stream to This example demonstrates streaming a continuous acquisition to disk.
Disk.vi
niScope EX
Advanced This example illustrates using some of the advanced measurement library
Measurement functions such as waveform processing and filtering.
Library.vi
niScope EX
Multi-Device
This example demonstrates how to easily synchronize an arbitrary
Configured
number of digitizers with NI-TClk.
Acquisition
(TClk).vi
© National Instruments 69
NI-SCOPE
Fundamentals
Expand this book for more information on digitizer fundamentals.
Bandwidth
Bandwidth describes the difference between limiting frequencies within which the
input signal can pass through the system with minimal amplitude loss — from the
input at the tip of the probe or test fixture to the output data. The limiting frequencies
that determine the bandwidth include both a high and a low frequency that are
specified as the frequency (in Hz) at which a sinusoidal input signal is attenuated to
70.7% of its original amplitude. This point is known as the -3 dB point.
5
0
–3dB
Gain (dB)
–5
–10
–15
–20
10 100 1000
Frequency (MHz)
The following figure shows the four main areas that can affect the bandwidth of a
digitizer.
ADC Software
Signal From
Outside World
1 2 3 4
70 ni.com
NI-SCOPE
Flatness
–1.0
Median 113.6M 44.3m 119.5m
–1.5 Std dev 22.4k 1.1m 12.4m
–2.0
–2.5
–3.0
–3.5
–4.0
1.0M 10.0M 150.0M
Frequency
Resolution
Resolution is the smallest input voltage change a digitizer can capture. Resolution can
be expressed in bits (LSB), in proportions, or in percent of full scale. For example, a
system has 12-bit resolution, one part in 4,096 resolution, and 0.0244% of full scale.
Resolution limits the precision of a measurement. The higher the resolution (number
© National Instruments 71
NI-SCOPE
of bits), the more precise the measurement. An 8-bit ADC divides the vertical range of
the input amplifier into 256 discrete levels. With a vertical range of 10 V, the 8-bit ADC
cannot ideally resolve voltage differences smaller than 39 mV. In comparison, a 14-bit
ADC with 16,384 discrete levels can ideally resolve voltage differences as small as
610 µV.
Bits Resolution % FS
8 1/256 .390
10 1/1024 .0976
12 1/4096 .0244
14 1/16384 .0061
16 1/65536 .0015
The following figure shows the transfer function of a 3-bit ADC with a vertical range of
5 V having an ideal resolution of 5/8 V/LSB.
Sample Rate
Sample rate, specified in samples per second (S/s), is the rate at which a signal is
sampled and digitized by an analog-to-digital converter (ADC). According to the
72 ni.com
NI-SCOPE
Nyquist theorem, a sample rate at least twice the highest frequency of the signal
produces accurate measurements if the analog bandwidth is wide enough to let the
signal pass through without attenuation. A higher sample rate captures more
waveform details for the time domain measurements. The following figure illustrates a
1 MHz sine wave sampled by a 2 MS/s ADC and a 20 MS/s ADC. The faster ADC digitizes
20 points per cycle of the input signal compared with 2 points per cycle with the
slower ADC. In this example, the higher sample rate more accurately captures the
waveform shape.
1µ
Legend
Related Topics
Undersampling
Oversampling
Related concepts:
• Nyquist Theorem
• Bandwidth
• Undersampling
• Oversampling
Nyquist Theorem
The Nyquist theorem states that a signal must be sampled at least twice as fast as the
highest frequency component of the signal to accurately reconstruct the waveform.
Frequency components higher than half the sample rate are mistakenly interpreted as
© National Instruments 73
NI-SCOPE
The following figure shows the frequency view of the same example.
f
fa fN 5 fs
where
Related Topics
Undersampling
Oversampling
Related concepts:
• Aliasing
• Undersampling
• Oversampling
74 ni.com
NI-SCOPE
Aliasing
In systems where you want to perform accurate measurements using sampled data,
the sampling rate must be set high enough to prevent aliasing, or an optional anti-
aliasing filter must be introduced before the A/D converter to restrict the bandwidth of
the input signal to meet the sampling criteria. An anti-aliasing filter attenuates
unwanted high-frequency signals (which otherwise would appear as undesired,
aliased frequency components) of an analog signal prior to its conversion into a digital
value. The actual bandwidth in which you can make correct measurements without
aliasing is called the alias-free bandwidth. After aliasing has been introduced into a
sampled signal, there is no general way to remove it.
In video applications, several forms of visual aliasing are possible. Temporal aliasing,
where the wheel of a car seems to turn backwards, raster scan aliasing that results in
twinkling on sharp horizontal lines, and stair-step aliasing, where jagged edges appear
on lines running at an angle to the scan.
Related concepts:
• Nyquist Theorem
Oversampling
Related concepts:
• Nyquist Theorem
© National Instruments 75
NI-SCOPE
Undersampling
Related concepts:
• Nyquist Theorem
• Aliasing
Record Length
Record length refers to the number of samples, or data points, the digitizer acquires
for each channel in a single acquisition.
To determine record length, call the niScope Actual Record Length VI or the
niScope_ActualRecordLength function. You can also obtain the record length
using the Actual Record Length property or the
NISCOPE_ATTR_HORZ_RECORD_LENGTH attribute.
Maximum Duration
Record length limits the maximum duration of a single-shot acquisition. For example,
with a 1,000-sample record and a sample rate of 20 MS/s, the duration of acquisition is
50 µs (the number of points multiplied by the acquisition time per sample, or 1,000 x
50 ns. With a 100,000-sample record and a sample rate of 20 MS/s, the duration of the
acquisition is 5 ms (100,000 x 50 ns).
Vertical range is the peak-to-peak voltage span that a digitizer can measure at the
input connector. Most digitizers have several choices for vertical range.
76 ni.com
NI-SCOPE
Vertical offset is the voltage the vertical range is centered on. Vertical offset positions
the vertical range around an arbitrary DC value. Using this offset allows you to examine
small changes in the input signal, which can improve the accuracy of your
measurement.
For example, imagine that you are acquiring the waveform shown in the following
figure that outputs 0.75 V to 1.25 V. Without using vertical offset, you would need to
specify a range of 2.5 V (±1.25 V) to capture the waveform.
1.25 V 1.25 V
1V
1V
–1 V
–1.25 V 0.75 V
Offset = 0 V Offset = 1 V
Range = 2.5 V Range = 0.5 V
Resolution = 2.5 V = 10 mV Resolution = 0.5 V = 2 mV
256 256
Input Coupling
On many digitizers, you can configure the input channels to be DC-coupled, AC-
coupled, or GND coupled. DC coupling allows DC and low-frequency components of a
signal to pass through without attenuation. In contrast, AC coupling removes DC
offsets and attenuates low frequency components of a signal. This feature can be
exploited to zoom in on AC signals with large DC offsets, such as switching noise on a
12 V power supply. GND coupling disconnects the input and internally connects the
channel to ground to provide a ground, zero-voltage reference.
Refer to the specifications for your specific digitizer for input limits that must be
observed regardless of coupling.
When broadband signals are carried on transmission lines of any significant length,
© National Instruments 77
NI-SCOPE
care must be taken that the transmission medium is matched to its terminations. The
source and load impedances should equal the characteristic impedance of the
transmission line, as this minimizes signal reflections. The presence of impedance
discontinuities or mismatches degrades the amplitude and phase accuracy, as well as
the temporal fidelity, of measurements made with a digitizer. The example below
shows one of the most common mismatch errors encountered in such measurements.
Example
Characteristic Impedance = 50 W
Delay = t
75 W
To Digitizer ADC
2V 75 W
Digitizer
Voltage With Matched Cable
0
0 t 3t 5t 7t 9t Time
The pulse encounters impedance mismatches at each end of the cable, whereupon it
is partially reflected. The reflected pulse traverses the cable back and forth numerous
times, diminishing at each end by the reflection coefficient, .
78 ni.com
NI-SCOPE
where
The resulting voltage waveform recorded by the digitizer is distorted by the asymptotic
decay of the reflected pulse as shown, exaggerated for visual effect. Impedance
discontinuities of smaller magnitude and/or duration have correspondingly smaller
effects. Also displayed is the waveform that results when a cable of matched
impedance (75 Ω) is used.
Mismatch Uncertainty
where
Resistive Matching
Signal sources with low (high) source impedance can be matched with a resistor
placed in series (shunt) such that the total source impedance (admittance) is matched
to the cable characteristic impedance (admittance). Sources that are not capable of
driving the cable impedance directly can be coupled through a matching L-pad, an
example of which is shown in the following figure. In this case, the source sees a 500 Ω
load, while the source impedance presented to the cable is 50 Ω. High-frequency
components and layout techniques should be used throughout to minimize parasitic
© National Instruments 79
NI-SCOPE
effects.
Characteristic Impedance = 50 Ω
500 Ω 50 Ω
475 W To Digitizer ADC
56.2 Ω 50 Ω
Probes work with digitizers as part of your measurement system. Signals travel from
the tip of the probe to the input amplifier and are then digitized by the ADC. This signal
path makes the probe an important electrical system component that can affect the
accuracy of the measurement. A probe can potentially influence measured amplitude
and phase, and the signal can pick up additional noise on its way to the input stage.
Although NI high-speed digitizers do not ship with probes, several types of probes are
available, including passive, active, and current probes.
Passive Probes
The passive probe is the most widely used general-purpose probe. Passive probes are
specified by bandwidth (or rise time), attenuation ratio, compensation range, and
mechanical design aspects. Probes with attenuation, X10, X100, or X1000, have a
tunable capacitor that can reduce capacitive effects at the input. The ability to cancel
or minimize effective capacitance improves the probe's bandwidth and rise time. The
following figure shows a typical X10 probe model.
80 ni.com
NI-SCOPE
Rp One-tenth of Signal
(1 Vpk-to-pk) at Input
9M
10 Vpk-to-pk x pF Cp
20 pF 1M
Signal Probe Cin Rin
Compensation
Adjustment
Cc = Lumped Cable
Capacitance
Adjust the tunable capacitor, Cp, to obtain a flat frequency response. Cp is the probe
capacitance, Rp is the probe resistance, Cin is the input capacitance, Rin is the input
resistance of the digitizer.
or the time constant of the probe equals the time constant of the digitizer input.
Active Probes
Active probes, such as differential and field-effect transistor (FET) probes, contain
active circuitry in the probe itself to reject noise and amplify the signal. FET probes are
useful for low-voltage measurements at high frequencies and differential probes are
noted for their high common-mode rejection ratio (CMRR) and nongrounded
reference.
Current Probes
© National Instruments 81
NI-SCOPE
Related Topics
Probe Compensation
Related concepts:
• Probe Compensation
Probe Compensation
Adjusting the tunable probe capacitor to get a flat frequency response is called probe
compensation. Compensating passive probes increases the accuracy of your
measurements by matching the capacitance of your probe to the capacitance of a
particular oscilloscope input channel.
82 ni.com
NI-SCOPE
Accuracy
Accuracy is a measure of the ability of a device to indicate the true value of a measured
signal. Accuracy is usually expressed as a percentage of the specified value, for
example, 5 V ±1%.
Signal Characteristics
Knowing the characteristics of the signal under consideration helps you to choose the
correct settings to maximize measurement accuracy. Such characteristics include:
© National Instruments 83
NI-SCOPE
+127 LSB
+7.7 LSB
0 LSB
–7.7 LSB
–128 LSB
Input Range 10 V
Number of LSBs = 15.4 (600 mV/10 V´256 LSBs = 15.4 LSB)
+127 LSB
+77 LSB
0 LSB
–77 LSB
–128 LSB
Input Range 1 V
Number of LSBs = 154 (600 mV/1 V´256 LSBs = 154 LSB)
+153 LSB
+127 LSB
–128 LSB
–154 LSB
84 ni.com
NI-SCOPE
+V
5V
1 2 3 4
Trigger Level rigger Level
t
Hold-off Hold-off
Ideally, the trigger event should occur at condition one, but sometimes the
instrument may trigger on condition two because the signal crosses the trigger
level. You can solve this problem without using complicated signal processing
techniques by using trigger holdoff, which lets you specify a time from the trigger
event to ignore additional triggers that fall within that time. With an appropriate
holdoff value, the waveform shown in the previous figure can be properly captured
by discarding conditions two and four.
• Input coupling—On many digitizers, you can configure the input channels to be
DC-coupled or AC-coupled. DC coupling allows DC and low-frequency components
© National Instruments 85
NI-SCOPE
Related concepts:
• Resolution
• Impedance and Impedance Matching
• Aliasing
• Nyquist Theorem
• Trigger Holdoff
Noise
Noise is any unwanted signal that appears in your sampled data. Noise comes from
both external sources, such as the AC power line, motors, generators, transformers,
fluorescent lights, soldering irons, CRT displays, computers, electrical storms, welders,
and radio transmitters, and internal sources, such as digital clocks, microprocessors,
and switched mode power supplies.
Noise can be transient in nature, have fixed frequencies such as harmonic or mixer
products, or be broadband random noise.
Some computer chassis can induce ground loop noise in measurements taken with
instruments having grounded input connectors. Spurious DC and low-frequency
content can result. The cause is usually power supply return currents from the
motherboard that partially flow through the computer chassis to the power supply
housing rather than entirely through the power supply cabling.
Follow these guidelines to mitigate the ground loop noise for PCI devices:
1. Ensure that the motherboard is tightly screwed down to the chassis so that chassis
86 ni.com
NI-SCOPE
return currents will flow though the chassis under the motherboard and not in the
vicinity of the PCI boards.
2. Ensure that the power supply cable is well seated on the motherboard.
3. Locate analog input cards in slots furthest away from the power supply.
4. Locate video cards and other high power PCI boards in slots furthest removed from
the analog input cards.
Follow these guidelines to mitigate the ground loop noise for PXI devices:
1. Ensure that the screws on the front panel of the device are tightened down.
2. Ensure that any external equipment that is providing a signal, and is not floating
with respect to ground (for example, it is not a passive sensor or a battery-
operated device), is connected to the same ground as the chassis.
3. On rack mounted systems, ground the chassis to the metal rack mount to reduce
ground loop currents.
Thermal Shutdown
Air circulation paths, fan settings, and space allowances are several factors that can
influence device temperature. To prevent thermal shutdown, follow the guidelines
described in the Maintain Forced-Air Cooling Note to Users document that shipped
with your device. Refer to the specifications document for your device to find the
correct operating temperature range.
In the event that the digitizer powers down, you are notified with an error message in
one of the following ways:
• NI-SCOPE returns an error when you use any of the functions that program the
hardware or check hardware status, for example, the commit function and the self-
calibration function.
• Measurement & Automation Explorer (MAX) returns an error message if you run a
self-test on your device after it exceeds the thermal shutdown temperature.
© National Instruments 87
NI-SCOPE
To re-enable your device after thermal shutdown, use one of the following methods:
• Power down the computer and the chassis that contains the digitizer (required for
the NI PXIe-5185/5186).
• For the NI PXIe-5160/5162, you can disable and enable the device from the Device
Manager.
• For PXI and PCI devices, you can call niScope_ResetDevice or perform a
device reset in MAX. For more information on resetting a device in MAX, select
Help»Help Topics»NI-DAQmx»MAX Help for NI-DAQmx within MAX.
The thermal shutdown error continues to be reported until the device is successfully
reset.
Note
• When overheating occurs on the NI PXI-5122, the Active LED turns red
and the Access LED may turn red, depending on the hardware revision
you have.
• When overheating occurs on the NI PXI-5124/5142/5152/5153/5154/
5922 or the NI PXIe-5122/5185/5186/5622, the Active LED turns red.
• For the NI 5185/5186, you must follow the guidelines described in the
Maintain Forced-Air Cooling Note to Users to prolong the life of the
device. If the NI 5185/5186 goes into thermal shutdown, a power cycle
is required to re-enable the device. You can read the current
temperature of the device using LabVIEW by selecting the Device
Temperature property in the NI-SCOPE property node. It is
recommended that this value stay below 100 °C to maximize the life of
the NI 5185/5186. The NI 5185/5186 will go into thermal shutdown
when its temperature exceeds 107 °C.
Related Topics
88 ni.com
NI-SCOPE
Related concepts:
Triggering
You can use several kinds of triggering with NI high-speed digitizers, including digital,
edge, glitch, hysteresis, immediate, runt, software, video, width, and window
triggering. Each type of triggering uses a different NI-SCOPE Configure Trigger
function.
The following table describes the triggers supported by NI high-speed digitizers. The
Supported Types column denotes which trigger types are valid for a given trigger.
Trigger Supported
Description
Name Types
The Start trigger transitions a device into a state where the device can
Digital respond to Sample clocks. This trigger transitions the device from a
Start
Edge nonsampling state into a sampling state—the device starts acquiring and
storing data.
The Reference trigger transitions a device from the Wait for Reference
Trigger sampling state into the Post Reference trigger sampling state. In the
Analog, Post Reference Trigger sampling state, a counter begins counting Sample
Reference Digital, clock cycles. When the configured number of samples is acquired, the
Video device transitions into a Done state. In other words, the arrival of this
trigger establishes the reference point that separates pretrigger and
posttrigger samples.
Digital The Advance trigger initiates the acquisition of the additional records in a
Advance
Edge multirecord acquisition.
The digitizer acquires pre-reference triggers until the Arm Reference trigger
Arm Digital
is received. For more information, refer to SMC-Based Digitizers Acquisition
Reference Edge
Engine State Diagram.
© National Instruments 89
NI-SCOPE
Related concepts:
• Digital Triggers
• Edge Triggers
• Glitch Triggers
• Hysteresis Triggers
• Immediate Triggers
• Runt Triggers
• Software Triggers
• Video Triggers
• Width Triggers
• Window Triggers
Related information:
Trigger Types
You can use several kinds of triggering with NI high-speed digitizers, including digital,
edge, glitch, hysteresis, immediate, runt, software, video, width, and window
triggering. Each type of triggering uses a different NI-SCOPE Configure Trigger
function.
Related concepts:
• Digital Triggers
• Edge Triggers
• Glitch Triggers
• Hysteresis Triggers
• Immediate Triggers
• Runt Triggers
• Software Triggers
• Video Triggers
• Width Triggers
• Window Triggers
90 ni.com
NI-SCOPE
Immediate Triggers
Immediate triggers occur when the digitizer triggers itself. There is no external signal
that triggers the acquisition—the acquisition simply begins immediately after being
configured by the driver software. Immediate triggering is the default option on NI
high-speed digitizers. Therefore, you can omit using this function if you never change
triggering modes.
Software Triggers
Software triggers occur when a software command starts the acquisition of posttrigger
data. When you call Initiate Acquisition the digitizer starts acquiring
pretrigger data and continues to do so until you call Send SW Trigger. The
digitizer continues to store posttrigger samples after the software trigger, so you still
need to wait for the acquisition to complete after the trigger. You can do this by setting
the timeout parameter in a Fetch function to a positive value. You cannot use a Read
function in conjunction with software triggering; you must use Initiate
Acquisition followed by one of the Fetch functions. The following figure shows the
programming flow using software trigger functions.
Initialize
Opens a session
Initiate Acquisition
Begins acquiring pretrigger data
Fetch
Polls the digitizer until the acquisition is
complete and retrieves the data
Close
Closes the session
© National Instruments 91
NI-SCOPE
Edge Triggers
An edge trigger occurs when a signal crosses a trigger threshold that you specify. You
can specify the slope as either positive (on the rising edge) or negative (on the falling
edge) to the trigger. Edge triggering is possible on all analog trigger channels, such as
0, 1, or the external trigger channel. The following figure shows edge triggering.
Trigger Level
Legend
Negative Edge Trigger Positive Edge Trigger
Glitch Triggers
A glitch trigger occurs when a pulse that crosses a vertical threshold you specify and
with a polarity you specify also has a width that is either greater than or less than a
duration you specify. The oscilloscope can trigger on pulses of positive, negative, or
either polarity.
Use the glitch trigger to detect transient pulses within pulse trains.
You can configure the glitch parameters in NI‑SCOPE using the Analog Glitch Ref
Trigger instance of the Configure Trigger (poly) VI.
92 ni.com
NI-SCOPE
2 2
3 4
2 2
5 6
Legend
1. Trigger level
2. Width
3. Positive glitch trigger (less than)
4. Positive glitch trigger (greater than)
5. Negative glitch trigger (less than)
6. Negative glitch trigger (greater than)
Hysteresis Triggers
Hysteresis triggers eliminate incorrect triggers caused by noisy signals. For example, if
your signal contains two rising edges of different amplitudes, you can use hysteresis
triggering to trigger on one of the edges. Although NI-SCOPE uses a default amount of
hysteresis for edge triggering, which is typically 2.5% of the vertical range, you can
override that value by setting your own hysteresis values. The Configure Trigger
Hysteresis function or VI allows you to choose the trigger coupling, trigger level,
hysteresis value, and trigger slope.
© National Instruments 93
NI-SCOPE
A positive slope hysteresis trigger is generated when the signal crosses below the
voltage specified by the trigger level parameter minus the hysteresis value, and then
crosses the trigger level.
Trigger Level
Trigger
A negative slope hysteresis trigger is generated when a signal crosses above the
voltage specified by the trigger level parameter plus the hysteresis value, and then
crosses the trigger level.
Trigger Level +
Hysteresis Value
Trigger Level
Trigger
Runt Triggers
A runt trigger occurs when both the leading edge and trailing edge of a pulse cross only
one of two trigger thresholds you specify and with a polarity you specify, where the
polarity is relative to the threshold crossed. The oscilloscope can trigger on pulses of
positive, negative, or either polarity.
You can also add time qualification to the runt trigger. A time-qualified runt trigger
captures only those runt pulses that, in addition to meeting your vertical threshold
criteria, have a width either within or outside a duration range you specify. By default,
the runt trigger is not time qualified.
Use the runt trigger to debug digital systems by capturing pulses that could represent
94 ni.com
NI-SCOPE
You can configure the runt trigger parameters in NI‑SCOPE using the Analog Runt Ref
Trigger instance of the Configure Trigger (poly) VI. Use NI‑SCOPE properties to time-
qualify the runt trigger.
Legend
Video Triggers
A video trigger occurs when the digitizer finds a valid video signal synchronization.
Refer to NI 5114/5122/5124/5142 Video Triggering for more information.
Related information:
© National Instruments 95
NI-SCOPE
• Video Triggering
Width Triggers
A width trigger occurs when a pulse that crosses a vertical threshold you specify and
with a polarity you specify also has a duration that is either within or outside a
duration range you specify. The oscilloscope can trigger on pulses of positive,
negative, or either polarity.
Use the width trigger to detect transient pulses with a duration that falls within or
outside of a known range.
You can configure the width trigger parameters in NI‑SCOPE using the Analog Width
Ref Trigger instance of the Configure Trigger (poly) VI.
2 2 2
3 3 3
6 7 6
2 2 2
3 3 3
Legend
1. Trigger level
2. Width low threshold
3. Width high threshold
96 ni.com
NI-SCOPE
Window Triggers
A window trigger occurs when a signal either enters or leaves a window you specify
with the window mode parameters in the Configure Trigger Window function.
Window triggering is possible on all analog trigger channels, such as 0, 1, or the
external trigger input.
High Level
Low Level
Trigger Trigger
High Level
Low Level
Trigger Trigger
Digital Triggers
A digital trigger occurs on either a rising edge or falling edge of a digital signal. Digital
triggering is possible on the RTSI lines, PFI lines, and the PXI Star Trigger line.
© National Instruments 97
NI-SCOPE
Related concepts:
• RTSI Bus
• PFI Lines
• PXI Star Trigger Line
Burst Triggers
To trigger on data bursts, you can configure the digitizer to wait until it detects a quiet
period before arming the trigger. Use the Min Quiet Time property or the
NISCOPE_ATTR_REF_TRIGGER_MINIMUM_QUIET_TIME attribute to set the
length of this quiet period.
The following figure shows how burst triggers occur after a configured minimum quiet
time of 1.5 seconds. The trigger occurs at point A because the minimum quiet time of
1.5 seconds has been exceeded—in this case, 2 seconds have elapsed since a signal
above the trigger level was detected. A trigger does not occur at point B because only 1
second of quiet time has elapsed.
98 ni.com
NI-SCOPE
Trigger Parameters
Common NI-SCOPE trigger parameters include trigger holdoff, trigger delay, and
trigger coupling.
Related concepts:
• Trigger Holdoff
• Trigger Delay
• Trigger Coupling
Trigger Holdoff
Trigger holdoff is an adjustable period of time during which the digitizer cannot trigger.
NI high-speed digitizers use trigger holdoff to guarantee a minimum time between two
Reference Triggers. This feature is useful if incoming triggers are a known time apart
and only a relatively small window of samples adjacent to the trigger are necessary. In
this case, setting the holdoff allows you to efficiently allocate the onboard memory,
and prevents the device from triggering on sections of the input waveform that are not
© National Instruments 99
NI-SCOPE
Trigger
Level
Legend
Note Trigger holdoff is not supported by all digitizers. Some digitizers allow
only trigger holdoff or trigger delay at any given time. Refer to Features
Supported by Device to find out which digitizers support trigger holdoff.
The details of how holdoff is implemented on each device varies. Refer to the device-
specific help sections for more information on your particular digitizer.
Trigger Delay
Trigger delay is the amount of time that elapses between when a trigger occurs and
when the digitizer actually triggers.
In NI-SCOPE, the trigger delay parameter specifies this time period, (in seconds). For
example, setting a 1 second trigger delay means the digitizer continues to acquire
pretrigger samples for 1 second after it is triggered. The posttrigger samples occur
after the delayed trigger.
100 ni.com
NI-SCOPE
Acquired Waveform
Trigger Delay
Trigger 50% Reference Position
Note Trigger delay is not supported by all digitizers. Some digitizers allow
only trigger holdoff or trigger delay at any given time. Refer to Features
Supported by Device to find out if your digitizer supports trigger delay.
Related topics:
• Trigger Parameters
Trigger Coupling
The trigger coupling parameter can be either AC, DC, HF Reject, LF Reject, or AC Plus
HF Reject. This parameter works much like the vertical coupling parameter. When AC
is selected, NI-SCOPE rejects the DC component of the trigger signal. When triggering
on channel 0 or channel 1 of the digitizer, the input signal is immediately coupled
based on the vertical coupling parameter. Therefore, if the vertical coupling
parameter is set to AC coupling, triggering occurs on the AC components of the signal
because the DC component has already been removed.
Related concepts:
• Input Coupling
Sample Clock
The sample clock is sent to the ADC of each channel and to the acquisition engine to
control the sampling rate of a digitizer. The sample clock sources are as follows.
High-speed digitizers and oscilloscopes have an onboard (internal) clock that controls
the sampling rate as well as other timing functionality of the device. In most cases, the
onboard oscillator is a Voltage Controlled Crystal Oscillator (VCXO). Typically, an
onboard DAC (digital to analog converter) is used to calibrate the VCXO to exactly the
desired clock rate. This DAC can also be used to adjust the frequency of the VCXO to
phase lock it to a reference clock. The maximum sampling rate of a device is usually
determined by the speed of the onboard clock. However, other sampling rates can be
achieved by two methods; decimation of the data or dividing down the onboard clock.
Decimation Method
In the decimation method, the ADC samples at the rate of the onboard clock and then
sends its digital data to a decimator that essentially discards samples at a specific
interval to achieve slower effective sampling rates. The valid sampling rates are always
an integer divisor of the onboard clock. For example, if the onboard clock is 100 MHz
but you want to sample at 25 MS/s, you must use decimation. The decimation method
would discard all data except for every fourth datapoint to achieve exactly 1/4 of the
maximum sample rate (or onboard clock rate).
Some oscilloscopes use the divide down clock method. In this method the onboard
clock is sent through a series of clock dividers, and then that clock is sent to the ADC.
102 ni.com
NI-SCOPE
Typically, the decimation method is preferred over the divide down clock method.
Some digitizers and oscilloscopes can accept an external sample clock. This external
sample clock is used to replace the onboard clock (the VCXO) for synchronization or to
achieve a sampling rate that cannot be specified by using the onboard clock. Some
devices can also decimate the external sample clock to achieve a sampling rate that is
an integer divisor of the external sample clock. For example, if the external sample
clock is 70 MHz, you could decimate the clock by a factor of 2 and achieve a 35 MS/s
sampling rate.
Note Not all devices support the option for an external sample clock and/or
decimation of that clock. Refer to Features Supported by Device for more
information. If your device does not support external sample clocks, refer to
reference clock for another method of synchronization.
Related concepts:
The reference clock is used in the phase-locked loop (PLL) circuit of a digitizer to
synchronize the internal oscillator to the reference clock. The frequency stability of the
internal oscillator matches that of the PLL reference clock when the two are phase
locked. In turn, phase locking synchronizes clocks of multiple devices that are phase
locked to the same reference clock. The most common frequency for a reference clock
is 10 MHz because a clock of that frequency can generally be shared over a cable
without much attenuation or loss. However, the frequency range of reference clocks
can vary anywhere from 1 MHz to 20 MHz. Refer to the Devices section of this help file
to determine what your device supports. The following figure shows a block diagram
of a basic PLL.
Frequency Voltage
Frequency
Reference Phase Detector Low Pass Filter Controlled
Output
Oscillator
The operation of this circuit is typical of all PLLs. A PLL is a feedback control system
that controls the frequency and phase of a voltage controlled oscillator (VCO). The
input signal is applied to a phase detector. The output of the VCO connects to the other
input. As shown in the previous diagram, the frequencies of both signals are the same.
The output of the phase detector develops a voltage proportional to the phase
difference between the two input signals. The lowpass filter receives this signal from
the phase detector. The lowpass filter determines the dynamic characteristics of the
PLL. The filtered signal controls the VCO.
Time Stamping
NI-SCOPE returns time stamps with every Fetch function, if the digitizer supports
them, in the waveform info structure. This structure contains both absolute initial x
and relative initial x parameters. The absolute initial x parameter is the time of the
first point in the waveform in units of seconds, and it has a resolution of the maximum
real-time sampling period of the digitizer (such as 10 ns for a 100 MS/s digitizer). This
time is valid between records and entire acquisitions, provided the clock is not reset.
The relative initial x parameter, which is supported by all digitizers, is the time
between the first point in your waveform and the trigger. Therefore, the trigger always
occurs at time equals zero. It includes the interpolated TDC. This conversion measures
when the trigger occurs between two samples. Keep in mind that the relative initial x
104 ni.com
NI-SCOPE
value is not valid until a trigger occurs when using continuous acquisition. To compute
an absolute trigger time that includes the TDC value, use the following formula:
The time it takes for the time stamp counter to roll over depends on the number of bits
in the time stamp counter and the clock frequency. For instance, the rollover would
occur for an NI 5114/5122/5124/5142/5922 if it runs for 5849 years. If the rollover
occurs, NI-SCOPE returns a warning.
The Timestamps example uses time stamps to compute a histogram of the time
between triggers. You can use this example to calculate the minimum time required
between records. You can find the Timestamps example by using the shortcut
Start»All Programs»National Instruments»NI-SCOPE»Examples.
Related concepts:
• TDC
TDC
A time-to-digital converter (TDC) is a circuit that is used to measure the time between
two events. For digitizers, the TDC measures the time elapsed from when a trigger is
received by the digitizer to the time the first sample is taken.
Sampled Data
Trigger
Level
Trigger
Sampling Methods
The sampling method you use determines how the digitizer collects sample points.
Depending on whether the signal is changing slowly or quickly, you can choose one of
the following methods to collect samples:
• Real-Time Sampling
• Random Interleaved Sampling (RIS)
• Time Interleaved Sampling (TIS)
Related concepts:
• Real-Time Sampling
• Equivalent-Time Sampling and Random Interleaved Sampling
• Time Interleaved Sampling
Real-Time Sampling
106 ni.com
NI-SCOPE
Related Topics
Random-Interleaved Sampling
Related concepts:
Note NI-SCOPE does not support using RIS with multi-instrument NI-
SCOPE sessions.
Each waveform trigger occurs at some time randomly distributed between two
samples. The digitizer can measure the time from the trigger to the next sample,
commonly called the time-to-digital conversion (TDC), extremely accurately—with
hundreds of times more resolution than the sample period of the digitizer. With these
TDC measurements, NI-SCOPE can combine multiple waveforms, aligned at the trigger
time, to simulate a faster sampling rate for repetitive signals.
When a digitizer is in RIS mode, the legal sample rates become multiples of the
maximum real-time sampling rate. These multiples are the oversampling factor. For
example, for a digitizer that has a 100 MS/s maximum real-time sampling rate, the RIS
sampling rates are the oversampling factor times 100 MS/s, where the oversampling
factor is two, three, four, and so on. If you specify 300 MS/s for your sampling rate, the
oversampling factor is three.
Each TDC value is between zero and the sampling period, so a 100 MS/s digitizer has
TDC values between 0 and 10 ns. This time span is divided into a number of bins equal
to the oversampling factor. For example, an oversampling factor of three means there
is one TDC bin from 0 to 3.33 ns, another from 3.33 to 6.67 ns, and another from 6.67 to
10 ns. To reconstruct a waveform, each bin must contain at least one TDC value.
The following four figures show an example RIS acquisition with an oversampling
factor of three. Each of the figures shows the aligned trigger time of the waveforms
followed by the three TDC bins, where the combined width of the three bins is the real-
time sample period of the digitizer.
1. The first waveform has a TDC value that falls in bin number 1.
Legend
Acquisition 1
108 ni.com
NI-SCOPE
Legend
Acquisition 1 Acquisition 2
3. Because of the randomness of the TDC value, another sampled waveform falls in
bin 1. NI-SCOPE does not fetch this waveform from the digitizer because the bin is
already filled.
Legend
Acquisition 1 Acquisition 2 Acquisition 3
Legend
Acquisition 1 Acquisition 2 Acquisition 4
Now all bins are full, so NI-SCOPE returns the three waveforms sampled at the
maximum real-time rate as one evenly-sampled waveform with a sampling rate three
times greater.
At a minimum to complete an RIS acquisition, the number of TDC values must be equal
to the oversampling factor. However, this does not guarantee a cleanly reconstructed
signal. The following figures show three acquisitions of a perfectly linear edge.
The following figure shows that the sample in bin number 1 is extremely close to its
right-hand bin edge. When NI-SCOPE returns the RIS waveform, this sample is coerced
to the middle of the bin. In similar fashion, each sample is coerced to the center of its
bin.
110 ni.com
NI-SCOPE
Legend
Acquisition 1
The following figure shows how NI-SCOPE returns the RIS waveform, with evenly-
spaced samples.
Legend
Acquisition 1 Acquisition 2 Acquisition 3
waveforms in each bin during the RIS algorithm. The number of averages in
each bin can be specified with the RIS Num Averages attribute of NI-SCOPE.
The following figure shows the acquisition using two averages. Notice that twice as
many waveforms are required now.
Legend
Acquisition 1 Acquisition 2 Acquisition 3
The following figure shows the returned waveform from the averaged RIS acquisition.
112 ni.com
NI-SCOPE
Legend
Acquisition 1 Acquisition 2 Acquisition 3
The higher the number of averages, the smaller the effect of coercing the time of
samples. Therefore, it is generally important to use some amount of averaging with
RIS. Increasing the amount of averaging increases the minimum number of waveforms
necessary to reconstruct the RIS waveform and therefore, the time it takes to complete
an acquisition.
When using RIS, remember that the TDC value is completely random—the hardware
does not adjust anything to ensure an even distribution of TDC values. If the TDC is the
same from two acquisitions, the digitizer has effectively sampled the same places on
the repetitive waveform, so no information has been gained. Therefore, for RIS to
work, you must have a suitable random distribution of TDC values, which requires a
nondeterministic number of waveforms. While it can take a long time to receive a
suitable set of waveforms with different TDC values, in practice you rarely need to wait
long. Furthermore, NI-SCOPE employs multirecord acquisitions and continuous
acquisition when possible to optimize reconstructing the waveform while the
acquisition is in progress.
Note Sometimes an RIS acquisition times out and does not complete. If
increasing the timeout value does not solve the problem, you may need to
self-calibrate the digitizer. This timeout can also occur if the digitizer is
frequency locked to the same reference as the frequency source.
Related concepts:
Time Interleaved Sampling (TIS) is a technique to increase the real-time sample rate of
a digitizer. TIS uses multiple analog-to-digital converters (ADCs) to sample the same
input waveform, but at different relative phases. The hardware then interleaves these
samples to create the waveform as if only one ADC were sampling the waveform at a
higher sample rate.
Note To use time interleaved sampling for the NI 5152, 5153, and 5154, set
the Enable TIS property or the
NISCOPE_ATTR_ENABLE_TIME_INTERLEAVED_SAMPLING attribute to
TRUE. For all other devices, TIS is enabled automatically by setting the
sample rate. The Enable TIS property is ignored.
When you enable TIS on a channel, the digitizer samples the input signal of that
channel using more than one ADC. The clocks of these ADCs are shifted to a phase that
reflects the time when an ADC of a higher sample rate would acquire a point. An
example is shown in the following figure.
114 ni.com
NI-SCOPE
ADC 1
ADC 2
ADC 1
ADC 2
ADC 1 + ADC 2
To obtain a 2 G/s TIS rate using two ADCs, each operated at 1 G/s, the 1 GHz clock of
one ADC is shifted 180 degrees with respect to the 1 GHz clock of the other ADC.
The data returned is in order and is acquired in real time. Therefore, the input signal is
not required to be repetitive.
Because multiple ADCs are used in TIS, it is possible for mismatch between ADCs and
phase offset between clocks to cause small changes in the spectral performance of the
digitizer. NI digitizers calibrate most of these changes out, but some small residual
changes may persist. It may be important, particularly in frequency domain
applications, to understand the following effects.
• Offset Mismatch—If the ADCs are not perfectly matched in DC offset, a small spur
can appear at DC and at the Nyquist frequency (Sample Rate/2).
• Gain Mismatch—If the ADCs are not perfectly matched in DC gain, spurs occur at
image frequencies of input signal frequencies. The size of the image spurs are
proportional to the amount of gain mismatch.
• Phase Offset—If the ADCs are not sampling at exactly the correct phase for the
interleaving factor, images of the frequency content similar to those found with
gain mismatch will occur.
Expand this book to view the frequency domain topics, or click one of the following
links:
• SFDR
• THD
• SINAD
• ENOB
Related concepts:
Spurious free dynamic range (SFDR) is the usable dynamic range before spurious noise
interferes with or distorts the fundamental signal. The amplitude of the fundamental
signal is usually -1 dBFS. SFDR is the measure of the ratio in amplitude between the
fundamental signal and the largest harmonically or non-harmonically related spur
from DC to the full Nyquist bandwidth (half the sampling rate). A spur is any frequency
bin on a spectrum analyzer, or from a Fourier transform, of the analog signal. SFDR is
expressed in dBc.
116 ni.com
NI-SCOPE
Largest Spur
fN fS/2 fS
Frequency
THD
The total harmonic distortion (THD) of a signal is the ratio of the sum of the powers of
the first five harmonics above the measured fundamental frequency to the power of
the fundamental frequency. THD is usually expressed in dB or dBc. Measurements for
calculating the THD are made at the output of a device under specified conditions.
SINAD
ENOB
where A is the input amplitude and V is the full scale range of the ADC.
The ENOB indicates that the ADC is equivalent to an ideal ADC of this number of bits.
Related concepts:
• SINAD
Video Fundamentals
Expand this topic for information about the fundamentals of video signals.
A composite video signal is a signal in which all the components needed to generate a
video signal are embedded in a single signal. The three main components that
together form a composite signal are as follows:
The monochrome composite signal is built of two components: luma (or luminance)
and synchronization. This signal, which is usually called the Y signal, is shown in the
following figure.
150
IRE Y = Luminance signal
100
50
0
Hsync
-50
0 5 10 15 20 25 30 35 40 45 50 55 60 us 65
118 ni.com
NI-SCOPE
The chroma signal by itself, which is usually called the C signal, is shown in the
following figure.
100
C = Color Signal
50
IRE
0
Burst
–50
–100
0 5 10 15 20 25 30 35 40 45 50 55 60 65
µs
Color Information Signal for a Color Bar Line (Including the Color Burst)
The composite color video signal, often called the Color Video, Blank, and Sync (CVBS)
signal, is the sum of Y and C.
CVBS = Y + C
150
Composite Signal
100
IRE
50
-50
0 5 10 15 20 25 30 35 40 45 50 55 60 65
µs
The two components Y and C can also be distributed separately as two independent
signals. These two signals together are called either Y/C or S-video.
Y/C = S-video
A component video signal is a signal in which all the color components needed to
generate a video signal are transmitted separately. Most HDTV formats are component
(Y-Pb-Pr).
The most common standard video formats (NTSC, PAL, and SECAM) are known by
acronyms. Sometimes extra letters are appended to the front of the names to indicate
the refresh rate. For example, M-PAL and M-NTSC have a refresh rate of 59.94 fields per
second.
The definition of standard composite video signal formats differs from country to
country.
Other video signal formats such as HDTV (high-definition television) and EDTV
(enhanced-definition television) are named using characteristics of the video format.
For example, an HDTV video format with 1,080 active horizontal lines using an
interlaced scheme with a refresh rate of 30 fields per second is designated as 1080i/30
fps. If the video signal format is changed to use a progressive scheme, the name would
change to 1080p/30 Fps.
Note Fps = Frames per second, used in progressive formats; fps = fields per
second, used in interlaced formats.
EDTV Formats
• 480i/59.94 fps
• 480i/60 fps
120 ni.com
NI-SCOPE
• 480p/59.94 Fps
• 480p/60 Fps
• 576i/50 fps
• 576p/50 Fps
Scanning Speed
The scanning speed is the number of video frames generated per second. The
scanning speed and the number of lines per frame depend on the video format. NTSC
specifies a scanning speed of approximately 30 frames per second and 525 lines per
frame while PAL and SECAM specify a rate of 25 frames per second and 625 lines per
frame.
Color Coding
The color information signal C, together with Y, forms the composite video signal is a
modulated signal. The modulation type depends on the video format.
For all PAL and NTSC formats, the coding is based on the Quadrature Amplitude
Modulation (QAM) concept, where 2-color components are amplitude modulated in
quadrature and then combined. The modulation must be decoded, so to keep track of
the absolute phase needed to decode the color information, a reference signal, called
the color burst, is inserted at the beginning of each line, right after the horizontal
synchronization pulse. The insertion signal is shown in the Complete NTSC Frame Scan
image.
For the SECAM format, the 2-color components are frequency modulated using two
different subcarrier frequencies and are sequentially distributed on alternated video
lines. SECAM does not need a color burst signal.
Related concepts:
Interlaced Scanning
All composite video systems display the video image on a TV screen using an
interlaced scanning technique. The following figure shows the interlaced scanning
concept.
Even
Odd
The analog video signal includes synchronization pulses that control the scanning line-
by-line from left to right and field-by-field from top to bottom. The pulses that control
the line-by-line scanning are called the horizontal synchronization pulses (Hsync). The
pulses that control the vertical scanning are called the vertical synchronization pulses
(Vsync).
122 ni.com
NI-SCOPE
Two interlaced fields compose a complete frame. The first field, called the odd field,
scans the odd lines of the video image. The second field, called the even field, scans
the even lines of the video image. The process repeats for every frame.
Related concepts:
The following figure shows the result of scanning all 525 lines that compose a
complete NTSC frame.
The Complete NSTC Frame Scan image simulates the video display that would appear
on a television screen if the following conditions were true:
• The television could show the entire line instead of just the active image part.
• The television was not interlacing the two fields to form a complete image frame,
but instead was displaying a progressive scanning, line by line, of the entire frame.
The scanning starts (line-by-line from top to bottom) with a number of lines that
represent the vertical synchronization pattern for the odd field. Immediately after the
vertical synchronization pattern for the odd field, optional insertion test signals (ITS)
are inserted. Finally, the actual odd field active image displays.
The process repeats for the even field, forming the complete frame.
The extracted line profile example at the bottom of the figure shows an actual video
signal line extracted from the even field. Refer to Video Levels for more information.
Horizontal synchronization pulses are basically simple negative pulses, which are
pulses going below the level of the luminance signal. However, the vertical
synchronization signals are composed of pulse trains distributed on several lines, and
the pulse trains are different for odd and even fields. The following figures show the
vertical synchronization patterns for both fields and for several main video formats.
Vertical Blanking and Synchronization Signal for M-NTSC, M-PAL, and 480i
Start of VSync
Field I
1 2 3 4 5 6 7 8 9 10 # 18 19
Field II
262 263 264 265 266 267 268 269 270 271 272 272 # 281 282
124 ni.com
NI-SCOPE
Start of VSync
Field I
524 525 1 2 7 8 13 14 15 16 45
Vertical Blanking and Synchronization Signal for B/G-PAL, SECAM, and 576i
Start of VSync
Field I
621 622 623 624 625 1 2 3 4 5 6 7
Field II
308 309 310 311 312 313 314 315 316 317 318 319 320
Start of VSync
Start of VSync
Start of VSync
1123 1125 1 2 3 4 5 6 7 21
Field I
560 562 563 564 565 566 567 568 569 584
Field II
Field I
Related concepts:
Active Image
The active video image resulting from the scanning always has an aspect ratio
(horizontal/vertical) of 4/3, independent of the video format. The color composite
video signal shows that the scanning process requires some additional room on the
left and right sides of each line, as well as on the top and bottom of the active video
image region. This additional room includes the synchronization signals, color bursts,
and other format-specific information, like the ITS, which are not part of the active
video image. Approximately 90% of all the lines and 80% of each line can transmit the
active image information. The exact values depend on the video format, as shown in
the following table.
126 ni.com
NI-SCOPE
Video Format Lines/Frame Active Lines Frame Rate Line Duration Active Line Duration
NTSC 525 480/486 29.97 frames/sec 63.55 µs 52.2 µs
PAL/SECAM 625 576 25.00 frames/sec 64.00 µs 52.0 µs
Active Lines represents the number of lines that are actually used to transmit the
image information. For example, only 480 lines out of 525 lines/frame transmit the
image information in NTSC. Likewise, on each line, the image information is
transmitted only during the active lines sequence, which is shorter than the entire line
duration. For example, of 63.55 µs only 52.2 µs are the active line duration in NTSC.
Frame rate is the scanning speed described in Scanning Speed.
Related concepts:
Video Levels
The video levels define the levels and ranges for the different parts of the video signal.
The unit used to define video levels is the IRE (Institute of Radio Engineers). The
blanking level refers to 0 IRE and the white level refers to +100 IRE. The blanking level,
which is the reference level for the video signal (usually 0 V), is different from the black
level if a setup is applied to the signal as shown in the following figure.
140
Peak Level
120
80
60
IRE
40
20 Burst Amplitude
Black Level
0 Blanking Level
–20
0 2 4 6 8 10 12 14 16
µs
For NTSC, a setup of 7.5 IRE is usually applied, moving the black level to +7.5 IRE. For
PAL and SECAM, the black level is aligned with the blanking level at 0 IRE.
The following table shows the different video levels depending on the video format.
The analog composite video signal is defined as a voltage source with an output
impedance of 75 Ω. The sync-to-white level is normally 1 Vpk-pk when loaded with a
75 Ω resistance. Therefore, the unloaded signal is nominally 2 Vpk-pk.
Waveform Measurements
NI-SCOPE waveform measurements offer you another method for fetching data from
NI high-speed digitizers. The measurements are processed in software instead of on
the digitizer hardware. The results are scalar or array measurements. Scalar
measurements refer to calculations such as rise time and frequency, which take the
128 ni.com
NI-SCOPE
time-domain data and produce a single value, whereas array measurements transform
the time-domain data into a new waveform, such as an FFT amplitude spectrum.
Related Topics
Related concepts:
Reference Levels
Reference levels are high, low, and mid range values that you set to take rise time, fall
time, width negative, width positive, duty cycle positive, and duty cycle negative
measurements. Reference levels are generally configured in terms of the percentage of
the waveform you acquire. By default, the low value is 10% of the waveform, the mid
level is 50%, and the high value is 90%.
Use the channel-based attributes to set the reference levels. Refer to Attributes and
Attribute Functions for an overview of attributes.
You can customize how NI-SCOPE configures the percentages used for the reference
levels with the Percentage Method attribute. This attribute uses any of the following
constants:
• Min Max—This method uses the measurement's voltage minimum and voltage
maximum as 0% and 100%. These algorithms find the absolute minimum and
maximum in the waveform, which is useful for sine waves and triangle waves
where the histogram method does not work.
• Low High—This method uses the measurement's voltage low and voltage high as
0% and 100%. The voltage low is the voltage of the histogram bin with the most
hits below 40% of the waveform's voltage peak-to-peak value. The voltage high is
the voltage of the histogram bin with the most hits above 60% of the waveform's
voltage peak-to-peak value. These measurements use the last-acquisition
histogram method to find the most common high and low voltages, which is useful
for ignoring the preshoot and overshoot on a square wave.
• Base Top—The voltage base and voltage top measurements correspond to 0% and
100% with this method. These measurements use the last-acquisition histogram
method if the most common histogram bin contains a substantial number of the
total points. Otherwise, it returns the absolute minimum and maximum values in
the waveform. This is a useful default value for most waveform types.
You can also configure the reference levels in terms of voltage with the Ref Level Units
property or the NISCOPE_ATTR_MEAS_REF_LEVEL_UNITS attribute.
Related concepts:
Hysteresis Percent
All scalar measurements involving time use the concept of reference-level crossings,
which occur when the waveform voltage crosses the reference level. Linear
interpolation accurately estimates the crosspoint times, but noise can create a higher
number of level crossings. To minimize the impact of noise, you can create a hysteresis
window around crosspoints. To count a crossing, the signal must start outside this
window and then pass through the window to the crosspoint. A crossing is not
130 ni.com
NI-SCOPE
counted again until the signal passes outside the window and then passes through the
window to the crosspoint. The following figure shows an exaggerated example of
digital hysteresis, where the dots are the real crosspoints after eliminating the spurious
crosspoints caused by noise.
Vertical Hysteresis
Hysteresis Range ´ Percent
=
Window Size 100
Legend
Crosspoints counted for Measurement Reference Level
Last-acquisition histogram method is used by the voltage low and voltage high
measurements for computing the extrema of a waveform. This method is useful for
ignoring overshoot or preshoot in a square waveform. In this method, a voltage
histogram is created from the most recent acquisition. The limits of this histogram are
set by the minimum and maximum voltages of the acquisition. NI-SCOPE then counts
how many samples fall into each bin of the histogram. The resolution is defined by the
Last Acquisition Histogram Size attribute, which is 256 bins by default. You can fetch
the histogram array using the Fetch Array Measurement function, with Last Acquisition
Histogram constant specified as the array measurement function. The following
illustrations show an example of a square wave and its resulting histogram. In the
histogram the voltage low and voltage high measurements correspond to the middle
value of a bin with the maximum number of hits in the lower 40% or upper 40%
respectively.
Voltage Max
Voltage High
Voltage Low
Voltage Min
Hits
Min Lo Hi Max
Smoothing Windows
132 ni.com
NI-SCOPE
amplitude of these discontinuities, the greater the spectral leakage. A simple way to
avoid this is to use smoothing windows when applying an FFT on finite-length data.
You can use smoothing windows to reduce the amplitude of the discontinuities at the
boundaries of each period. This technique multiplies the time record by a finite length
window whose amplitude varies smoothly and gradually towards zero at the edges. In
the following figure, the original time signal shown in FFT with Spectral Leakage is
windowed using a Hanning window.
The following figure shows that the FFT of this data is significantly less noisy than the
non-windowed FFT shown in FFT with Spectral Leakage.
Choosing the correct window to use requires some prior knowledge of the signal that
you are analyzing. The following table shows the different types of windows and the
signal types they are appropriate for.
Window
Type and Description Applications
Signal
Order tracking, system analysis (frequency
Transient signals that are shorter
Rectangular response measurements) with pseudorandom
than the length of the window;
(no excitation, separation of two tones with
truncates a window to within a
window) frequencies very close to each other, but with
finite time interval.
almost equal amplitudes.
General-purpose applications, system analysis
Transient signals that are longer
Hanning (frequency response measurements) with
than the length of the window.
random excitation.
Transient signals that are longer
than the length of the window; a
Hamming modified version of the Hanning Often used in speech signal processing.
window that is discontinuous at
the edges.
Transient signals; similar to
Hanning and Hamming windows
Blackman General-purpose applications.
but adds one additional cosine
term to reduce ripple.
Window that is the shape of a
Triangle No special applications.
triangle.
Has the best amplitude accuracy
Accurate single tone amplitude measurements
of all the windows but comes at
Flat top when there are no nearby frequency
the expense of frequency
components.
selectivity.
Note In cases in which you do not have sufficient prior knowledge of the
signal, you may need to experiment with different windows to find the best
one.
Related concepts:
• Spectral Leakage
• FFT with Spectral Leakage
134 ni.com
NI-SCOPE
Spectral Leakage
When you use the discrete Fourier transform (DFT) or Fast Fourier Transform (FFT) to
find the frequency content of a signal, it is assumed that the data that you have is a
periodically repeating waveform. In the following figure, the first period shown is the
one sampled. Notice that the waveform has not completed an entire cycle, which
creates a discontinuity when the waveform is repeated to produce the periodic
waveform.
Time
Related concepts:
In the following figure, you see the spectral representation when you sample a
noninteger number of cycles of the time waveform (namely 10.25). The periodic
extension of this signal creates a discontinuity similar to the figure shown in Spectral
Leakage.
Notice how the energy is now spread over a wide range of frequencies, so the relative
height difference between the FFT peak amplitude and the neighboring bins is
reduced. This smearing of the energy is called spectral leakage.
Related concepts:
• Spectral Leakage
The following figure shows a sine wave sampled from an NI digitizer and its
corresponding FFT amplitude spectrum in decibels. The time-domain waveform has
an integer number of cycles (10), so the assumption of periodicity does not create any
discontinuities.
136 ni.com
NI-SCOPE
Digital Filtering
Analog filter design is one of the most important areas of electronic design, but it is
often reserved for specialists because it requires advanced mathematical knowledge
and understanding of the processes involved in the system affecting the filter. With the
digital filters in NI-SCOPE, however, you do not have to be a design expert. NI-SCOPE
handles all the design issues, computations, memory management, and actual
filtering internally.
Although digital filters have advantages over analog filters, they have disadvantages
such as floating-point precision limitations, numerical instability, quantization noise,
and frequency warping.
Types of Filters
Filters alter or remove unwanted frequencies. Depending on the frequency range that
they either pass or attenuate, they can be classified into the following types:
• A lowpass filter passes low frequencies, but rejects (or attenuates) high
frequencies. To specify the cut-off frequency, use the Measurement Filter Cutoff
Frequency attribute.
• A highpass filter passes high frequencies, but attenuates low frequencies. To
specify the cut-off frequency, use the Measurement Filter Cutoff Frequency
attribute.
• A bandpass filter passes a certain band of frequencies and attenuates others. To
specify the bandpass filter, use the Measurement Filter Center Frequency attribute
and the Filter Width attribute, where the cut-off frequencies are the center
frequency plus or minus one-half width.
• A bandstop filter attenuates a certain band of frequencies and passes others. To
specify the bandstop filter, use the Measurement Filter Center Frequency attribute
and the Measurement Filter Width attribute, where the cut-off frequencies are the
center frequency plus or minus one-half width.
• An ideal filter has a gain of one (0 dB) in the passband so that the amplitude of the
signal neither increases nor decreases. The stopband (SB) corresponds to that
range of frequencies that do not pass through the filter at all and are rejected
(attenuated).
Amplitude
Amplitude
Frequency Frequency
fc fc
Lowpass Highpass
Amplitude
Amplitude
Frequency Frequency
fc1 fc2 fc1 fc2
Bandpass Bandstop
138 ni.com
NI-SCOPE
Infinite Impulse Response (IIR) Versus Finite Impulse Response (FIR) Filters
If the impulse response of the filter falls to zero after a finite amount of time, it is
known as a FIR filter. However, if the impulse response exists indefinitely, it is known as
an IIR filter. Whether the impulse response is finite (that is, whether the filter is FIR or
IIR) depends on how the output is calculated. The basic difference between FIR and IIR
filters is that for FIR filters, the output depends only on the current and past input
values, whereas for IIR filters, the output depends not only on the current and past
input values, but also on the past output values. The advantage of digital IIR filters
over FIR filters is that IIR filters usually require fewer coefficients to perform similar
filtering operations. Thus, IIR filters execute much faster and do not require extra
memory, because they execute in place. The disadvantage of IIR filters is that the
phase response is nonlinear. If the application does not require phase information,
such as amplitude spectrum analysis, IIR filters may be appropriate. You should use
FIR filters for those applications requiring linear phase responses.
IIR Filters
Filters are classified as infinite impulse response (IIR) filters if the impulse response
exists indefinitely. For IIR filters, the output depends not only on the current and past
input values, but also on the past output values.
Because IIR filters depend on the output and the input, there is a transient response at
the beginning of the filtered data that is invalid, due to the assumptions made at the
beginning boundary condition. This is due to the assumption that negative indices in
the general IIR difference equation are zero. NI-SCOPE IIR filters remove the user-
defined transient portion by deleting the first input size times the Measurement Filter
Transient Waveform Percent attribute divided by 100 from the beginning of the filtered
data array. This feature is useful when using a combination of processing steps, so the
result of an IIR filter excluding the transient portion may be the input of another
measurement. The length of the transient response depends on both the filter order
and the input waveform, and it may require some trial and error to determine the
proper setting for the Measurement Filter Transient Waveform Percent attribute.
Transient Steady State
Legend
Related Topics
FIR Filters
Digital Filtering
Related concepts:
• FIR Filters
• Digital Filtering
NI-SCOPE supports Butterworth, Chebyshev , and Bessel IIR filters. You can fetch
filtered data by calling the Fetch Array Measurement function or VI.
Related concepts:
140 ni.com
NI-SCOPE
• Butterworth Filters
• Chebyshev Filters
• Bessel Filters
Butterworth Filters
A smooth response at all frequencies and a monotonic decrease from the specified
cutoff frequencies characterize Butterworth filters. These filters are maximally
flat—the ideal response of unity in the passband and zero in the stopband. The half
power frequency or the –3 dB down frequency corresponds to the specified cutoff
frequencies.
Butterworth filters do not always provide a good approximation of the ideal filter
response because of the slow rolloff between the passband (the portion of interest in
the spectrum) and the stopband (the unwanted portion of the spectrum). The
advantage of Butterworth filters is a smooth, monotonically decreasing frequency
response. The steepness of the transition is proportional to the filter order, so higher
order Butterworth filters approach the ideal lowpass filter response.
The following figure shows the response of a lowpass Butterworth filter. In the figure,
the sampling frequency is normalized to 1.0, and the cutoff frequency is 0.25.
Chebyshev Filters
These attributes minimize peak error in the passband by setting the maximum
allowable absolute value of the difference between the ideal filter and the filter
response you want (the maximum tolerable error in the passband). Chebyshev filters
have an equiripple magnitude response in the passband, monotonically decreasing
magnitude response in the stopband, and a sharper rolloff than Butterworth filters.
The cutoff frequency for Chebyshev filters is defined as the end of the passband. For
example, if you specify a lowpass filter with 1 dB ripple, the passband response from
0 Hz to the cutoff frequency will have 1 dB ripple. At the cutoff frequency, the response
will be 1 dB down, and it is monotonically decreasing above the cutoff frequency.
The following figure shows the response of a lowpass Chebyshev filter. Notice that the
equiripple response in the passband is constrained by the maximum tolerable ripple
142 ni.com
NI-SCOPE
error and that the sharp rolloff appears in the stopband. The advantage of Chebyshev
filters over Butterworth filters is that Chebyshev filters have a sharper transition
between the passband and the stopband with a lower order filter, which produces
smaller absolute errors and higher execution speeds.
Impulse Magnitude and Phase Response Versus Frequency for a Lowpass Chebyshev
Filter
Bessel Filters
You can use Bessel filters to reduce nonlinear phase distortion inherent in all IIR filters.
In higher order filters and those with a steeper rolloff, this condition is more
pronounced, especially in the transition regions of the filters. Bessel filters have
maximally flat response in both magnitude and phase. Furthermore, the phase
response in the passband of Bessel filters, which is the region of interest, is nearly
linear. Like Butterworth filters, Bessel filters require high-order filters to minimize the
error and, for this reason, are not widely used. You can also obtain linear phase
response using FIR filter designs. The following figure shows a plot of the response of a
lowpass Bessel filter with a sampling frequency normalized to 1.0 and a cutoff
frequency of 0.25. Notice that the response is smooth at all frequencies, as well as
monotonically decreasing in both magnitude and phase. In addition, notice that the
phase in the passband is nearly linear. For Bessel filters, the cutoff frequency specifies
the passband, or the region of linear phase response.
Bessel filters have a distinct advantage in the time domain because they exhibit small
transient aberrations.
FIR Filters
Finite impulse response (FIR) filters are digital filters that have a finite impulse
response. FIR filters are also known as nonrecursive filters, convolution filters, or
moving-average (MA) filters because you can express the output of a FIR filter as a
finite convolution:
where x represents the input sequence to be filtered, y represents the output filtered
sequence, and h represents the FIR filter coefficients.
144 ni.com
NI-SCOPE
• They can achieve linear phase because of filter coefficient symmetry in the
realization.
• They are always stable.
• The filtering function is performed using the convolution and, as such, generally
allows associating a delay with the output sequence of (n-1)/2, where n is the
number of filter coefficients or filter taps.
The simplest method for designing linear-phase FIR filters is the window design
method. To design a FIR filter by windowing, you start with an ideal frequency
response, calculate its impulse response, and then truncate the impulse response to
produce a finite number of coefficients. The truncation of the ideal impulse response
results in the effect known as the Gibbs phenomenon—oscillatory behavior near
abrupt transitions (cutoff frequencies) in the FIR filter frequency response.
You can reduce the effects of the Gibbs phenomenon by smoothing the truncation of
the ideal impulse response using a smoothing window. By tapering the FIR coefficients
at each end, you can diminish the height of the side lobes in the frequency response.
This method widens the main lobe, however, resulting in a wider transition region at
the cutoff frequencies. The selection of a window function, then, is similar to the
choice between Chebyshev and Butterworth IIR filters in that it is a trade-off between
side lobe levels near the cutoff frequencies and width of the transition region.
Related concepts:
The window type you choose affects the data you acquire. In the following figure, a FIR
Filter with a Hanning response window is applied to a signal.
In the following figure, a FIR filter with no window is applied to the same signal, which
has been normalized to 1.0 with a cutoff frequency of 0.25.
Related concepts:
• FIR Filters
• Digital Filtering
146 ni.com
NI-SCOPE
The figure shows the impulse response magnitude and phase response versus
frequency for a lowpass windowed FIR filter, where the sampling frequency is
normalized to 1.0 and the cutoff frequency is 0.25.
No Window
The figure shows the impulse response magnitude and phase response versus
frequency for a lowpass Hamming windowed FIR filter, where the sampling frequency
is normalized to 1.0 and the cutoff frequency is 0.25.
Hamming Window
The figure shows the impulse response magnitude and phase response versus
frequency for a lowpass Triangle windowed FIR filter, where the sampling frequency is
normalized to 1.0 and the cutoff frequency is 0.25.
Triangle Window
148 ni.com
NI-SCOPE
The figure shows the impulse response magnitude and phase response versus
frequency for a lowpass Flat Top windowed FIR filter, where the sampling frequency is
normalized to 1.0 and the cutoff frequency is 0.25.
The figure shows the impulse response magnitude and phase response versus
frequency for a lowpass Blackman windowed FIR filter, where the sampling frequency
is normalized to 1.0 and the cutoff frequency is 0.25.
Blackman Window
150 ni.com
NI-SCOPE
Not all PXI or PXI Express chassis provide the same cooling. When selecting a PXI or PXI
Express chassis, consideration should be given to providing adequate airflow.
NI PXI and PXI Express devices are high-precision instruments and may be sensitive to
interference from other electronic devices. To optimize the accuracy and performance
of the device, you may need to locate the device in a slot away from devices with
power supplies and other noisy circuitry. The device may also be sensitive to heat
generated by high-power products in neighboring slots. When possible, consider
locating the device away from high-power devices to optimize cooling.
For more information on cooling, refer to the Maintain Forced-Air Cooling note that
shipped with the device.
PXI Express uses PCI Express signaling and protocols for communication. A PCI Express
system topology includes several different types of components:
• Root Complex—The root complex is the base of the PCI Express hierarchy that
connects the CPU and system memory to PCI Express I/O.
• Switch—A switch routes transactions among multiple PCI Express devices, other
switches and the root complex. PCI Express communication is always point-to-
point. A device communicates to a single switch. The switch then passes on the
data to another switch, another PCI Express device, or the root complex.
• Endpoint—An endpoint is a device that performs an I/O function, such as a PXI
Express module.
Switch Endpoint
Switch Endpoint
Endpoint Endpoint
The following figure illustrates a link between two devices consisting of 4 lanes.
“Lane” “Link”
Device A Device B
The number of lanes in a link is denoted as xn, where n is a number. All PCI Express
devices must support x1 links. PCI Express devices may also support links of x2, x4, x8,
x12, x16, and x32.
152 ni.com
NI-SCOPE
The data transfers on a lane can occur at 2.5 Gb/s or 5.0 Gb/s.
During initialization, the two devices of a link must negotiate the lane width and
signaling speed that will be used for the link. This process is called link training. All
devices must support x1 lane widths and 2.5 Gb/s signaling.
Performance
The actual throughput for a given system will be less due to protocol overhead, system
topology, data transfers between other devices in the system, and other components
in the system.
Transfers between an I/O device and host memory usually travel through several PCIe
links. Data transfer performance depends on the performance of each link. For
example, if a PXI chassis is controlled with a x1 MXI Express link, the throughput to
system memory may be limited by the x1 link.
PXI Modules
NI
PX
I-1
04
2
Chassis Guidelines
• PXI chassis—PXI modules can be installed in any peripheral slot of a PXI chassis.
• PXI Express chassis—PXI devices can be installed in the following PXI Express
chassis slots:
◦ PXI-1 slots—Accepts all PXI modules
◦ PXI hybrid slots—Accepts all PXI modules that are hybrid slot-compatible or
PXI Express modules
◦ PXI Express slots—Accepts PXI Express modules
154 ni.com
NI-SCOPE
buses that co-exist with the basic PCI interface on the CompactPCI bus. Compatible
operation is not guaranteed between CompactPCI devices with different sub-buses nor
between CompactPCI devices with sub-buses and PXI. The standard implementation
for CompactPCI does not include these sub-buses. NI signal generators work in any
standard CompactPCI chassis. PXI-specific features, such as PXI_Trig bus and
PXI_CLK10 reference are implemented on the J2 connector of the CompactPCI bus.
Related concepts:
The PXI Express Specification integrates PCI Express signaling into the PXI standard,
which increases backplane bandwidth and enhances PXI timing and synchronization
features by incorporating a 100 MHz differential reference clock and differential
triggers. The PXI Express Specification adds these features to PXI while maintaining
backward compatibility. For an overview of the PXI Express specification, refer to PXI
Express Specification Tutorial.
NI
PX
Ie-
10
62
Q
Chassis Guidelines
NI PXI Express modules can be installed in the following PXI Express chassis slots:
• PXI hybrid slots—Accepts all PXI modules that are hybrid slot-compatible or PXI
Express modules
• PXI Express slots—Accepts PXI Express modules
Note Refer to the documentation for your PXI Express chassis for more
information about installing and configuring PXI Express modules.
Related information:
156 ni.com
NI-SCOPE
The PXI star trigger is a feature implemented on National Instruments PXI chassis. PXI
chassis have a PXI trigger bus that is linked to all slots in the chassis. In addition, PXI
chassis have a star trigger that is linked to Slot 2. The star trigger is a high-performance
trigger signal that you can use to synchronize all the modules in a chassis. You can also
do this using the normal PXI trigger bus, but the star trigger offers increased
performance, specifically a propagation delay of no more than 5 ns and an
intermodule delay of no more than 1 ns.
Star Triggers
Star Trigger/Peripheral Slot [3]
Backplane
Interface
Slot 2 of the PXI chassis is optimized for a star trigger controller. If the star trigger is not
required, you can use Slot 2 as a standard peripheral slot. The trigger signal generated
by a controller can then be accessed by the other modules through the backplane. The
star trigger controller in Slot 2 of the PXI chassis can route triggers among peripheral
slots with very low skew (within 1 nanosecond).
All NI digitizers can receive triggers from the PXI star trigger line, which means that if
another instrument is driving the PXI star trigger from Slot 2 of the PXI chassis, the NI
digitizer can receive this trigger signal from another slot. NI digitizers cannot drive the
PXI star trigger line from Slot 2. Therefore, if you want to generate a trigger on the star
trigger line with a master in Slot 2, this master cannot be an NI digitizer.
Eight PXI bused trigger lines are highly flexible and can be used in a variety of ways. For
example, triggers can be used to synchronize the operation of several different PXI
peripheral modules. In other applications, one module can control carefully timed
sequences of operations performed on other modules in the system. Triggers may be
passed from one module to another, allowing precisely timed responses to
asynchronous external events that are being monitored or controlled. The number of
triggers that a particular application requires varies with the complexity and number
of events involved.
PXI_Trigger Bus
PXI Backplane
Star Trigger/Peripheral Slot [2]
System Controller [1]
The PXI Specification is implemented with the RTSI bus through the PXI trigger lines.
PXI Specification requires 8 lines, PXI_TRIGGER[0:7], on the P2/J2 connector of the PXI
chassis for the trigger lines. The RTSI features of the NI Source hardware is
implemented on this sub-bus. The RTSI trigger [0..6] is implemented on
PXI_TRIGGER[0:6], and the RTSI clock is routed on PXI_TRIGGER(7).
The PXI chassis supplies the PXI 10 MHz system clock signal (PXI_CLK10)
independently to each peripheral slot. An independent buffer drives the clock signal to
each peripheral slot. The buffer has a source impedance matched to the backplane
and a skew ranging from less than 1 ns to more than 250 ps between slots. You can use
this common reference clock signal to synchronize multiple modules in a
measurement or control system. You can drive PXI_CLK10 from an external source
through the PXI_CLK10_IN pin on the P2 connector of the star trigger slot. Sourcing an
external clock on this pin automatically disables the backplane's 10 MHz source. You
can synchronize multiple chassis that have connectors on the back panel for 10 MHz
158 ni.com
NI-SCOPE
Reference In and 10 MHz Reference Out. Refer to your PXI chassis documentation for
more information.
Related concepts:
PFI Lines
PFI lines are multipurpose programmable function input/outputs. These lines serve as
connections to virtually all internal timing signals. Many NI high-speed digitizers have
two or more digital lines that can import a trigger, import or export a reference clock,
or output various signals.
The function of each PFI line is independent. However, only one trigger source can be
imported during acquisition.
Notice If you enable a PFI line for output, do not connect any external
signal source to it; doing so can damage the device, the computer, and the
connected equipment.
MXI-3
If you are using the MXI-3 interface to control the PXI chassis, the MXI-3 Optimization
Application must be run prior to using the NI high-speed digitizer. By default, this
application runs automatically when Windows starts. If you have an initialization,
timeout, or performance issue with your module, or if you are not certain that the
application ran, select Start»Programs»National Instruments MXI-3»MXI-3
Optimization to run the application. If you continue to have initialization or
performance issues, refer to the MXI-3 documentation at Start»Programs»National
Instruments MXI-3, or visit NI Technical Support at ni.com/support.
Optimization for MXI-4 and MXI Express are performed automatically by the hardware.
RTSI Bus
RTSI stands for Real-Time System Integration. It is a bus found on many National
Instruments devices that, when cabled together with a RTSI cable, is used to share and
exchange timing and control signals between multiple boards. It is usually used for
synchronization purposes.
The RTSI bus cables are short, 34-conductor ribbon cables equipped with two to five
connectors to link together a group of boards. The cable options include connections
for two, three, four, and five boards, plus an extended cable length to connect up to
five long and short boards. The following figure shows an example of an extended five-
board cable setup.
PFI Lines
PFI lines are multipurpose programmable function input/outputs. These lines serve as
connections to virtually all internal timing signals. Many NI high-speed digitizers have
two or more digital lines that can import a trigger, import or export a reference clock,
160 ni.com
NI-SCOPE
The function of each PFI line is independent. However, only one trigger source can be
imported during acquisition.
Notice If you enable a PFI line for output, do not connect any external
signal source to it; doing so can damage the device, the computer, and the
connected equipment.
When you install NI‑SCOPE on a 64‑bit system, you can monitor, control, and record
measurements from supported devices using InstrumentStudio. InstrumentStudio is a
software-based front panel application that allows you to perform interactive
measurements on several different device types, including oscilloscopes, in a single
program.
InstrumentStudio is automatically installed when you install the NI‑SCOPE driver. You
can access InstrumentStudio in one of the following ways:
‑
• From the Windows start menu, select National Instruments»NI‑SCOPE Soft Front
Panel. This launches InstrumentStudio and runs a soft front panel populated with
NI‑SCOPE devices.
• From the Windows start menu, select National Instruments»InstrumentStudio
[year]. This launches InstrumentStudio and runs a soft front panel populated with
devices detected on your system.
• From Measurement & Automation Explorer (MAX), select a device and then click
Test Panels.... This launches InstrumentStudio and runs a soft front panel for the
device you selected.
162 ni.com
NI-SCOPE
Related concepts:
Related information:
•
• InstrumentStudio
This help file contains information about using the 32‑bit NI-SCOPE Soft Front Panel
(SFP) to interactively control your NI high-speed digitizer. For information about
developing applications, refer to NI High-Speed Digitizers Help»Programming.
Note The information in this help file is relevant only to the NI-SCOPE SFP
that launches in NI-SCOPE 18.0 and earlier or that, beginning with NI-SCOPE
18.1, launches on 32‑bit systems. For information on InstrumentStudio, a
software-based front panel application for 64‑bit systems that was first
available in NI-SCOPE 18.1, refer to NI-SCOPE Soft Front Panel and
InstrumentStudio.
Note Most features of the SFP are documented in the SFP context help. You
can view the context help for a SFP element by hovering the cursor over the
element you want more information about. If the context help window does
not appear, press <Ctrl-H> to activate the context help, or select Help»Show
Context Help.
Related concepts:
You must either connect to or simulate a device to use the SFP. If you have already
registered an active device or simulated a device in Measurement & Automation
Explorer (MAX), you can choose from a list of available devices.
If you do not have any active digitizers registered in MAX, the SFP will prompt you to
simulate a device. Choose the Model Number and Bus Type of the device you want to
simulate, then select the amount of Noise (%) to simulate. The SFP will simulate data
acquired from the type of digitizer you have chosen.
164 ni.com
NI-SCOPE
The SFP is designed to look similar to the front panel of a desktop instrument.
However, some functionality of the SFP is fundamentally different from that of a box
oscilloscope.
The following buttons control the connection and data acquisition of your device.
The Pause button pauses the acquisition. The device is still connected to the SFP, but
other programs are not able to acquire data from the device. The Pause button
becomes the Run button while the acquisition is paused.
The Run button resumes a paused acquisition. It also prompts you to select a new
device if you have released a previous session with a device.
The Off button stops the acquisition. When stopped, all drivers are unloaded. Select
the Run button to resume an acquisition.
The Auto button automatically configures the device. The device recognizes the input
signal and automatically configures many instrument settings.
The Prop button opens a dialog box and displays all properties available in a session.
Control Tabs
The control tabs on the SFP are similar to the soft buttons on a box oscilloscope. The
control tabs are, from left to right: Channel Settings (CHAN), Trigger Settings (TRIG),
Horizontal Settings (HORIZ), Measurement Settings (MEAS), Cursor Settings (CURS),
and Display Settings (DISP). The Trigger Settings tab is active by default.
Related concepts:
• Monitoring a Device
• Sharing Control of a Device
In a Debug Driver session, you can monitor or control your device in the Soft Front
Panel (SFP) while the device is being used by another application, such as LabVIEW or
TestStand. Changing device settings in the SFP can help you troubleshoot problems
with your device under test or application.
Note The SFP automatically opens in a Debug Driver session for a device
that is In Use.
Example
You want to change the device settings based on unexpected results from your
application. You immediately pause the application where you suspect an error, start
166 ni.com
NI-SCOPE
the SFP and choose the device for which you want to change settings. You can change
device settings, then resume your application with the new settings.
Related Topics
Monitoring a Device
Related concepts:
• Monitoring a Device
Your
SFP
Application
Debug Driver
Device
You can monitor or control your device in the SFP when the device is in use by other
applications, such as LabVIEW or TestStand. Select Debug Driver Session (Monitor)
from the pull-down menu to view data and device settings. Most SFP controls are
disabled because the SFP is read-only when Debug Driver Session (Monitor) is
selected. You cannot make changes in the SFP that will affect your device or
application in this mode.
Select Debug Driver Session (Control) from the pull-down menu if you want to change
device settings. The SFP is read-write when Debug Driver Session (Control) is
selected. Controls are enabled and you have full access to your device. To relinquish
Related Topics
Monitoring a Device
Related concepts:
• Monitoring a Device
You can debug your device by sharing a device between the SFP and another
application.
Complete the following steps to share control between the SFP and LabVIEW:
Tip Select Show Changes in the Debug Session Changes dialog box to
display a log of device setting changes made during the Debug Driver
168 ni.com
NI-SCOPE
5. (Optional) Continue using your device in your LabVIEW application, with your new
device settings.
Complete the following steps to share control between the SFP and CVI, TestStand, or
another application:
Tip Select Show Changes in the Debug Session Changes dialog box to
display a log of device setting changes made during the Debug Driver
session. Select Export as Text to document the changes.
7. (Optional) Continue using your device in the other application, with your new
device settings.
Monitoring a Device
You can monitor a device with LabVIEW, CVI, TestStand, or your application in the SFP
to troubleshoot problems with your device under test or application. View data and
device settings by sharing your device between the SFP and your application.
Tip You can launch the SFP from the Windows Start menu, the Tools
menu in LabVIEW, or from your device listed under Devices and
Interfaces in the MAX configuration tree.
2. Select an In Use device that you want to monitor with the SFP. Debug Driver
Session (Monitor) is selected from the pull-down menu.
3. When you finish monitoring the device, close the SFP.
Complete the following to correct common issues you might encounter while
debugging your device.
Your application made a call to the NI-SCOPE driver. Pause your external application
and select Debug Driver Session (Control) from the pull-down menu, or ensure that
the application does not fetch data or access the device.
The SFP is currently monitoring or controlling a shared device session, or the device
170 ni.com
NI-SCOPE
does not support debugging. Verify that no external applications are currently
accessing the device.
Complete the following steps in the SFP to ensure the device is enabled for Debug
Session mode (the default value is enabled).
Waveform data can be saved in three file formats: hierarchical waveform storage
(*.hws) data file, LabVIEW Measurement (*.lvm) data file, and flat binary (*.bin).
Waveforms saved with the NI-SCOPE Soft Front Panel can be generated using an NI
arbitrary waveform generator and the NI-FGEN Soft Front Panel.
Shortcut:
<Ctrl–S>
Related concepts:
Hierarchical Waveform Storage Data File (.hws) format is based on the HDF5 file
format, which is a widely used and efficient file format for storing scientific and
engineering data such as images, vector arrays, and structured and unstructured grids.
For more information about HDF5, refer to the HDF Group web site at
http://www.hdfgroup.org/HDF5/.
HWS is the file type of choice due to its flexibility. It is capable of saving device
configuration settings as well as multiple channels of waveform data, measurements,
and associated header information. HWS also offers compression options, making this
format the best choice for very large or multiple data records.
The LabVIEW Measurement (.lvm) format is a text-based file format for one-
dimensional data that you can use with the Read LabVIEW Measurement File and Write
LabVIEW Measurement File Express VIs.
The .lvm format is easy to parse and easy to read when imported into a spreadsheet
program such as Microsoft Excel, or a text editor such as Notepad. The .lvm format
supports multiple data sets, grouping of data sets, and the addition of data sets to
existing files.
This file format is not designed for high-performance or for very large data sets, as is
the case with all text-based formats.
Note For very large data sets, use the HWS or binary file formats.
For more information on the .lvm file format, refer to the Specification for the
LabVIEW Measurement File.
Related concepts:
The NI-SCOPE Soft Front Panel can save data in a binary file that conforms to the
following specifications:
172 ni.com
NI-SCOPE
• File extension—.bin
• File header—none
• Data—Data are stored as a continuous single stream. The creator of the file must
remember the data type the data were stored in. Data can be imported in 8-, 16-, or
32-bit binary, and can be little or big endian format.
Binary files save only one channel of data and offer advanced options for byte format.
Associated header information is saved in a separate text file with the same name.
Configuration settings are saved in three ways: automatically upon stopping or closing
the SFP, using the File»Save Configuration option, and when saving data in HWS file
format.
The SFP always saves your device configuration settings upon release of a session or
closing of the SFP. If the SFP detects the same device using the same resource
descriptor (set in MAX) upon reopening, it loads the previous configuration settings. If
you are using a different type of device, the SFP configures your acquisition
automatically using the Autosetup function.
To save your configuration settings, select File»Save Configuration. Enter the name of
your configuration file or select an existing configuration file and click Save.
Enter any additional information you would like to add in the fields provided. Click OK
to add your current configuration to the selected file.
Related concepts:
Backing Store
Backing store is a feature that stores the current waveform on the NI-SCOPE Soft Front
Panel in RAM. During normal operation, the NI-SCOPE SFP gets the data from the
digitizer, decimates and scales it for display, displays it, then discards it. This process
saves time and memory, especially when working with large data sets. With large data
sets, the data is never all in memory at one time, because it is read from the digitizer in
chunks and decimated in chunks. The NI-SCOPE SFP scales this decimated data. The
disadvantage of this process is that you must wait for an acquisition to finish before
you get data that you can save. If you have a signal on the NI-SCOPE SFP that you want
to save, you may not be able to do so unless the acquisition is currently paused,
depending on the length of the waveform.
To save a waveform, the NI-SCOPE SFP copies chunks of data from the digitizer directly
to disk, which prevents a memory hit. If your acquisition is in progress, the data that is
currently displayed is lost, and you must wait until the acquisition is complete before
saving data. Using single-shot mode is usually recommended if you want to save the
displayed data. When the digitizer pauses, the data is preserved because another
acquisition is not initiated. If backing store is enabled, the current waveform is stored
in memory and you can save at any time.
Backing store is enabled by default. If you are using an older computer, however, you
may experience reduced performance and higher memory requirements. Disabling
backing store may solve these problems.
Keyboard Shortcuts
Note Shortcuts for controls grouped under a Control Tab are only usable
while their Control Tab is active.
Shortcut Description
<G>, <R>, <Shift–G>, <Shift–R> Run
<P>, <Shift–P> Pause
174 ni.com
NI-SCOPE
Shortcut Description
<G>, <R> Resume
<ESC>, <Q>, <Shift–Q> Stop
<Shift–X>, <X>, <Ctrl–Q>, <Alt–F4> Exit
<A>, <Shift–A> Auto setup
<1> Trigger a single-shot acquisition
<)> (usually Shift–0) Set left channel selector to channel 0
<!> (usually Shift–1) Set left channel selector to channel 1
<#> (usually Shift–3) Set left channel selector to channel 2 (if available)
<$> (usually Shift–4) Set left channel selector to channel 3 (if available)
<Ctrl–)> (usually Ctrl–Shift–0) Set right channel selector to channel 0
<Ctrl–!> (usually Ctrl–Shift–1) Set right channel selector to channel 1
<Ctrl–#> (usually Ctrl–Shift–3) Set right channel selector to channel 2 (if available)
<Ctrl–$> (usually Ctrl–Shift–4) Set right channel selector to channel 3 (if available)
<Ctrl–D> Enable/Disable the left channel
<Ctrl–Shift–D> Enable/Disable the right channel
<Ctrl–up arrow> Decrease volts per division on the left channel
<Ctrl–down arrow> Increase volts per division on the left channel
<Ctrl–Shift–up arrow> Decrease volts per division on the right channel
<Ctrl–Shift–down arrow> Increase volts per division on the right channel
<Ctrl–A> Increment coupling on left channel
<Shift–Ctrl–A> Increment coupling on right channel
<Up arrow> Increase left channel software offset
<Down arrow> Decrease left channel software offset
<Shift–up arrow> Increase right channel software offset
<Shift–down arrow> Decrease right channel software offset
<Shift–up arrow> Increase vertical position slider
<Shift–down arrow> Decrease vertical position slider
Shortcut Description
<Ctrl–M> Launch measurement window
<Ctrl–D> Launch device configuration window
<Ctrl–left arrow> Decrease horizontal range
<Ctrl–right arrow> Increase horizontal range
<F2> Change reference position to 10%
<F3> Change reference position to 50%
<F4> Change reference position to 90%
<Shift–right arrow> Increase reference (trigger) position slider
<Shift–left arrow> Decrease reference (trigger) position slider
<Y> Increment acquisition type
<Shift–Y> Decrement acquisition type
<Ctrl–E> Display error info
<Ctrl–O> Turn on/off probe compensation
<Ctrl–T> Turn on/off trigger cursor
<Ctrl–Shift–S> Run self–calibration
<Ctrl–P> Print window
<Ctrl–X> Cut
<Ctrl–V> Paste
<Ctrl–H> Show context help
<Ctrl–S> Save waveform data
<E> Increment EXT coupling
<Shift-E> Decrement EXT coupling
<C> Toggle Cursors
<F1>, <Ctrl–?> Contents and index
Trigger Settings (TRIG) Control Tab
<S> Increment trigger source
<Shift–S> Decrement trigger source
176 ni.com
NI-SCOPE
Shortcut Description
<T> Increment trigger type
<Shift–T> Decrement trigger type
<U> Increment trigger coupling
<Shift–U> Decrement trigger coupling
<L> Increment trigger slope
<Shift–L> Decrement trigger slope
<M> Increment trigger mode
<Shift–M> Decrement trigger mode
<W> Increment trigger window mode
<Shift–W> Decrement trigger window mode
<Ctrl–W> Increment trigger delay
<Ctrl–Shift–W> Decrement trigger delay
<PgUp> Increment trigger level/low level
<PgDwn> Decrement trigger level/low level
<Shift–PgUp> Increment trigger hysteresis/high level
<Shift–PgDwn> Decrement trigger hysteresis/high level
<V> Increment TV event
<Shift-V> Decrement TV event
<O> Increment TV polarity
<Shift-O> Decrement TV polarity
<N> Increment TV line number
<Shift-N> Decrement TV line number
<F> Increment TV signal format
<Shift–F> Decrement TV signal format
<Ctrl–R> Toggle TV DC Restore
Horizontal Settings (HORIZ) Control Tab
<Z> Enable zoom
Shortcut Description
Display Settings (DISP) Control Tab
<Ctrl–M> Toggle show/hide measurement/cursor data
<Ctrl–C> Toggle show/hide configuration data
<H> Hide all data
178 ni.com
NI-SCOPE
Programming
This section contains information on programming NI high-speed digitizers. You can
acquire data with an NI high-speed digitizer either programmatically or interactively.
NI High-Speed Digitizer
For more information, refer to the NI-SCOPE Soft Front Panel and InstrumentStudio.
NI-SCOPE is both the application programming interface (API) and the instrument
driver that controls your NI high-speed digitizer. NI-SCOPE is included with all NI high-
speed digitizers.
Features
Examples
To help you get started, NI-SCOPE comes with examples you can use or modify. You
can find shortcuts to the examples for each ADE at Start»All Programs»National
Instruments»NI-SCOPE»Examples.
Related concepts:
• Instrument Drivers
180 ni.com
NI-SCOPE
• In LabVIEW as VIs
• In traditional programming languages as functions
Note If you are new to NI-SCOPE, read Getting Started with NI-SCOPE
(Tutorial) before you read this section.
The following diagram illustrates the basic programming flow for using NI-SCOPE
functions in your own digitizer applications. Click the VIs in the diagram for more
detailed programming information.
For any application you write, you must open a session to establish communication
with the digitizer(s) by using niScope Initialize or niScope Initialize With Options. When
your program finishes, you must close the session with niScope Close.
Initialize functions set the driver and digitizers to a known state. This function may
take a significant amount of time compared to all other NI-SCOPE functions, so you
should not include it in a loop when repeatedly acquiring data. Ideally, your program
should call an Initialize function one time. If the reset device parameter is set to TRUE,
the digitizer resets to the default state, which may include resetting relays and
resetting time stamp counters.
Caution Resetting digitizers may cause wear on the relays, so you should
reset only when necessary.
Examples
All NI-SCOPE examples include niScope Initialize or niScope Initialize With Options,
niScope Close, and Error Message (except for LabVIEW). The Getting Started
example is a good choice to start with if you are inexperienced with NI-SCOPE because
it is the simplest example.
Related concepts:
• NI-SCOPE Tutorial
If you want to integrate a digitizer into your test and measurement application, you
can program the device using National Instruments LabVIEW or LabWindows/CVI,
Microsoft Visual C++/C#, Microsoft Visual Basic, and Microsoft Visual Basic .NET.
182 ni.com
NI-SCOPE
NI High-Speed Digitizer
If you are using the digitizer as a general-purpose digitizer, you can use the NI-SCOPE
Soft Front Panel (SFP) to make measurements interactively without writing code. To
launch the NI-SCOPE SFP, select Start»All Programs»National Instruments»NI-
SCOPE»NI-SCOPE Soft Front Panel. For more information, refer to the NI-SCOPE Soft
Front Panel Help.
Related concepts:
Acquisition Functions
You can acquire data by calling either a Read function or a Fetch function. The Read
functions are the easiest way to acquire data from your digitizer. They initiate an
acquisition, wait for it to complete, and retrieve the data.
Fetch functions assume that the acquisition has already been initiated. Both Read and
Fetch functions accept a timeout parameter and a number of points to retrieve. They
will efficiently sleep while waiting for the number of requested points to be acquired.
Using a Fetch function in conjunction with the acquisition status function allows you to
perform other operations while waiting for the acquisition to finish. When acquisition
status reports the operation is complete, you can call the Fetch function with any
timeout value to retrieve the data.
You must use Fetch functions to acquire binary data because Read functions allow
retrieval of scaled data only. Fetching binary data is faster and requires less user
memory than fetching scaled data.
If you want to use a software trigger to start the acquisition, you must use a Fetch
function because Read functions block until the operation is complete.
The Getting Started example uses a Read function. Most examples use Fetch
functions, but the Binary Acq example provides the least complicated source
code. You can find shortcuts to these examples at Start»All Programs»National
Instruments»NI-SCOPE»Examples.
Related concepts:
• Fetching Data
Configuration Functions
Using these functions, you can set triggers, input impedance, DC offset, vertical range,
sampling rate, and much more. Additionally, NI‑SCOPE can automatically configure
your device settings with the Auto Setup function. Once configured, you can also
export and import device settings between matching models.
184 ni.com
NI-SCOPE
You can use the Configuration functions to configure the following settings and
parameters:
• Acquisition type
• Vertical settings
• Horizontal settings
• Configuring triggers
Configuration Example
NI digitizers support different acquisition types. You set the acquisition type with the
niScope Configure Acquisition VI or the niScope_ConfigureAcquisition
function. The different acquisition types change the processing of the data that is
returned. In conventional (or normal) mode, the digitizer acts like a traditional
instrument, measuring voltage waveforms. In PXI/PCI‑5922 flexible resolution mode,
the digitizer uses an advanced averaging algorithm to increase the resolution of data
at lower sample rates.
Note Not all digitizers support flexible resolution mode. Refer to Features
Supported by Device for more information. By default, the acquisition type
parameter is set to normal, and you can omit Configure Acquisition
if you do not want to change the acquisition type.
Related concepts:
With the Configure Vertical function, you can adjust the vertical range,
vertical offset, vertical coupling, and the probe attenuation parameters.
With the Configure Chan Characteristics function, you can adjust the input
impedance and the and the max input frequency parameters.
Related Topics
Related concepts:
Vertical Range
Configure Vertical adjusts the vertical range for the digitizer. The vertical range
is the full-scale (peak-to-peak) voltage range at the probe or the input to the digitizer.
For example, a 10 V vertical range means the digitizer can measure a signal between
–5 V and 5 V. The signal may be clipped if it exceeds this range, which means the
analog-to-digital converter (ADC) is saturated, so all values above 5 V or below –5 V are
mapped to approximately 5 V or –5 V, respectively. For optimum resolution, choose the
smallest vertical range that completely covers your input signal and avoids clipping.
For example, if your signal is 2 Vpk-pk and your vertical range is 10 Vpk-pk, you are only
186 ni.com
NI-SCOPE
using one-fifth of the range of the ADC. With an 8-bit digitizer, you have 256 unique
voltage levels, but if you only use one-fifth of the range, you only have 51 unique
voltage levels. This results in a noisy signal from the quantization of the ADC.
Vertical Offset
The vertical offset parameter in the Configure Vertical function adjusts the
middle of your vertical range. For example, if you set the vertical offset to 2 V with a
vertical range of 10 V, your signal must be between –3 V and 7 V. Vertical offset allows
you to adjust the range when analyzing signals with a DC offset. By centering the
vertical offset on the DC level of your signal, you can use a smaller vertical range and
optimize the resolution of your measurement.
1.25 V 1.25 V
1V
1V
–1 V
–1.25 V 0.75 V
Offset = 0 V Offset = 1 V
Range = 2.5 V Range = 0.5 V
Resolution = 2.5 V = 10 mV Resolution = 0.5 V = 2 mV
256 256
Note Not all digitizers support using vertical offset. Refer to Features
Supported by Device to determine if your digitizer supports vertical offset.
Vertical Coupling
When you need to measure a small AC signal on top of a large DC component, you can
use AC-coupling by setting the vertical coupling parameter in the Configure
Vertical function. AC-coupling rejects any DC component in your signal before it is
digitized. Activating AC-coupling inserts a capacitor in series with the input.
When you change the vertical range or coupling on the digitizer, the input stage takes
time to settle. When you switch from AC- to DC-coupling, the settling time is about
0.5 ms. When you switch from DC- to AC-coupling, returned data is accurate about 20
time constants after switching to AC. A 1X probe takes about 15 ms, while a 10X probe
takes 150 ms, depending on the digitizer. NI-SCOPE does not provide the delay to
account for settling time; therefore, acquisitions immediately following a coupling
change may yield incorrect data. However, the vertical range and coupling are set
immediately when you call Configure Vertical, so inserting a delay in your
program before calling Initiate Acquisition or a Read function allows time for
the input stage to completely settle.
Note For the NI 5122, the vertical range and coupling are not set when
Configure Vertical is called. Settling delays for a 1X probe are
automatically compensated for in the driver. For other probes that require
longer delays, you can call Commit to switch the coupling immediately.
Then, you can insert the appropriate delay before calling a Read function or
Initiate Acquisition.
Probe Attenuation
Probe attenuation scales your data to compensate for the attenuation of the probe.
The voltage measured by the digitizer is multiplied by the probe attenuation
parameter in the Configure Vertical function. The vertical range parameter is
the voltage range you want after the probe compensation scaling. For example, if your
probe attenuation is 10 and your vertical range is 10 V, the digitizer is set to measure a
1 Vpk-pk signal. The data returned with the Fetch function is 10 Vpk-pk.
Related concepts:
Using the Configure Chan Characteristics function, you can configure the
less common vertical parameters.
Input Impedance
The input impedance parameter allows you to switch between 50 Ω and 1 MΩ input
impedance, depending on your digitizer. Refer to Features Supported by Device to find
188 ni.com
NI-SCOPE
out the input impedance your digitizer supports. The allowed vertical ranges may vary
depending on the input impedance. If you measure a signal from a 50 Ω output
function generator, set the digitizer for 50 Ω input to match your source. Impedance
matching becomes much more important with higher frequency signals to avoid
reflections of the signal that may distort your measurements. Alternatively, if you
probe a circuit, it is best to use the high impedance setting on the digitizer to avoid
changing the characteristics of the circuit.
To protect the 50 Ω resistor, a thermal sensing circuit opens the input if the power
dissipation is too high. If this occurs, a warning is returned from all Read, Fetch, and
Status functions. The circuit tries to reset itself when Read, Fetch, or Status functions
are called, except on SMC-based devices, which require you to reset the circuit by
initiating a new acquisition. Some digitizers also support the detection of an ADC
overload. ADC overload detection works the same as the 50 Ω overload detection
circuit described previously.
The max input frequency parameter sets the –3 dB cutoff frequency for a hardware
analog filter. Setting this parameter to zero uses the default bandwidth of the digitizer.
The filter attenuates signals greater than the cutoff frequency, which is useful for
minimizing high-frequency noise when sampling at lower rates. For example, if you
sample at 100 MS/s, you can resolve frequencies up to 50 MHz according to the Nyquist
theorem. Any noise in the signal above 50 MHz, such as harmonics of the input signal,
are aliased onto a frequency below 50 MHz. The solution is to filter this noise before
the signal is digitized. Refer to Features Supported by Device to find out the valid –3 dB
bandwidth your digitizer supports. This hardware filter is not available in all digitizers.
Related concepts:
The horizontal timing parameters apply to all enabled channels of the digitizer, which
means that both channels of a two-channel digitizer sample the same amount of data
at the same rate. Some digitizers support acquiring multirecords. multirecord
acquisitions allow you to acquire multiple, triggered waveforms very quickly. Because
the triggering and timing are done in hardware, multirecord acquisitions eliminate the
possibility of the operating system interrupting your program and causing the digitizer
to miss triggers. To find out if your digitizer supports multirecord acquisitions, refer to
Features Supported by Device. The horizontal settings include the num records,
sample rate, min record length, and reference position parameters.
Num Records
Sample Rate
The sample rate parameter is the frequency at which digitized samples are stored,
expressed in samples per second. This parameter is rounded up to the next legal
sampling rate that your device supports. If the enforce realtime parameter is set to
TRUE, the sampling rate must be set lower than the maximum real-time sampling rate
of the digitizer, so data can be digitized at the requested rate. If you set the enforce
realtime parameter to FALSE, NI-SCOPE allows you to specify sampling rates higher
than the maximum real-time sampling rate of the digitizer. When you do this, NI-
SCOPE enters random interleaved sampling (RIS) mode, where it acquires multiple
waveforms at the maximum real-time sampling rate and reconstructs a periodic
waveform.
The min record length parameter is the minimum number of samples to store for each
record in the acquisition. This parameter can also be rounded up. NI-SCOPE maintains
a constant time per record, which is the min record length divided by the requested
sampling rate. Because the sampling rate is rounded up to a legal value, the min
record length can also be rounded up. You can fetch this resulting actual record length
by calling Actual Record Length. Similarly, you can call Sample Rate to find
the true sample rate used or Actual Sample Mode to determine if NI-SCOPE is
using RIS or real-time sampling.
190 ni.com
NI-SCOPE
Reference Position
Related Topics
Related concepts:
Configuring Triggers
You can also use the Configure Trigger functions to set certain trigger parameters.
Refer to Trigger Parameters for more information on some of the common parameters.
Related concepts:
• Immediate Triggers
• Software Triggers
• Hysteresis Triggers
• Edge Triggers
• Window Triggers
• Video Triggers
• Digital Triggers
• Trigger Parameters
• Use attributes if NI-SCOPE does not have a high-level function that sets an
attribute that you need.
• Use attributes if you need to change one variable at a time. Attributes allow you to
change one variable at a time, whereas functions and parameters do not. Because
NI-SCOPE efficiently caches previous settings, there is no performance penalty if
you use a function when only one variable is changed at a time.
Accessing Attributes
In LabVIEW, you can find attributes in the NI-SCOPE property node by dropping the
property node from the NI-SCOPE palette onto your block diagram.
In C and Visual Basic, you can access attributes with the Set Attribute and Get Attribute
functions.
Attributes—which are also called properties in LabVIEW—are modified when you set
them or when you call a configuration VI or function that sets them. It is important to
set the attributes or call any configuration VIs or functions before reading back any
attribute values for the following reasons:
• Values read are coerced depending on the current configuration of the session. If
you read an attribute value and then set other attributes, the value read may no
longer be valid.
192 ni.com
NI-SCOPE
• The driver verifies that the configuration of the device is valid at the time the
attribute is read. It is possible to get an error when reading an attribute if the
configuration is not valid at that point, even when a setting later could make it
valid.
• Reading attributes causes the driver to verify the current configuration. If you
change some of the settings later, those settings need to be validated again.
Utility Functions
The Utility functions perform various tasks such as resetting the digitizer and returning
the revision numbers of NI-SCOPE and the instrument firmware. These functions can
also help you start or stop the output of a square wave for probe compensation.
Related concepts:
• Probe Compensation
Fetching Data
NI-SCOPE supports several attributes for advanced fetching operations. The two
following attributes are general purpose, allowing you to fetch only a portion of the
acquired waveforms.
• The Fetch Offset attribute is the offset in samples from which to start fetching
Related concepts:
If you are programming in C, C++, or Visual Basic, you need to declare a waveform
array in your program. This array allocates space for the data that is acquired with a
Fetch function. LabVIEW users do not need to declare a waveform because the Fetch
call allocates it for you.
NI-SCOPE coerces up the min record length specified with the Configure
Horizontal Timing function. You can retrieve the actual number of samples
acquired by the digitizer by calling niScope Actual Record Length.
NI-SCOPE provides the Actual Num Wfms function when declaring your waveform
array. This function returns the number of waveforms that are available for fetching,
according to the formula:
numWaveforms = NR x NC x AT
194 ni.com
NI-SCOPE
The waveform array is a single dimension array with a size equal to the number of
waveforms to fetch times the number of points to fetch in each waveform. For
example, if you are fetching scaled voltage data in a C program, your code may look
like the following:
You also need to declare an niScope_WfmInfo structure to hold the relevant constants
that describe each waveform. You need one structure for each fetched waveform. The
syntax is as follows:
Related Topics
Fetching Data
Related concepts:
• Fetching Data
Initiating an Acquisition
Initiate Acquisition tells the digitizer to start acquiring data. During this
function, the hardware is programmed with the configuration that you have chosen,
and the digitizer begins sampling data and storing it to onboard memory. First, the
digitizer samples the requested number of pretrigger points, ignoring any triggers that
may occur. After the requested number of pretrigger points are stored, the digitizer
waits for a trigger. While waiting, it continues to sample and store data into the
circular, onboard memory. The trigger signals the digitizer to sample the exact number
of posttrigger samples that you requested. After the posttrigger points are stored, the
digitizer either stops sampling data or restarts this process for the next record. The
digitizer stores the memory location of the first posttrigger sample, which allows it to
calculate where the first pretrigger sample is located in memory when you fetch the
waveform.
Related Topics
Fetching Data
Related concepts:
• Fetching Data
After the acquisition is initiated, you typically use a Fetch function with a positive
timeout parameter to sleep while the digitizer acquires the data. The Fetch function
polls the digitizer while waiting for the data to be acquired, and it returns the
requested data when the data is available. If the data is not acquired within the time
specified with the timeout parameter, NI-SCOPE returns an error.
Alternatively, you can use the Acquisition Status function, or the Records
Done or Points Done attributes to determine when the data is available. Using
these low-level functions allows you to perform other operations while the digitizer is
busy. However, using a Fetch function to wait for the data is easier.
Digitizers that support continuous acquisition allow fetching while the acquisition is
still in progress. When you specify a positive timeout, the Fetch function only waits for
the requested data, not the entire acquisition. Furthermore, digitizers supporting
continuous acquisition allow you to call a Fetch function with a timeout value of zero,
which fetches all the currently available data without waiting. In this case, the actual
number of samples fetched from the digitizer is returned in the wfmInfo structure.
Fore more information, refer to Acquiring Data Continuously.
NI-SCOPE supports one high-level Read function that combines the Initiate
Acquisition and a Fetch function into one call. This function is suitable for most
applications, but it does not support fetching binary (non-scaled) waveforms, software
triggering, or continuous acquisition. You can use Read to acquire and fetch some
data, followed by a call to a Fetch function to retrieve more data.
196 ni.com
NI-SCOPE
If you want to stop the digitizer before it finishes, use Abort. If the digitizer supports
continuous acquisition, you can fetch all the data that was acquired before you called
Abort. However, if the trigger has not occurred in the record that the digitizer is
currently acquiring, the trigger point is invalid.
Related Topics
Fetching Data
Related concepts:
• Initiating an Acquisition
• Acquiring Data Continuously
• Fetching Data
Fetching data refers to the process of transferring the acquired waveform from the
digitizer memory to the host computer memory. This is generally done with direct
memory access (DMA), which copies the binary data from the digitizer extremely
quickly. Usually, the binary data is scaled to voltage during the fetch and stored in as a
64-bit floating point number. One or more waveform arrays are returned from each
Fetch function, which allow you to display, analyze, or store the acquired data.
NI-SCOPE offers one method to fetch many types of data. This means that one function
can fetch normal acquisitions, multirecord acquisitions, and continuous fetching
acquisitions. For C and Visual Basic, there are four Fetch functions, one for each data
type that may be returned. For LabVIEW, there are several Fetch functions that allow
fetching either one or several waveforms with either a waveform cluster output or a
two-dimensional array output for each data type. In LabVIEW 7.0 and later, data can
also be returned as a waveform data type.
The Fetch functions all take a comma-delimited list of channels to fetch, and the
number of samples (numSamples) to fetch for each waveform that is returned. If the
acquisition finishes and the specified numSamples have not been acquired, the Fetch
functions return all the available data. The waveformInfo output lists the actual
number of samples fetched. In LabVIEW, setting the numSamples parameter to –1
fetches the actual record length, specified when you configure the acquisition.
Otherwise, you can determine the actual record length by calling Actual Record
Length.
• If the acquisition type returns two waveforms, they are directly next to each other.
• If multiple channels are specified, the channel's data is returned in the order of the
list.
• If multiple records are specified, all Record 0 waveforms are returned before any
Record 1 waveforms.
Refer to the NI-SCOPE Function Reference Help or the NI-SCOPE LabVIEW Reference for
more information on Read and Fetch functions.
The most common situation is fetching two channels of data during a normal, single-
record acquisition. In this case, the two waveforms are ordered the same as the
channel list. Refer to Making Multiple-Record Acquisitions for more information about
fetching data in multiple-record situations. Remember, you can always call a Fetch
function repeatedly to fetch each waveform separately. In addition to returning
waveforms, Fetch functions return an array of wfmInfo structures—one for each
waveform returned. The structure contains information about the waveform, including
timing and scaling information.
The waveformInfo structure contains the necessary timing information for plotting
and analyzing an acquired waveform. The x increment is the time, in seconds,
between two samples. The relative initial x is the time, in seconds, of the first point in
198 ni.com
NI-SCOPE
the waveform with respect to the trigger. If you acquire pretrigger samples, this value
is negative. The trigger time is very accurate and has much higher resolution than the
sample period because it uses a time-to-digital conversion (TDC) circuit. Using the
relative initial x scale, the trigger always occurs at time equals zero. In LabVIEW, the
Fetch functions that return a cluster contain the relative initial x value and the
x increment. Wiring that cluster directly to the graph plots the waveform versus time.
The absolute initial x parameter is only supported on devices with continuous
acquisition. Refer to Acquiring Data Continuously for more information on continuous
acquisition.
The waveformInfo structure also contains the gain and offset scaling factors that allow
you to convert binary data to voltage. Often, you need to maximize the speed of the
application while acquiring data. Fetching binary data saves time because it avoids the
scaling operation and uses significantly less memory (on an 8-bit device, 1 byte instead
of 8 bytes per sample). However, you may want to scale the binary values to a voltage
at a later time. To do this, use the gain factor and offset values from the waveformInfo
structure in the following formula:
Related Topics
Fetching Data
Related concepts:
Unlike Read VIs, Fetch VIs such as niScope Fetch Poly and niScope Fetch Measurement
Poly—acquire data asynchronously. That means these VIs store data on your digitizer
until you need it, which frees up your computer to perform other tasks. However,
fetching requires additional VIs that initiate waveform acquisitions and query your
You use the same Fetch VIs for simple data acquisition and advanced continuous
acquisition, such as fetching multiple records. Although the VIs only have the
numSamples input parameter to determine how what data is retrieved, NI-SCOPE
offers several properties that allow you to specify advanced fetching options. The
Fetch Relative To and Fetch Offset properties allow you to explicitly choose the
portion of a record to retrieve. The Fetch Record Number and Fetch Number of
Records properties allow specifying the records to retrieve during a multirecord
acquisition.
200 ni.com
NI-SCOPE
to perform other tasks and allows for better system performance. However, fetching
requires additional functions that initiate waveform acquisitions and query your board
to see if the acquisition is complete.
You use the same Fetch functions for both simple data acquisition and advanced data
acquisition such as multiple-record fetching. Although the functions have only the
numSamples parameter to determine how data is retrieved, NI-SCOPE offers several
attributes that allow you to specify advanced fetching options. The
NISCOPE_ATTR_FETCH_RELATIVE_TO and NISCOPE_ATTR_FETCH_OFFSET
attributes allow you to explicitly choose the portion of a record to retrieve. The
NISCOPE_ATTR_FETCH_RECORD_NUMBER and
NISCOPE_ATTR_FETCH_NUM_RECORDS attributes allow specifying the records to
retrieve during a multirecord acquisition.
Continuous acquisition is the ability to transfer data from the digitizer to the host
computer memory while the digitizer is still acquiring data, which can be useful for the
following applications:
NI digitizers contain a large amount of onboard memory, generally 8, 16, 32, or 256 MB
per channel. This memory is divided into individual records when acquiring data. For
example, if you are acquiring two records, 8 MB of memory is divided into two 4 MB
records. Each record is treated as a circular buffer. When the digitizer starts acquiring
data, the samples are placed in the beginning of the buffer. The digitizer acquires the
requested number of pretrigger samples—that is, the actual record length times the
reference position divided by 100. After the pretrigger samples are complete, the
digitizer waits for a trigger. While waiting, the digitizer continues to acquire and store
data. This data is placed in the circular buffer, so after the buffer is filled, the digitizer
starts overwriting data at the beginning. If a trigger never occurs, the digitizer waits for
a trigger forever. After the trigger occurs, the digitizer samples the requested number
of posttrigger samples, and the record is complete. If another record is requested, the
digitizer restarts the acquisition, moving to the next record in memory.
Continuous acquisition refers to the digitizer's ability to fetch data from its own
circular buffer to the host computer's memory while it is acquiring data. When you call
Initiate Acquisition, the digitizer starts acquiring data into its circular buffer,
as shown in the following figure.
202 ni.com
NI-SCOPE
Circular Buffer
Legend
You can then use a Fetch function to send the first chunk of data to the host computer
while the digitizer continues to acquire more samples, as shown in the following
figure.
Legend
When the circular buffer is filled on the digitizer, it starts to overwrite the data at the
beginning of the buffer, as shown in the following figure.
Legend
Ideally, you have already copied and saved the data that is being overwritten in the
host computer.
Legend
If you do not send a trigger, the digitizer continues to acquire data forever or until you
call Abort, Reset, or Close.
204 ni.com
NI-SCOPE
acquisition, but additional attributes are available to specify what data to fetch. In
particular, the Fetch Relative To attribute supports values of Read Pointer, Now,
and Start in addition to the standard Trigger and Pretrigger values. These values allow
specifying different locations within the record from which to start fetching. When
fetching data continuously, the possibility always exists that the data has been
overwritten in the onboard memory before you attempt to fetch it. NI-SCOPE returns
an error in this situation.
When fetching data continuously, the relative initial x value returned in the waveform
info structure is not valid until the trigger occurs. Often, the trigger never occurs during
continuous acquisitions. However, the waveform info structure also contains an
absolute initial x value, which is a free-running timestamp counter on the digitizer.
Additional status information about your acquisition is available by using the Fetch
Points Done and Fetch Records Done attributes. The points done is the
number of samples available in the record specified by the Fetch Record Number
attribute, starting at the Fetch Offset attribute that is relative to the Fetch
Relative To attribute. NI-SCOPE also supports a Fetch Backlog attribute,
which is the number of samples that have not been fetched when performing a
continuous acquisition.
Related concepts:
The standard use of continuous acquisition is to fetch a record that is larger than the
available memory on the digitizer. Because the data is fetched as it is acquired, the
digitizer memory can be overwritten. At slow sampling rates, you can fetch data
forever by setting up an acquisition that is never triggered and is repeatedly fetching.
At faster sampling rates, the host computer may not be able to fetch as fast as the
digitizer samples data. If the data that is being fetched is overwritten, NI-SCOPE
returns an error message from the Fetch function. Look at the Fetch in Chunks
example to see how a waveform can be reconstructed with the data from multiple
fetch calls. Look at the Fetch Forever example to benchmark how much data you
can acquire at a given sampling rate before the data is overwritten.
To fetch a record that is larger than memory, set the Fetch Relative To attribute
to Read Pointer. This positions the beginning of the fetch operation at the start of the
record when you initiate a new acquisition. After every fetch, the read pointer is
incremented to be the sample after the last sample retrieved. Therefore, you can
repeatedly fetch relative to the read pointer, with a retrieval offset of zero, to acquire a
single, infinite record.
If you specify a positive timeout with a Fetch function, it waits for the requested
number of samples. Alternatively, specifying a timeout of zero acquires the number of
samples currently available (up to a maximum of the numSamples parameter). The
waveform info structure returns the actual number of samples fetched. Using a
timeout of zero achieves slightly better performance because the status of the digitizer
is queried less often.
A separate read pointer is stored for each channel, so you can alternate fetching
different channels. The read pointer is also reset to zero when you fetch from a
different record.
Fetching records continuously can greatly speed up applications that have a very slow
trigger rate. If you are acquiring at 100 MS/s, but you only receive a trigger once every
second, you can completely fetch each record as soon as it is acquired by fetching each
record individually. You can set the Fetch Num Records attribute to 1 and
increment the Fetch Record Number attribute for each record you want to fetch.
Then, using a positive timeout with any of the Fetch functions causes the digitizer to
wait only for the next record to be acquired before it returns the waveform.
For lower-level control, NI-SCOPE supports the Records Done attribute that you can
poll to determine the current status of your acquisition.
206 ni.com
NI-SCOPE
During typical multirecord operation, each buffer in memory must be large enough to
contain all the pretrigger and posttrigger samples. If you request 1,000 points with
Configure Horizontal Timing, each record in memory must be at least 1,000
points; otherwise NI-SCOPE returns an error. Typically, all the records are required to
fit in memory, so you can wait until the entire acquisition is finished before fetching
anything.
However, in certain cases, you may want to acquire more records than would fit in the
onboard memory. In this situation, the records in memory are also circular. That
means if you configure four records and only three fit in memory, the fourth record
overwrites the first record. Ideally, you have time to fetch the first record to the host
computer memory before it is overwritten.
To fetch more records than fit in memory, set the Boolean attribute Enable More
Records Than Memory to TRUE and configure the desired number of records with
the Configure Horizontal Timing function. You must fetch the records
individually as described in Fetching Triggered Records while other Records are Being
Acquired. If the record you are attempting to fetch has been overwritten, NI-SCOPE
returns an error.
Caution The total number of records that you can acquire is limited. Each
record requires up to 64 bytes of page-locked memory. The actual amount of
page-locked memory depends on the amount of physical memory and the
number of other devices being used in your host computer. You can configure
as many records as you need, but save your work first.
Related concepts:
Another application of continuous acquisition is fetching a few of the most recent data
points. This technique is useful if you want chunks of nontriggered data with the same
configuration parameters. It avoids the software overhead necessary to reconfigure
the acquisition, and your program never needs to wait for the data to be acquired.
To fetch the most recent data, initiate an infinite acquisition—one that never
triggers—by configuring software triggering. When you want the most recent data
points, call a Fetch function with the Fetch Relative To attribute set to now,
which specifies that the offset is from the last sample acquired by the digitizer. You
must set the Fetch Offset attribute to the negated number of samples you want.
Setting the Fetch Relative To attribute to Start sets the starting fetch position to be the
first sample acquired by the digitizer. If the trigger happens immediately, the first point
sampled by the digitizer would equal the first pretrigger point. However, this is
generally not true because the digitizer usually has to wait for a trigger. While the
digitizer waits, it continues to sample data, possibly forever. As it samples data into the
circular, onboard memory, the original data is eventually overwritten. As in other
cases, if you attempt to fetch data that is overwritten, NI-SCOPE returns an error. A
typical use of fetching relative to start is to acquire nontriggered waveforms at precise
intervals. You can use the digitizer sample clock to precisely time the duration
between waveforms. Suppose you want 500 points every millisecond, while sampling
at 100 MS/s. You can set the Fetch Relative To attribute to start at the beginning of your
program. Then, for every iteration of a loop, call a Fetch function to retrieve 500
samples, and increment the Fetch Offset attribute by 100,000 samples. Because
100,000 samples are acquired every millisecond when sampling at 100 MS/s, this
program is effectively using the sample clock to precisely time the interval between
acquired waveforms.
The main benefit of multiple-record acquisitions is that you can acquire numerous
triggered waveforms quickly. Multiple-record acquisitions allow hardware rearming of
the digitizer. The digitizer hardware must transition between several states (given by
the digitizer's Acquisition Engine State Diagram) before it is ready to accept a
208 ni.com
NI-SCOPE
subsequent trigger. If two triggers arrive, one shortly after the other, the digitizer may
or may not detect the second trigger.
• If the second trigger arrives before the first record completes, it will not be
accepted. Only one trigger can be accepted in any one record in the NI-SCOPE
driver.
• If the second trigger arrives after the first record completes, but before the dead
time has elapsed, it will not be accepted.
• If the second trigger arrives after the first record completes and after the dead time
has elapsed, but before the minimum pre-reference trigger sampling for the
subsequent record is complete, it will not be accepted.
• If the second trigger arrives after the first record completes, the dead time has
elapsed, and the minimum pre-reference trigger sampling is finished, the trigger
will be accepted.
Minimum Minimum Minimum
Post-Reference Pre-Reference Post-Reference Pre-Reference Post-Reference Pre-Reference
Trigger Trigger Trigger Trigger Trigger Trigger
Sampling Sampling Sampling Sampling Sampling Sampling
Trigger
Level
= Trigger Accepted
= Trigger Rejected
Note The information above assumes that there are no holdoff values set
(for example, trigger holdoff).
The minimum time between triggers can be calculated with the dead time and the
time per record as follows: Minimum Time Between Triggers = Time Per Record + Dead
Time
The maximum trigger rate can be calculated as follows: Maximum Trigger Rate (Hz) =
1/(Minimum Time Between Triggers)
When the reference trigger type is set to immediate and all holdoff values = 0 seconds,
the digitizer will trigger at the maximum trigger rate regardless of any external signal.
Some digitizers specify a minimum rearm time. Minimum rearm time is the minimum
time between reference triggers as the record length approaches a minimum (for
example, record length = 1 sample). Therefore, when the record length is 1 sample,
Maximum Trigger Rate (Hz) = 1/(minimum rearm time).
Multiple-Record Example
Related topics
Trigger Holdoff Fundamentals
Related concepts:
You use the same Fetch functions discussed in Acquisition Functions—Reading versus
Fetching for retrieving multirecord acquisitions. However, two additional attributes are
available for specifying which records to retrieve. The Fetch Record Number
attribute is the zero-based index of the first record to fetch, and the Fetch Number
of Records attribute specifies how many records to fetch. By default, the Fetch
Number of Records is –1, which means fetch all the records starting at the Fetch
Record Number.
The Fetch functions wait for specified number of samples to be acquired when the
timeout parameter is positive. During a multirecord acquisition, they wait for the
requested number of samples in each record. Because the number of records attribute
defaults to –1 (or all the records), Fetch functions wait for all the specified number of
samples in all the records.
210 ni.com
NI-SCOPE
Fetching multiple records with a single Fetch function requires understanding the
order of the returned waveforms. All record 0 waveforms come before all record 1
waveforms. For example, fetching data with a channel list of "0,1" for three records
results in the following order:
• Channel 0 Record 0
• Channel 1 Record 0
• Channel 0 Record 1
• Channel 1 Record 1
• Channel 0 Record 2
• Channel 1 Record 2
For C and Visual Basic users, the waveforms are all packed into a one-dimensional
array that is declared using code such as the following:
For LabVIEW users, the waveforms are returned in either a two-dimensional array or an
array of clusters that include timing information. In both cases, you can use the index
array function to extract the waveform of interest.
You can also fetch each record individually by setting the Fetch Number of
Records parameter to 1. Then, in a loop set the Fetch Record Number attribute
to the zero-based index of the record you want to fetch and call one of the Fetch
functions.
Related concepts:
• Acquisition Functions
This section describes the different ways to make waveform measurements, which are
processed in software by NI-SCOPE. For more information, refer to the following:
Often the time-domain data returned from a digitizer requires processing before
measurements are done. To do this, register an array measurement as a processing
step by using the AddWaveformProcessing function. At the time of registering the
processing step, the entire set of NISCOPE_ATTR_MEAS parameters are cached.
Then when a measurement function is called, the processing measurements are
completed with this cached set of parameters, and the result is used in the
measurement. This allows streaming together of measurements. For example, if you
register Add Channels and Bessel Filter as processing steps, fetching a frequency
measurement actually gives you the frequency of the filtered summation of two
channels.
Related concepts:
You can fetch scalar and array measurements with the Fetch Measurement,
Fetch Measurement Stats, and Fetch Array Measurement functions.
The channel list and timeout parameters are identical to the waveform functions.
212 ni.com
NI-SCOPE
However, instead of returning waveforms, these functions return either the specified
scalar measurement or the specified array measurement. In LabVIEW, versions exist
that fetch either a single measurement or an array of measurements. The C and Visual
Basic versions return an array of measurement results, just as the Fetch functions can
return an array of waveforms. The order of the returned results is the same as in the
Fetch functions. C and Visual Basic users can dynamically declare memory for the
measurement results using code such as the following.
Note The following sample code uses the Actual Meas Wfm Size
function to query how many samples are available in the resulting array
measurement.
Steps for Fetching Scalar and Array Data with Fetch Functions
Related concepts:
• Waveform Measurements
• Using Attributes in Waveform Measurements
• Fetching Statistics from Waveform Measurements
By default, the Fetch Measurement functions use the entire acquired waveform for the
analysis. However, all the fetching attributes apply when determining what data is
used for the measurement. In addition to the normal fetch attributes such as Fetch
Relative To and Fetch Offset, the Fetch Meas Num Samples attribute
allows you to specify the number of samples fetched for performing the measurement.
By default, this attribute is –1, which fetches the actual record length. This attribute is
the same as the numSamples parameter in the other Fetch functions.
Use the channel-based attributes to set the reference levels. The Measurement
Library example shows how to set the reference levels. You can customize how NI-
SCOPE configures the percentages used for the reference levels with the Percentage
Method attribute. This attribute uses any of the following constants:
• Min Max—This method uses the measurement's voltage minimum and voltage
maximum as 0% and 100%. These algorithms find the absolute minimum and
maximum in the waveform, which is useful for sine waves and triangle waves
where the histogram method does not work.
• Low High—This method uses the measurement's voltage low and voltage high as
0% and 100%. The voltage low is the voltage of the histogram bin with the most
hits below 40% of the waveform's voltage peak-to-peak value. The voltage high is
the voltage of the histogram bin with the most hits above 60% of the waveform's
voltage peak-to-peak value. These measurements use the last-acquisition
histogram method to find the most common high and low voltages, which is useful
for ignoring the preshoot and overshoot on a square wave.
• Base Top—The voltage base and voltage top measurements correspond to 0% and
214 ni.com
NI-SCOPE
100% with this method. These measurements use the last-acquisition histogram
method if the most common histogram bin contains a substantial number of the
total points. Otherwise, it returns the absolute minimum and maximum values in
the waveform, which is a useful default value for most waveform types.
You can also configure the reference levels in terms of voltage with the Ref Level Units
attribute.
Related concepts:
• Reference Levels
The Fetch Measurement Stats function returns the current measurement result
as well as statistics for this measurement over multiple acquisitions. Every time you
fetch a measurement, NI-SCOPE keeps a history of the measurement values, which
allows NI-SCOPE to compute the mean, standard deviation, minimum, and maximum
value of each scalar measurement. To clear the statistics history, use Clear
Waveform Measurement Stats.
The following figure shows the programming flow for making scalar measurements.
Initialize
Configure
Initiate
Initiates data acquistion
Fetch Measurement
Polls digitizer until data
is available, fetches the
waveform, and performs the
scalar measurement
Error Handler
(not required in LabVIEW)
Close
Refer to the Measurement Library example for sample code you can use to
create your own application. This example demonstrates fetching scalar
measurements and statistics. The Advanced Measurement Library example
demonstrates how to fetch a scalar measurement on a processed waveform.
The following figure shows the programming flow for making array measurements.
216 ni.com
NI-SCOPE
Initialize
Configure
Initiate
Begins acquiring pretrigger data
Error Handler
Close
Refer to the Advanced Waveform Measurement example for sample code you
can use to create your own application. The Digital Filtering and Windowing
examples for LabVIEW also use array measurements.
Histogram Measurements
measurements such as pulse height analysis and distortion with voltage histograms.
In some cases the statistical distribution of response values gives richer insights than
numerical representations such as mean, median, standard deviation, and mode.
Histograms are specialized plots that capture statistical data about how many times
specific values occur. Histograms are usually plotted with the dependent variable
along the vertical axis and the independent variable along the horizontal axis.
To create a histogram from discrete response data, a count is taken each time a
discrete value occurs. For example, the following figure is a histogram of 20 students'
letter grades on a test. The discrete values are the letter grades and the counts
represent the number of students who received each grade.
8
6
Number of Students
0
A B C D F
Grade
218 ni.com
NI-SCOPE
6
Number of Students
0
5 15 25 35 45 55 65 75 85 95
Percentage
Related concepts:
• Time Histograms
• Voltage Histograms
Time Histograms
Time histograms place samples that fall within a defined voltage range and time
window into bins based on their time relative to a trigger point. The time resolution of
time histograms depends directly on the precision with which samples can be
positioned in time relative to the trigger. More precise positioning of the sample in
time allows the use of more histogram bins of smaller size, increasing histogram
resolution. Often, digitizers can only resolve samples in time with a resolution equal to
the sample period. Many NI digitizers, however, include a high-resolution Time-to-
Digital Conversion (TDC) circuit. Using a process called time-stamping, the TDC circuit
locates samples relative to the trigger point with exceptional precision. For example,
the NI 5122 is equipped with a TDC circuit that allows time-stamping of samples with
100 ps resolution, while using a 10 ns sample period. Thus, TDC circuitry and time-
stamping allow you to sort data into highly resolved time histogram bins and maximize
histogram resolution.
The following figures demonstrate how time histograms are constructed. The first
figure is a time-domain waveform sampled by a high-speed digitizer. The second figure
shows the corresponding time histogram. Multiple pulses are acquired, and an edge
trigger is used to align the rising edge of each pulse. Histogram voltage (vertical)
discriminator levels are configured to define a window around the falling edges of
each pulse—the shaded region in the figure. Make sure you capture only the falling
edges of the waveform when setting these discriminator levels—otherwise, the
histogram appears perfectly uniform.
Time Histogram
High Volts
Trigger
Time Histogram
Low Volts
Acquisition 3
Acquisition 2
Acquisition 1
When you use this setup, every sample on the falling edge is added to the time
histogram shown in the following figure. In this example, both the first and third
acquisitions have a falling edge at the same time, while the second acquisition is later.
The histogram captures this statistical information.
Hits
Low High
Time Time
220 ni.com
NI-SCOPE
Histograms can be used to characterize delay jitter between the input and output of a
real-time I/O system. By definition, a real-time system is deterministic in time, but it is
useful to know exactly how deterministic a given measurement system is. Time
histogram measurements can be used to characterize the jitter in real-time systems,
which in turn allows measurement of the determinism of a real-time I/O system.
Let's look at a specific example: feeding a square wave into the analog input of a real-
time system while sampling at a rate of 1 kHz. The samples acquired are output to an
analog channel by the real-time system one clock cycle later. This provides a
deterministic delay of 1 msec between the analog input and the analog output of the
real-time system. Measurement of the jitter in this delay between the input and output
yields a measure of the reliability of the real-time I/O system.
In this example, the NI 5122 two-channel high-speed digitizer is used to measure the
jitter. The input square wave and the analog output of the real-time system are
sampled by the NI 5122. A time histogram of the delay from the edge on one channel
to the same edge on the second channel is created. Statistics from the time histogram
such as Time Histogram Min, Time Histogram Max, Time Histogram Hits and Time
Histogram Mean yield measurements of the maximum jitter, the number of measured
samples in the histogram, and the mean delay.
The results shown in the following figure yield a Gaussian distribution of the variations
of the delay, meaning that this jitter is most likely derived from random electrical noise
in the measurement system.
Related concepts:
To create a time histogram, you must use attributes/properties and follow these
general steps:
1. Set the size of the histogram using the Time Histogram Size property or the
NISCOPE_ATTR_MEAS_TIME_HISTOGRAM_SIZE attribute. The default size is
256 bins. The more bins used, the greater the histogram resolution.
2. Time limits determine the temporal window. Set the time limits for the histogram
using the Time Histogram Low Time property or the
NISCOPE_ATTR_MEAS_TIME_HISTOGRAM_LOW_TIME attribute. for the
222 ni.com
NI-SCOPE
beginning time. Use the Time Histogram High Time property or the
NISCOPE_ATTR_MEAS_TIME_HISTOGRAM_HIGH_TIME attribute for the
ending time. Set these values during the first measurement after the histogram
history is cleared.
3. Histogram voltage limits determine the vertical window. Set the voltage limits for
the acquisition using the Time Histogram Low Volts property or the
NISCOPE_ATTR_MEAS_TIME_HISTOGRAM_LOW_VOLTSattribute and the
Time Histogram High Volts property or the
NISCOPE_ATTR_MEAS_TIME_HISTOGRAM_HIGH_VOLTS attribute. These
values can change every acquisition.
Refer to the niScope EX Time Histogram.vi example for sample code you can
use to create your own application.
Related concepts:
• Time Histograms
Voltage Histograms
Voltage Histogram
High Volts
Voltage Histogram
Low Volts
Note The higher amplitude pulse occurs twice. The lower amplitude pulse
occurs only once.
Hits
Low High
Volts Volts
The voltage histogram of a sine waveform ideally looks like a saddle with the peaks
occurring at the maxima and minima of the sine waveform. The saddle is centered at
zero if the sine waveform has no DC voltage offset. Any anomalous peaks in the
histogram between the maxima and minima reflect nonlinear distortion in the sine
waveform. A peak at the center of the voltage histogram reflects zero-crossing
distortion, which is a key concern for output amplifier performance.
224 ni.com
NI-SCOPE
The two following figures show voltage histograms taken using an NI 5122 high-speed
digitizer. The histograms characterize the sine output of two function generators. The
sine output in the first figure is relatively distortion-free and the histogram centers at
zero. By contrast, the histogram in the second figure is not centered at zero, indicating
distortion and voltage drift in the sine output. Thus, while neither histogram shows
zero-crossing distortion to be a primary problem, the noisy histogram in the second
figure reveals considerable spectral purity degradation in the second function
generator.
pk-pk
pk-pk
Related concepts:
To create a voltage histogram, you must use attributes and follow these general steps:
1. Set the size of the histogram with the Voltage Histogram Size property or the
NISCOPE_ATTR_MEAS_VOLTAGE_HISTOGRAM_SIZE attribute. This property
defines the number of histogram bins. The larger the number of bins, the more
resolution you have in the histogram. The default size is 256 bins.
2. Set the low limit of the voltage histogram with Voltage Histogram Low Volts
property or the NISCOPE_ATTR_MEAS_VOLTAGE_HISTOGRAM_LOW_VOLTS
attribute. Set the high limit of the voltage histogram with Voltage Histogram High
Volts property or the
NISCOPE_ATTR_MEAS_VOLTAGE_HISTOGRAM_HIGH_VOLTS attribute.
226 ni.com
NI-SCOPE
Refer to the niScope EX Voltage Histogram.vi example for sample code you
can use to create your own application.
Related concepts:
• Voltage Histograms
Coercions
Related concepts:
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:
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.
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:
228 ni.com
NI-SCOPE
In the Configure Vertical function, vertical range is coerced to the next higher
valid vertical range for the digitizer. You can determine the actual value with a Binary
Fetch function.
Note You can also use the Vertical Range attribute to determine the
coerced value.
The gain scale factor is the volts/binary value. Therefore, if you use the Fetch
Binary 8 function, the actual vertical range is the gain scale factor times 256, with
256 being the number of binary values in an 8-bit number. If this vertical range is set
higher than the maximum vertical range of the digitizer, NI-SCOPE returns an error.
Probe attenuation is applied exactly as specified. Therefore, if you select a 1.234 probe
attenuation, your data is the voltage measured multiplied by 1.234. NI-SCOPE adjusts
your vertical range based on the probe attenuation parameter, so the resulting voltage
after the probe attenuation scaling is within the range specified. For example, if your
probe attenuation is 10 and your vertical range is 10 V, the digitizer is set to measure a
1 Vpk-pk signal. The data returned with the Fetch function is 10 Vpk-pk.
The input impedance and vertical coupling parameters are not coerced. These
parameters return an error if the value is not valid for the digitizer.
The trigger level, low level, high level, and hysteresis parameters found in the
Configure Trigger functions are all coerced to the nearest valid value. Typically the
hardware uses an 8–, 10–, or 12-bit DAC to set the trigger levels. The exact values
cannot be queried for these parameters.
Many LabVIEW VIs contain error in parameters you can use to manage errors. These
parameters typically provide the same, standard functionality. When a node exhibits
different parameter functionality, the exceptions are documented in the reference
material for that node. Standard error in behavior is as follows
Note Some nodes, such as error handling VIs, contain an error in parameter
that does not provide standard error in functionality, but that contains an
error in cluster that is standard.
error in describes error conditions that occur before this node runs. The default is no
error. If an error occurred before this node runs, the node passes the error in value to error
out. This node runs normally only if no error occurred before this node runs. If an error
occurs while this node runs, it runs normally and sets its own error status in error out. Use
230 ni.com
NI-SCOPE
error in and error out to check errors and to specify execution order by wiring error out from
one node to error in of the next node.
status is TRUE (X) if an error occurred before this node ran or FALSE (checkmark) to indicate a
warning or that no error occurred before this node ran. The default is FALSE.
code is the error or warning code. The default is 0. If status is TRUE, code is an error code. If
status is FALSE, code is 0 or a warning code.
source specifies the origin of the error or warning and is, in most cases, the name of the node
that produced the error or warning. The default is an empty string.
Many LabVIEW VIs contain an error out parameter you can use to manage errors. These
parameters typically provide the same, standard functionality. When a node exhibits
different parameter functionality, the exceptions are documented in the reference
material for that node.
error out contains error information. If error in indicates that an error occurred before this VI
ran, error out contains the same error information. Otherwise, it describes the error status
that this VI produces. Right-click the error out front panel indicator and select Explain Error
from the shortcut menu for more information about the error.
status is TRUE (X) if an error occurred or FALSE (checkmark) to indicate a warning or that no
error occurred.
code is the error or warning code. If status is TRUE, code is an error code. If status is FALSE,
code is 0 or a warning code.
source specifies the origin of the error or warning and is, in most cases, the name of the node
that produced the error or warning.
Histogram Measurements
LabVIEW C/C++
Last Acq Histogram NISCOPE_VAL_LAST_ACQ_HISTOGRAM
Multi Acq Time Histogram NISCOPE_VAL_MULTI_ACQ_TIME_HISTOGRAM
Multi Acq Voltage Histogram NISCOPE_VAL_MULTI_ACQ_VOLTAGE_HISTOGRAM
Window Measurements
LabVIEW C/C++
Blackman Window NISCOPE_VAL_BLACKMAN_WINDOW
Hanning Window NISCOPE_VAL_HANNING_WINDOW
Flat Top Window NISCOPE_VAL_FLAT_TOP_WINDOW
Triangle_Window NISCOPE_VAL_TRIANGLE_WINDOW
Hamming Window NISCOPE_VAL_HAMMING_WINDOW
Filter Measurements
LabVIEW C/C++
Bessel IIR Filter NISCOPE_VAL_BESSEL_FILTER
FIR Windowed Filter NISCOPE_VAL_WINDOWED_FIR_FILTER
Butterworth IIR Filter NISCOPE_VAL_BUTTERWORTH_FILTER
Chebyshev IIR Filter NISCOPE_VAL_CHEBYSHEV_FILTER
232 ni.com
NI-SCOPE
LabVIEW C/C++
Add Channels NISCOPE_VAL_ADD_CHANNELS
Multiply Channels NISCOPE_VAL_MULTIPLY_CHANNELS
Divide Channels NISCOPE_VAL_DIVIDE_CHANNELS
Subtract Channels NISCOPE_VAL_SUBTRACT_CHANNELS
Math Measurements
LabVIEW C/C++
Derivative NISCOPE_VAL_DERIVATIVE
Multi_Acq_Average NISCOPE_VAL_MULTI_ACQ_AVERAGE
Array Integral NISCOPE_VAL_ARRAY_INTEGRAL
Inverse NISCOPE_VAL_INVERSE
Array Gain NISCOPE_VAL_ARRAY_GAIN
Array Offset NISCOPE_VAL_ARRAY_OFFSET
FFT Measurements
LabVIEW C/C++
FFT Amp Spectrum (dB) NISCOPE_VAL_FFT_AMP_SPECTRUM_DB
FFT Phase Spectrum NISCOPE_VAL_FFT_PHASE_SPECTRUM
FFT Amp Spectrum (Volts RMS) NISCOPE_VAL_FFT_AMP_SPECTRUM_VOLTS_RMS
Resampling Measurements
LabVIEW C/C++
Polynomial Interpolation NISCOPE_VAL_POLYNOMIAL_INTERPOLATION
Related concepts:
The initial x value returned is the bin value for the first bin, corresponding to the
midpoint of the range of values in the first bin. The x increment returned is the bin
size. The last acquisition histogram method is used by the voltage low and voltage high
measurements for computing the extrema of a waveform. This method is useful for
ignoring overshoot or preshoot in a square waveform.
234 ni.com
NI-SCOPE
In the last acquisition histogram method, a voltage histogram is created from the most
recent acquisition. The limits of the histogram are set by the minimum and maximum
voltages of the acquisition. NI-SCOPE then counts how many samples fall into each bin
of the histogram. The resolution is defined by the Last Acquisition Histogram Size
attribute, which is 256 bins by default. You can fetch the histogram array using the
Fetch Array Measurement function, with Last Acquisition Histogram constant specified
as the array measurement function. The following illustrations show an example of a
square wave and its resulting histogram. The voltage low and voltage high
measurements correspond to the middle value of a bin with the maximum number of
hits in the lower 40% or upper 40%, respectively.
Voltage Max
Voltage High
Voltage Low
Voltage Min
Hits
Min Lo Hi Max
Units
Count
X Units
Volts
NI-SCOPE_ATTR_LAST_ACQ_HISTOGRAM_SIZE Attribute
236 ni.com
NI-SCOPE
The initial x value returned is the bin value for the first bin, corresponding to the
midpoint of the range of values in the first bin. The x increment returned is the bin
size.
Units
Count
X Units
Seconds
The initial x value returned is the bin value for the first bin, corresponding to the
midpoint of the range of values in the first bin. The x increment returned is the bin
size.
Units
Count
X Units
Volts
Blackman Window
Units
Volts
X Units
Seconds
inputSize
Hanning Window
238 ni.com
NI-SCOPE
The Hanning window is useful for analyzing transients longer than the time duration of
the window, and also for general-purpose applications. A Hanning window is applied
to the waveform using the following equation:
Units
Volts
X Units
Seconds
inputSize
The Flat Top window has the best amplitude accuracy of all the window functions. The
increased amplitude accuracy (±0.02 dB for signals exactly between integral cycles) is
at the expense of frequency selectivity. The Flat Top window is most useful in
accurately measuring the amplitude of single frequency components with little nearby
spectral energy in the signal. A Flat Top window is applied to the waveform using the
following equation:
Units
volts
X Units
Seconds
inputSize
Triangle Window
240 ni.com
NI-SCOPE
Units
Volts
X Units
Seconds
inputSize
Hamming Window
Units
Volts
X Units
Seconds
inputSize
The input waveform is filtered with a Bessel IIR algorithm. The type of the filter is
specified by Measurement Filter Type as any of the following values:
• lowpass
• highpass
• bandpass
• bandstop
The order of the filter is specified by the Filter IIR Order property or the
NISCOPE_ATTR_MEAS_FILTER_ORDER attribute. Also, a number of points equal
to the Percent Waveform Transient property or the
NISCOPE_ATTR_MEAS_FILTER_TRANSIENT_WAVEFORM_PERCENT attribute
divided by 100 times the input size are eliminated from the beginning of the filtered
waveform so that the transient response of the filter does not affect further
measurements.
Units
Volts
242 ni.com
NI-SCOPE
X Units
or
inputSize × (1 –
NISCOPE_ATTR_MEAS_FILTER_TRANSIENT_WAVEFORM_PERCENT attribute /
100)
Related Topics
Bessel Filters
Related concepts:
• Bessel Filters
FIR filters are well suited for applications that require phase information, because the
phase response is always linear. This linearity prevents distortion of time-domain
filtered data. The transient response of an FIR filter is a fixed number of points, filter
taps –1, which are eliminated in the filtered waveform returned from this VI.
Windowed FIR filters use the cutoff frequency as part of the design process, but the
cutoff is specified before the windowing operation. For Windowed FIR filters of
sufficient taps (more than 10 for a simple lowpass), the cutoff frequency has a
magnitude near 0.5 (or 6 dB down). This magnitude varies slightly with the order and
the window type.
The number of taps in the filter (that is, the number of coefficients in the filter) is given
Units
Volts
X Units
or
The input waveform is filtered with a Butterworth IIR algorithm. The type of the filter is
specified by Filter Type as any of the following values:
• lowpass
• highpass
• bandpass
• bandstop
The order of the filter is specified by the Filter IIR Order property or the
NISCOPE_ATTR_MEAS_FILTER_ORDER attribute. Also, a number of points equal
to Percent Waveform Transient property or the
NISCOPE_ATTR_MEAS_FILTER_TRANSIENT_WAVEFORM_PERCENT attribute
divided by 100 times the input size are eliminated from the beginning of the filtered
244 ni.com
NI-SCOPE
waveform so the transient response of the filter does not affect further measurements.
Units
Volts
X Units
or
inputSize × (1 –
NISCOPE_ATTR_MEAS_FILTER_TRANSIENT_WAVEFORM_PERCENT attribute /
100)
Related Topics
Butterworth Filters
Related concepts:
• Butterworth Filters
The input waveform is filtered with a Chebyshev IIR algorithm. The type of the filter is
specified by the Filter Type property or the NISCOPE_ATTR_MEAS_FILTER_TYPE
attribute as any of the following values:
• lowpass
• highpass
• bandpass
• bandstop
The Chebyshev filter allows you to specify the passband ripple, the Filter Ripple or the
NISCOPE_ATTR_MEAS_FILTER_RIPPLE, in decibels. The order of the filter is
specified by the Filter Order property or the
NISCOPE_ATTR_MEAS_FILTER_ORDER attribute. Also, a number of points equal
to the Percent Waveform Transient property or the
NISCOPE_ATTR_MEAS_FILTER_TRANSIENT_WAVEFORM_PERCENT attribute
divided by 100 times the input size are eliminated from the beginning of the filtered
waveform, so the transient response of the filter does not affect further
measurements.
Units
Volts
X Units
or
inputSize × (1 –
NISCOPE_ATTR_MEAS_FILTER_TRANSIENT_WAVEFORM_PERCENT attribute /
100)
Related Topics
Chebyshev Filters
Related concepts:
• Chebyshev Filters
246 ni.com
NI-SCOPE
Add Channels
Adds the waveforms from two channels, where one channel is specified by the
channel parameter to the niScope Fetch Measurement (poly) VI (Measurement Scalar
DBL instance) or the niScope_FetchWaveformMeasurementArray function,
and the other channel is specified by the Other Channel property or the
NISCOPE_ATTR_MEAS_OTHER_CHANNEL attribute. Any processing steps registered
with the niScope Add Waveform Processing VI or the
niScope_AddWaveformProcessing function are completed for the other channel
before this measurement is taken. The two channels used in this measurement must
be different.
Units
Volts
X Units
Seconds
Multiply Channels
Multiplies the waveforms from two channels, where one channel is specified by the
channel parameter to the niScope Fetch Measurement (poly) VI (Measurement Scalar
DBL instance) or the niScope_FetchWaveformMeasurementArray function,
and the other channel is the Other Channel property or the
NISCOPE_ATTR_MEAS_OTHER_CHANNEL attribute. Any processing steps registered
with the niScope Add Waveform Processing VI or the
niScope_AddWaveformProcessing function are completed for the "other
channel" before this measurement is taken. The two channels used in this
measurement must be different.
Units
Volts2
X Units
Seconds
Divide Channels
The channel specified by the channel parameter to niScope Fetch Measurement (poly)
VI (Measurement Scalar DBL instance) or the or the
niScope_FetchWaveformMeasurementArray function, is divided by the
channel specified by the Other Channel property or the
NISCOPE_ATTR_MEAS_OTHER_CHANNEL attribute. Any processing steps registered
with the niScope Add Waveform Processing VI or the
niScope_AddWaveformProcessing function are completed for the other
channel before this measurement is taken. The two channels used in this
measurement must be different.
Units
None
X Units
Seconds
248 ni.com
NI-SCOPE
Subtract Channels
Units
Volts
X Units
Seconds
Derivative
y[i] = (waveform[i+2] – waveform[i]) / (2 × dt), where dt is the time between two points.
Units
Volts/second
X Units
seconds
inputSize - 2
The first time this measurement is called after it is cleared, an array the same size as
the input is initialized to the input waveform, and the initial x and x increment values
are set. Every subsequent call updates and returns the running average array without
affecting the size of the array. The average array is cleared by calling niScope Clear
Waveform Measurement Stats VI or the niScope_ClearWaveformMeasurementStats
with the measurement function parameter set to Multi Acq Average.
Units
Volts
X Units
Seconds
inputSize (during the first call to this measurement after clearing it)
Array Integral
250 ni.com
NI-SCOPE
The waveform is integrated using Simpson's rule, fitting a parabola to every 3 points
with the equation:
Units
Volts × Seconds
X Units
Seconds
inputSize – 2
Inverse
Units
1.0/volts
X Units
Seconds
inputSize
Array Gain
Every point in the waveform is multiplied by the scalar value Array Gain.
Units
X Units
Seconds
Array Offset
The scalar value of measurement array offset is added to every point in the waveform.
Units
X Units
Seconds
The amplitude spectrum is calculated using a split-radix real FFT. If the number of
acquired points is not a power of two, zeros are padded at the end of the waveform so
it is the next higher power of two. The FFT is scaled to decibels:
252 ni.com
NI-SCOPE
Units
X Units
hertz
The phase spectrum is calculated using a split-radix real FFT. If the number of acquired
points is not a power of two, zeros are padded at the end of the waveform so it is the
next higher power of two. The phase spectrum is unwrapped.
Units
Radians
X Units
hertz
The amplitude spectrum is calculated using a split-radix real FFT. If the number of
acquired points is not a power of two, zeros are padded at the end of the waveform so
Units
Volts RMS
X Units
hertz
Polynomial Interpolation
For every consecutive (order + 1) number of points, a polynomial is fit to the points,
and new points are interpolated in a region of size dx in the middle of these order + 1
points, where dx is the original x spacing between two points in the waveform. This
results in the interpolation shrinking the total x size of the waveform, since points
cannot be accurately interpolated near the boundaries. In particular, the waveform
loses 0.5 × dx × (order – 1) amount of x range at both the beginning and the end of the
waveform.
Units
Volts
254 ni.com
NI-SCOPE
X Units
Seconds
or
LabVIEW C/C++
AC Estimate NISCOPE_VAL_AC_ESTIMATE
Voltage Cycle RMS NISCOPE_VAL_VOLTAGE_CYCLE_RMS
FFT Amplitude NISCOPE_VAL_FFT_AMPLITUDE
Voltage RMS NISCOPE_VAL_VOLTAGE_RMS
DC Voltage Measurements
LabVIEW C/C++
Voltage Average NISCOPE_VAL_VOLTAGE_AVERAGE
Voltage Cycle Average NISCOPE_VAL_VOLTAGE_CYCLE_AVERAGE
LabVIEW C/C++
DC Estimate NISCOPE_VAL_DC_ESTIMATE
Area Measurements
LabVIEW C/C++
Area NISCOPE_VAL_AREA
Integral NISCOPE_VAL_INTEGRAL
Cycle Area NISCOPE_VAL_CYCLE_AREA
LabVIEW C/C++
Voltage Min NISCOPE_VAL_VOLTAGE_MIN
Voltage Low NISCOPE_VAL_VOLTAGE_LOW
Voltage Max NISCOPE_VAL_VOLTAGE_MAX
Voltage High NISCOPE_VAL_VOLTAGE_HIGH
Voltage Peak to Peak NISCOPE_VAL_VOLTAGE_PEAK_TO_PEAK
Voltage Amplitude NISCOPE_VAL_AMPLITUDE
Voltage Base NISCOPE_VAL_VOLTAGE_BASE
Voltage_Top NISCOPE_VAL_VOLTAGE_TOP
Voltage Base to Top NISCOPE_VAL_VOLTAGE_BASE_TO_TOP
Overshoot NISCOPE_VAL_OVERSHOOT
Preshoot NISCOPE_VAL_PRESHOOT
Reference Levels
LabVIEW C/C++
Low Ref Volts NISCOPE_VAL_LOW_REF_VOLTS
Mid Ref Volts NISCOPE_VAL_MID_REF_VOLTS
256 ni.com
NI-SCOPE
LabVIEW C/C++
High Ref Volts NISCOPE_VAL_HIGH_REF_VOLTS
Time Measurements
LabVIEW C/C++
Fall Time NISCOPE_VAL_FALL_TIME
Positive Duty Cycle NISCOPE_VAL_DUTY_CYCLE_POS
Falling Slew Rate NISCOPE_VAL_FALL_SLEW_RATE
Rise Time NISCOPE_VAL_RISE_TIME
Negative Width NISCOPE_VAL_WIDTH_NEG
Rising Slew Rate NISCOPE_VAL_RISE_SLEW_RATE
Positive Width NISCOPE_VAL_WIDTH_POS
Negative Duty Cycle NISCOPE_VAL_DUTY_CYCLE_NEG
LabVIEW C/C++
Phase Delay NISCOPE_VAL_PHASE_DELAY
Time Delay NISCOPE_VAL_TIME_DELAY
LabVIEW C/C++
Average Frequency NISCOPE_VAL_AVERAGE_FREQUENCY
FFT Frequency NISCOPE_VAL_FFT_FREQUENCY
Average Period NISCOPE_VAL_AVERAGE_PERIOD
Frequency NISCOPE_VAL_FREQUENCY
Period NISCOPE_VAL_PERIOD
LabVIEW C/C++
Time Hist Hits NISCOPE_VAL_TIME_HISTOGRAM_HITS
Time Hist Mean + 3 Stdev NISCOPE_VAL_TIME_HISTOGRAM_MEAN_PLUS_3_STDEV
Time Hist Max NISCOPE_VAL_TIME_HISTOGRAM_MAX
Time Hist Median NISCOPE_VAL_TIME_HISTOGRAM_MEDIAN
Time Hist Mean NISCOPE_VAL_TIME_HISTOGRAM_MEAN
Time Hist Min NISCOPE_VAL_TIME_HISTOGRAM_MIN
Time Hist Peak to Peak NISCOPE_VAL_TIME_HISTOGRAM_PEAK_TO_PEAK
Time Hist Mode NISCOPE_VAL_TIME_HISTOGRAM_MODE
Time Hist Mean + Stdev NISCOPE_VAL_TIME_HISTOGRAM_MEAN_PLUS_STDEV
Time Hist New Hits NISCOPE_VAL_TIME_HISTOGRAM_NEW_HITS
Time Hist Mean + 2 Stdev NISCOPE_VAL_TIME_HISTOGRAM_MEAN_PLUS_2_STDEV
Time Hist Stdev NISCOPE_VAL_TIME_HISTOGRAM_STDEV
LabVIEW C/C++
Volt Hist Hits NISCOPE_VAL_VOLTAGE_HISTOGRAM_HITS
Volt Hist Median NISCOPE_VAL_VOLTAGE_HISTOGRAM_MEDIAN
Volt Hist Max NISCOPE_VAL_VOLTAGE_HISTOGRAM_MAX
Volt Hist Min NISCOPE_VAL_VOLTAGE_HISTOGRAM_MIN
Volt Hist Mean NISCOPE_VAL_VOLTAGE_HISTOGRAM_MEAN
Volt Hist Mode NISCOPE_VAL_VOLTAGE_HISTOGRAM_MODE
Volt Hist Mean + Stdev NISCOPE_VAL_VOLTAGE_HISTOGRAM_MEAN_PLUS_STDEV
Volt Hist New Hits NISCOPE_VAL_VOLTAGE_HISTOGRAM_NEW_HITS
Volt Hist Mean + 2 Stdev NISCOPE_VAL_VOLTAGE_HISTOGRAM_MEAN_PLUS_2_STDEV
Volt Hist Peak to Peak NISCOPE_VAL_VOLTAGE_HISTOGRAM_PEAK_TO_PEAK
258 ni.com
NI-SCOPE
LabVIEW C/C++
Volt Hist Mean + 3 Stdev NISCOPE_VAL_VOLTAGE_HISTOGRAM_MEAN_PLUS_3_STDEV
Volt Hist Stdev NISCOPE_VAL_VOLTAGE_HISTOGRAM_STDEV
Related concepts:
• AC Estimate
• Voltage Cycle RMS
• FFT Amplitude
• Voltage RMS
• Voltage Average
• Voltage Cycle Average
• DC Estimate
• Area
• Integral
• Cycle Area
• Voltage Min
• Voltage Low
• Voltage Max
• Voltage High
• Voltage Peak to Peak
• Voltage Amplitude
• Voltage Base
• Voltage Top
• Voltage Base to Top
• Overshoot
• Preshoot
• Low Ref Volts
• Mid Ref Volts
• High Ref Volts
• Fall Time
• Positive Duty Cycle
• Falling Slew Rate
• Rise Time
• Negative Width
• Rising Slew Rate
• Positive Width
• Negative Duty Cycle
• Phase Delay
• Time Delay
• Average Frequency
• FFT Frequency
• Average Period
• Frequency
• Period
• Time Hist Hits
• Time Hist Mean + 3 Stdev
• Time Hist Max
• Time Hist Median
• Time Hist Mean
• Time Hist Min
• Time Hist Peak to Peak
• Time Hist Mode
• Time Hist Mean + Stdev
• Time Hist New Hits
• Time Hist Mean + 2 Stdev
• Time Hist Stdev
• Volt Hist Hits
• Volt Hist Median
• Volt Hist Max
• Volt Hist Min
• Volt Hist Mean
• Volt Hist Mode
• Volt Hist Mean + Stdev
• Volt Hist New Hits
• Volt Hist Mean + 2 Stdev
• Volt Hist Peak to Peak
• Volt Hist Mean + 3 Stdev
• Volt Hist Stdev
AC Estimate
260 ni.com
NI-SCOPE
The DC estimate is subtracted from the waveform, and a Hanning window is applied to
give a processed waveform. The RMS voltage is calculated with the following equation:
where the equivalent noise bandwidth (enbw) for the Hanning window is 1.5, and the
coherent gain (cg) is 0.5.
This algorithm minimizes the effect of an uneven number of waveform cycles in the
measurement, which could arbitrarily increase or decrease the RMS value.
Units
Volts RMS
pointsPerPeriod = period / dt
where period is the measured period of the signal and dt is the time between two
points. The result will then be converted to an integer from a floating point value.
Units
Volts RMS
Related concepts:
• Period
pointsPerPeriod = period / dt
where period is the measured period of the signal and dt is the time between two
points. The result will then be converted to an integer from a floating point value.
Related concepts:
• Period
FFT Amplitude
The FFT amplitude spectrum is calculated using a split-radix real FFT, and the
maximum amplitude is returned. If the input waveform size is not a power of two, the
waveform is zero-padded to the next higher power of two. For best results, verify that
your actual record length is a power of 2.
Units
Volts RMS
Voltage RMS
262 ni.com
NI-SCOPE
Units
Volts RMS
Voltage Average
Units
Volts
DC Estimate
A Hanning window is applied to give a "processed waveform" and the voltage average
is calculated with the following equation:
where the coherent gain (cg) of the Hanning window is 0.5 – the DC gain of the
window.
The algorithm minimizes the effect of an uneven number of waveform cycles. For
example, performing a simple voltage average on 5.5 cycles of a sine waveform gives a
slightly incorrect DC estimate if the extra half cycle is not evenly divided between the
positive and negative portions of the sine wave.
Units
Volts
Area
Units
Volts × Seconds
Related concepts:
• Voltage Average
Integral
Units
Volts × seconds
Cycle Area
Units
Volts × Seconds
Related concepts:
264 ni.com
NI-SCOPE
Voltage Min
Voltage Low
The last acquisition histogram method is used where the voltage low result is the
voltage of the histogram bin with the maximum number of hits below 40% of the
waveform's voltage peak-to-peak value. This calculation is useful for ignoring the
overshoot and preshoot on square waves.
Units
Volts
Voltage Max
Units
Volts
Voltage High
The last-acquisition histogram method is used, where the voltage high result is the
voltage of the histogram bin with the maximum number of hits above 60% of the
waveform's voltage peak-to-peak value. This calculation is useful for ignoring the
overshoot and preshoot on square waves.
Units
Volts
Voltage Amplitude
Units
Volts
Related concepts:
• Voltage High
• Voltage Low
Related concepts:
• Voltage Max
• Voltage Min
Voltage Base
266 ni.com
NI-SCOPE
If the histogram bin corresponding to voltage low has over five percent of the total hits,
the voltage low result is returned. Otherwise, the voltage minimum calculation is
returned. This allows using the voltage base to get a reasonable answer for either a
square wave (ignoring the overshoot and preshoot) or a triangle wave (where a
histogram fails).
Units
Volts
Related concepts:
• Voltage Low
• Voltage Min
Voltage Top
If the histogram bin corresponding to voltage high has over five percent of the total
hits, the voltage high result is returned. Otherwise, the voltage maximum calculation is
returned. This allows using the voltage top to get a reasonable answer for either a
square wave (ignoring the overshoot and preshoot) or a triangle wave (where a
histogram fails).
Units
Volts
Related concepts:
• Voltage High
• Voltage Max
Units
Volts
Related concepts:
• Voltage Top
• Voltage Base
Overshoot
The measurement is taken on the first edge of the waveform. If two edges exist, the
algorithm finds the time interval from the first edge until one half the time to the
second edge. The local maxima and minima are found in this interval. If only one edge
is present in the waveform, the local maximum and minimum is found between the
first edge and the end of the waveform.
If the first edge is positive sloped, overshoot = 100 × (local maximum - voltage high) /
voltage amplitude.
If the first edge is negative sloped, overshoot = 100 × (voltage low - local minimum) /
voltage amplitude.
268 ni.com
NI-SCOPE
Local Maximum
Voltage High
High Reference Level
Time Interval
Searched for
Max (T E/2)
Units
Percentage
Related concepts:
• Voltage High
• Voltage Amplitude
• Voltage Low
Preshoot
The measurement is taken on the second edge of the waveform if two edges exist. The
algorithm finds the time interval from the middle time between the two edges until
the second edge. The local maxima and minima are found in this interval. If only one
edge is present in the waveform, the local maximum and minimum are found from the
start of the waveform to the first edge.
If the edge is negative sloped, preshoot = 100 × (local maximum – voltage high) /
voltage amplitude.
If the edge is positive sloped, preshoot = 100 × (voltage low – local minimum) / voltage
amplitude.
Units
Percentage
Details
Local Maximum
Voltage High
High Reference Level
Time Interval
Searched for
Max (T E/2)
Related concepts:
• Voltage High
• Voltage Amplitude
• Voltage Low
The voltage corresponding to the low reference level. If the Reference Level Units
270 ni.com
NI-SCOPE
Units
Volts
The voltage corresponding to the mid reference level. If the Reference Level Units
property or the NISCOPE_ATTR_MEAS_REF_LEVEL_UNITS attribute is set to Voltage,
the value of the Channel Based Mid Ref property or the
NISCOPE_ATTR_MEAS_CHAN_MID_REF_LEVEL attribute is returned.
Units
Volts
The voltage corresponding to the high reference level. If the Reference Level Units
property or the NISCOPE_ATTR_MEAS_REF_LEVEL_UNITS attribute is set to Voltage,
Units
Volts
Fall Time
The time span in seconds from when the waveform crosses the high reference level
until it crosses the low reference level. The measurement starts at the left edge of the
waveform and finds all high reference level crossings until a low reference level
crossing. The final high reference level crossing is used in the calculation.
The reference levels are specified by Channel Based Low Ref and Channel Based High
Ref, and their default values are 10% and 90%.
Rise Fall
Time Time
272 ni.com
NI-SCOPE
Units
Seconds
Units
Percentage
Related concepts:
• Positive Width
• Period
The low reference voltage minus the high reference voltage is divided by the fall-time
calculation. The result is always negative.
Units
Volts/second
Related concepts:
Rise Time
The time span in seconds from when the waveform crosses the low reference level
until it crosses the high reference level. The measurement starts at the left edge of the
waveform and finds all low reference level crossings until a high reference level
crossing. The final low reference level crossing is used in the calculation.
The reference levels are specified by Channel Based Low Ref and Channel Based High
Ref, and their default values are 10% and 90%.
Rise Fall
Time Time
Units
Seconds
Negative Width
The time difference between the first two mid reference level crossings, where the
slopes are negative and positive, respectively. A digital hysteresis is used when finding
the crosspoints.
274 ni.com
NI-SCOPE
Units
Seconds
The high reference voltage minus the low reference voltage is divided by the rise-time
calculation.
Units
Volts/second
Related concepts:
Positive Width
The time difference in seconds between the first two mid reference level crossings,
where the slopes are positive and negative respectively. A digital hysteresis is used
when finding the crosspoints.
Units
Seconds
Units
Percentage
Related concepts:
• Negative Width
• Period
Phase Delay
The time delay divided by the period (of the waveform on the channel specified by the
measurement VI or function) times 360 degrees.
Units
Degrees
Related concepts:
• Time Delay
Time Delay
The time between a rising or falling edge on one channel and the subsequent edge, by
default of the same type, on a second channel.
1. Finds the first time that the waveform from the channel specified by the channels
parameter crosses its mid-reference level.
276 ni.com
NI-SCOPE
2. Finds the first two times that the waveform from the channel the Other Channel
property or the NISCOPE_ATTR_MEAS_OTHER_CHANNEL attribute crosses its mid-
reference level.
3. By default, measures the time delay across channels as rising edge to rising edge
or falling edge to falling edge, depending on which edge type the algorithm first
detects on the first channel.
Tip You can invert the data from either or both channels by adding a
processing step and using the array measurement gain with a value of -1.
With this method, you can also measure from rising edge to falling edge or
from falling edge to rising edge by inverting a signal on only one of the two
channels.
Units
Seconds
Average Frequency
Units
hertz
Related concepts:
• Average Period
FFT Frequency
The FFT amplitude spectrum is calculated using a split-radix real FFT, and the
frequency corresponding to the maximum amplitude is returned. If the input
waveform size is not a power of two, the waveform is zero padded to the next higher
power of two. The frequency resolution is sampling rate / number of points.
The DC bin of the FFT is ignored when searching for the maximum amplitude, so the
FFT frequency should ignore any DC offsets. However, the zero padding used in the
FFT measurement can introduce other low frequency components if the waveform has
a large DC offset. To avoid problems, make sure the Horizontal Actual Record Length
property or the NISCOPE_ATTR_HORZ_RECORD_LENGTH attribute is a power of 2, so
no zero padding occurs. This property/attribute can be fetched using the niScope
Actual Record Length VI or the niScope_ActualRecordLength function. Alternatively,
configuring the digitizer for AC coupling solves the problem.
Units
hertz
Average Period
Up to 256 mid reference level crossings are found on the waveform, using a digital
hysteresis. The time difference between the last crossing and the first crossing is
divided by the number of periods found in the waveform. The last crossing is defined
as the last crossing in the waveform with the same slope as the first crossing, so an
integer number of periods exist in the waveform.
Units
Seconds
Frequency
278 ni.com
NI-SCOPE
Related concepts:
• Period
Period
Finds the time in seconds between the first and third mid reference level crosspoints. A
hysteresis window is applied when finding crosspoints. The mid reference level is 50%
by default and is set with Channel Based Mid Ref Level.
Units
Seconds
Units
Seconds
The bin value is the center time value of the histogram bin.
Units
Seconds
Related concepts:
The percentage of hits in the histogram between mean minus the standard deviation
and mean plus the standard deviation. The percentage is returned in the range 0–100.
Units
Percentage
The percentage of hits in the histogram between the mean minus two times the
standard deviation and the mean plus two times the standard deviation. The
percentage is returned in the range 0—100.
Units
Percentage
280 ni.com
NI-SCOPE
The percentage of hits in the histogram between the mean minus three times the
standard deviation and the mean plus three times the standard deviation. The
percentage is returned in the range 0—100.
Units
Percentage
The bin value where half the histogram hits are above it and half the histogram hits are
below.
Units
Seconds
Units
Seconds
The bin value with the most hits. If there is a tie, the lower voltage or time value is
returned.
Units
Seconds
Units
Seconds
Units
Seconds
282 ni.com
NI-SCOPE
Units
Volts
The bin value is the center voltage value of the histogram bin.
Units
Volts
Related concepts:
The percentage of hits in the histogram between mean minus the standard deviation
and mean plus the standard deviation. The percentage is returned in the range 0–100.
Units
Percentage
The percentage of hits in the histogram between the mean minus two times the
standard deviation and the mean plus two times the standard deviation. The
percentage is returned in the range 0–100.
Units
Percentage
The percentage of hits in the histogram between the mean minus three times the
standard deviation and the mean plus three times the standard deviation. The
percentage is returned in the range 0–100.
Units
Percentage
The bin value where half the histogram hits are above it and half the histogram hits are
below.
284 ni.com
NI-SCOPE
Units
Volts
Units
Volts
The bin value with the most hits. If there is a tie, the lower voltage or time value is
returned.
Units
Volts
Units
Volts
Units
Volts
Before you begin using NI-SCOPE instrument driver FPGA extensions, you must install
NI-SCOPE and LabVIEW. You must also download a precompiled bitfile to use NI-
SCOPE instrument driver FPGA extensions. Visit ni.com/info and enter ex6h8h as
the Info Code, then select your hardware, and browse the download page to download
a NI-SCOPE FPGA extensions precompiled FPGA bitfile.
The precompiled bitfiles are included in examples that illustrate how to use the
precompiled bitfiles. These examples contain three parts: a precompiled bitfile
featuring application-specific IP, a host-based example that uses NI-SCOPE, and IP
286 ni.com
NI-SCOPE
dependencies, such as source code. These examples are distributed through the VI
Package Manager, which installs with LabVIEW.
When you install NI-SCOPE, model-specific folders for the supported devices are
created in the following location:
Related Topics
Visit ni.com/info and enter exkt9h as the Info Code to learn more about
instrument driver FPGA extensions.
Related concepts:
Before you begin using NI-SCOPE instrument driver FPGA extensions, you must install
NI-SCOPE and LabVIEW. When you install NI-SCOPE, model-specific folders for the
supported devices are created in the following location:
To use NI-SCOPE instrument driver FPGA extensions, you must specify the precompiled
bitfile you want to use when you initialize the instrument driver session. If you want to
access additional FPGA functionality provided by the precompiled bitfile, you must
also obtain an FPGA reference to use with the LabVIEW FPGA host interface.
Complete the following steps to open an instrument driver session that uses a
precompiled bitfile:
DriverSetup=Bitfile:filename.lvbitx
where filename.lvbitx is the file name of the bitfile you want to load.
Complete the following steps to obtain an FPGA reference to use with the LabVIEW
FPGA host interface:
1. Call the niScope FPGA Bitfile Path property. The FPGA Bitfile Path property returns
the absolute path to the bitfile as a string.
2. Wire the output of the FPGA Bitfile Path property to the String input of the String to
Path function.
3. Wire the Path output of the String to Path function to the Bitfile Path input of the
Open Dynamic Bitfile Reference function.
Visit ni.com/info and enter ex6h8h as the Info Code to download precompiled NI-
SCOPE instrument driver FPGA extensions bitfiles.
Visit ni.com/info and enter exkt9h as the Info Code to learn more about
instrument driver FPGA extensions.
288 ni.com
NI-SCOPE
You can use the NI-TClk API to synchronize the action of multiple instruments. Manual
adjustment tunes the sample clocks and triggers of instruments that have been
synchronized using NI-TClk, which enables better alignment than you can achieve
using NI-TClk synchronization alone.
Refer to the specifications for your instrument for the synchronization specifications
you can expect using NI-TClk with or without manual adjustment.
Note Note Manual adjustment can minimize skew only between multiple
instruments, not between multiple channels of the same physical
instrument. Mulitple channels of the same physical instrument are always
synchronized.
measurements.
Tip Tip The lower the skew and jitter of your reference signal, the better
the synchronization you can achieve between instruments using manual
adjustment.
Complete the following steps to perform manual adjustment for your oscilloscopes.
Set Up
Tip Tip For best results, use cables of the same model and of identical
length for each connection.
Calculate Adjustment
290 ni.com
NI-SCOPE
1. Fetch data from the instruments and measure the skew and jitter between the
waveforms each instrument is acquiring, for example, by performing a point-by-
point average.
2. Use any of the adjustment techniques applicable to your instrument to reduce the
skew and jitter you measured:
Adjustment
Instrument Description When to Use
Technique
◦ PXIe/PXI/
PCI-5105
◦ Adjustment
◦ PXIe/PXI/
range: ±1 Sample
PCI-5114
Clock Period
◦ PXIe/PXI/
Offsets the ◦ Adjustment unit:
PCI-5122
sample clock seconds
◦ PXI/ NI-SCOPE
from the Primary technique
PCI-5124 Adjust
◦ PXI/ Sample
reference clock by Tip Tip for reducing skew
the specified You can and jitter for
PCI-5142 Clock
amount. call this
◦ PXI/ Relative supported
function
PCI-5152 Delay
Reduces skew instruments.1
multiple
◦ PXI/ function
between times to
PCI-5153
instruments. implement
◦ PXI/
cumulative
PCI-5154
delay.
◦ PXIe-5622
◦ PXI/
PCI-5922
Offsets the
sample clock
◦ PXIe-5110 from the
◦ PXIe-5111 NI-SCOPE reference clock by ◦ Adjustment
Primary technique
◦ PXIe-5113 Absolute the specified range: ±0.5
for reducing skew
◦ PXIe-5163 Sample amount. Sample Clock
and jitter for
◦ PXIe-5164 Clock Period
supported
◦ PXIe-5170 Offset Reduces skew ◦ Adjustment unit:
instruments.
◦ PXIe-5171 property between seconds
◦ PXIe-5172 instruments and
improves
synchronization
Adjustment
Instrument Description When to Use
Technique
repeatability.
To apply offset
All oscilloscopes when adjustment
that support NI- Offsets the sample clock of an NI-TClk beyond the range
TClk session relative to the other synchronized of other
NI-TClk
synchronization Sample NI-TClk sessions. techniques is
except the needed.
Clock Delay
following: Reduces skew between instruments.
property
Sole technique for
◦ Adjustment range: ±∞ reducing skew for
◦ PXIe-51852
◦ Adjustment unit: seconds the PXIe-5160 and
◦ PXIe-51862 PXIe-5162.
3. Repeat steps 4 and 5 until the measured skew and/or jitter are as low as possible.
Apply Adjustment
1. Depending on your adjustment technique(s) from step 5, save the adjustment you
used to minimize skew and/or jitter.
Adjustment
Description
Technique
The NI-SCOPE Oscillator Phase DAC Value property converts the time offset you
applied with NI-SCOPE Adjust Sample Clock Relative Delay into a value that can
apply the manual adjustment across sessions and improve synchronization
NI-SCOPE
repeatability.
Adjust
Sample Clock a. Add the NI-SCOPE Oscillator Phase DAC Value property to your program
Relative and read its value.
Delay b. Save the Oscillator Phase DAC Value you read.
292 ni.com
NI-SCOPE
Adjustment
Description
Technique
All other
adjustment Save the value of each property.
techniques
2. Write the saved value(s) of the property or properties you used prior to calling the
NI-TClk Synchronize function in other sessions when using the test system in an
identical physical configuration. Writing the manual adjustment property or
properties to a session applies the improved synchronization to the session,
regardless of the signals the test system is acquiring.
1
Must be used in conjunction with the NI-SCOPE Oscillator Phase DAC Value property.
2
PXIe-5185 and PXIe-5186 only: These oscilloscopes have limited support for manual
adjustment. To calculate an adjustment for these oscilloscopes, you must set the NI-
SCOPE Oscillator Phase DAC Value property and determine the effect it has on
measured skew and jitter experimentally.
This is the sole technique for reducing skew and jitter for the PXIe-5185 and PXIe-5186.
Related concepts: