EasyManuals Logo
Home>Tektronix>Test Equipment>DPO5000 Series

Tektronix DPO5000 Series User Manual

Tektronix DPO5000 Series
1002 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #774 background imageLoading...
Page #774 background image
Oscilloscope Reference Writing math plugins
argument specied in the equation does not match the type expected by the plugin (for example, a string
was expected but a FastFrame waveform was supplied).
Writingmathplugins
You can write plugins in any .NET language. The following examples use C#. When writing a plugin,
reference the ScopeSupportBase.dll and TekScriptin gEngine.dll system assemblies. Additionally, tag all
plugins with the C# a ttribute [Math] if they are to be loaded into the system.
Six different classes are used inside plugins: INormalizedVec t or, IFastFrame, IWaveformDB, IString,
ISettings and IRange. The rst two, INormalizedVec tor and IFastFrame, are waveform vector types used
by the instrument. The third, IWaveformDB is a pixmap waveform. IStrings, ISettings and IRange are
used to pass additional information into a plugin.
Waveform types
All waveform classes contain a member called SourceName. T his is a string that contains the symbol
name of the waveform source. If the source is a channel, math or reference waveform, the SourceName
will be Ch<x>, Math<n> or Ref<n>, respectively. If the wa veform is an intermediate, the SourceName
will be Intermediate0, if it is the output waveform or Intermediate<n> if it’s an input vector, where <n>
corresponds to which argument it is. Examples of intermediates are:
Math1=MyAdd(Ch1, Ch2)*Ch3: The output of MyAdd is an intermediate because it still needs to
be multiplied by Ch3 before being put into Math1. The
SourceName for the output waveform will
be Intermediate0.
Math1=MyAdd(Ch1*Ch2, Ch3): The rst input is an intermediate because two channels are being
multiplied together. Its SourceName will be Intermediate1.
Math1=MyAdd(Ch1, Ch2/Ch3): The second input is an intermediate because two channels are being
divided. Its SourceName will be Intermediate2.
INormalizedVe ctor is the basic waveform type used by TekScope. The length of the vector is found in the
Count member of the class. Array indices are used to access values inside the vector:
INormalizedVe ctor output;
INormalizedVe ctor input1;
for(longi=0;i<
input1.Count; i++)
output[i] = input1[i];
IFastFrame is built on top of INormalizedVector. An IFastFrame is a grouping of INormalizedVectors.
IFastFrames are generated when FastFrame is enabled on the instrument. The number of frames is stored
in the member called FrameCount. You can iterate through the frames by setting the CurrentFrame (note:
frames are 1 counted so you should iterate from 1 to FrameCount). Once you set the CurrentFrame, y
ou
use the IFastFrame the same as an INormalizedVector.
IFastFrame output;
IFastFrame input1;
IFastFrame input2;
for (long f = 1; f <= output.FrameCount; f++)
752 DSA/DPO70000D, MSO/DPO/DSA70000C, DPO7000C, and MSO/DPO5000 Series

Table of Contents

Other manuals for Tektronix DPO5000 Series

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Tektronix DPO5000 Series and is the answer not in the manual?

Tektronix DPO5000 Series Specifications

General IconGeneral
BrandTektronix
ModelDPO5000 Series
CategoryTest Equipment
LanguageEnglish

Related product manuals