MATLAB Input Variables
When FlexDCA starts a user-measurement script, FlexDCA pushes a number of variables into the MATLAB workspace, including the source waveform. Any variables that you defined with the <Variable> XML element are also pushed into the workspace.
If your script uses a two-waveform input measurement, the input variables shown in this table will have a "2" character appended to the variable's name to distinguish the variable from each waveform. For example, SrcData becomes SrcData2 for the second waveform. The only exceptions are the except MeasData and SoftwareVersion variables.
Dictionary keys | Type | Description | FlexDCA Modes | ||
---|---|---|---|---|---|
Scope | TDR | Eye | |||
SrcData | numpy.ndarray | The input waveform in Oscilloscope and TDR/TDT mode where the waveform consists of y-data values. Values are in volts for electrical signals and Watts for optical signals. | ♦ | ♦ | |
The input waveform in Eye/Mask mode is a database where the waveform consists of hits-per-pixel arranged in a two-dimensional array ([column][row]). The column index represents increasing time values starting from the waveform's displayed left side to its right side. The row index represents increasing amplitude values that are in volts for electrical signals and Watts for optical signals. | ♦ | ||||
Example variable and value: 'SrcData': array([[0,0,0,…,0,0], [0,0,0,…,0,0], [0,0,0,…,0,0], … [0,0,0,…,0,0], [0,0,0,…,0,0]], dtype=uint32) |
|||||
Source | string | The source of the input waveform. Example variable and value: 'Source': 'Channel 1B' | ♦ | ♦ | ♦ |
SourceBw | float | The bandwidth of the input source. Example variable and value: 'SourceBw': 150000000000.0 | ♦ | ♦ | ♦ |
TotalHits | long | The number of hits in eye database. The value is an unsigned long integer in Python 2. Example variable and value: 'TotalHits': 2809395L | ♦ | ||
XOrg | float | The time of the first x-axis value of the input waveform value of SrcData. Example variable and value: 'XOrg': 8.785e-11 | ♦ | ♦ | ♦ |
XInc | float | The spacing of the x-axis input waveform values of SrcData. Example variable and value: 'XInc': 2.232e-13 | ♦ | ♦ | ♦ |
XUnits | string | The X units associated with the input waveform. Example variable and value: 'XUnits': 'Second' | ♦ | ♦ | ♦ |
YOrg | float | The time of the first y-axis value of SrcData. Example variable and value: 'YOrg': -0.42711 | ♦ | ||
YInc | float | The spacing of the y-axis values of SrcData. Example variable and value: 'YInc': 0.0016430 | ♦ | ||
YUnits | string | The Y units associated with the input waveform. Example variable and value: 'YUnits': 'Volt' | ♦ | ♦ | ♦ |
BitRate | float | FlexDCA A.05.61 and below. Deprecated in FlexDCA A.05.62 and above. Use the recommended SymbolRate variable instead.
The current value of the 'Data Rate' control in the pattern lock tab of the trigger setup dialog. If pattern lock is not turned on, this value may not be correct. Example variable and value: 'BitRate': 9953280000.0 |
♦ | ♦ | ♦ |
SymbolRate | float | Available FlexDCA A.05.62 and above.
The current value of the 'Symbol Rate' control in the pattern lock tab of the trigger setup dialog. If pattern lock is not turned on, this value may not be correct. Example variable and value: 'SymbolRate': 9953280000.0 |
♦ | ♦ | ♦ |
PatLength | integer | The current value of the 'Pattern Length' control in the pattern lock tap of the trigger setup dialog. If pattern lock is not turned on, this value may not be correct. Example variable and value: 'PatLength': 127 | ♦ | ♦ | ♦ |
SrcClipped | bolean | Set to True if the source data was clipped high or low; otherwise set to False. Example variable and value: 'SrcClipped': True | ♦ | ♦ | |
ClipHigh | float | The maximum value that could be present in the source waveform. If SrcClipped is True, check to see which elements of SrcData are equal to ClipHigh to determine which elements were clipped. Example key: value pair: 'ClipHigh': 0.51057 |
♦ | ♦ | |
ClipLow | float | The minimum value that could be present in the source waveform. If SrcClipped is True, check to see which elements of SrcData are equal to ClipLow to determine which elements were clipped. Example variable and value: 'ClipLow': -0.510869 | ♦ | ♦ | |
IsAvgComplete | bolean | Flag tells if waveform averaging is complete. Set to True if complete, otherwise False if not complete. Example variable and value: 'IsAvgComplete': True | ♦ | ♦ | |
IsPeriodic | bolean | Flag tells if waveform is periodic. Set to True if complete, otherwise False if not complete. Example variable and value: 'IsPeriodic': False | ♦ | ♦ | |
AvgAcqCount | long | The current value of the 'Number of Averages' control in the Averaging tab of the Acquistion dialog if averaging is enabled, otherwise its value is 1. The value is an unsigned long integer in Python 2. Example variable and value: 'AvgAcqCount': 1L | ♦ | ♦ | |
Markers | list of dictionaries | Marker information if markers are on source waveform. If a marker is not on, it is not included in the list. | ♦ | ♦ | ♦ |
TdrAmplitude | float | The current amplitude of the TDR waveform. | ♦ | ||
TdrPolarity | string | The current polarity of the TDR waveform. | ♦ | ||
TdrRiseTime | float | The current rise time of the TDR waveform. | ♦ | ||
DielectricConstant | float | The dielectric constant of the TDR waveform. (If horizontal units are defined in distance instead of time.) | ♦ | ||
VelocityFactor | float | The velocity factor of the TDR waveform.(If horizontal units are defined in distance instead of time.) | ♦ | ||
MeasData | list of dictionaries | Contains name, status, channel, result, and units for each input measurement. | ♦ | ♦ | ♦ |
SoftwareVersion | string | The FlexDCA software version that is being run. | ♦ | ♦ | ♦ |
MeasData Variable's Array
As shown in the table above, the MeasData
variable is an array of measurement result structures from built-in measurements. Measurements that are turned on will be pushed into the MATLAB workspace. Each structure contains:
- Name: Measurement name as a string.
- Result: Floating point value of measurement.
- Status: Result status as a string ('Correct', 'Questionable', or 'Invalid').
- Units: Result units as a string.
- Source1: Input measurement source1 as a string.
- Source2: Input measurement source2 as a string.
The following tables show example measurement strings for a measurement Name. You can use the Name to:
- Discover structure for a measurement.
- Learn the status of the measurement result by selecting
'Status'
. - Get the found dictionary's measurement result by selecting
'Result'
key.
The measurement name matches the name shown in FlexDCA's Results panel except in cases where a Unicode character is included. Unicode characters are included in the Δ Time, DI (δ-δ), and DJ (δ-δ) measurement names. Also, names that have time or amplitude values in them may contain the μ symbol. For example, Scope mode's Time at Amplitude measurement name could be Time[+2,900 μV]
depending on the settings made at the time that the measurement was started in FlexDCA.
Markers Variable's Array
The Markers
variable is an array of waveform marker structures. Markers that are turned on will be pushed into the MATLAB workspace. For example,
- Status: Marker status as a string ('Correct', 'Questionable', or 'Invalid').
- Source: 'Channel 1B'.
- Name: 'X1'.
- Position: 1.28445e-10.
To confirm a measurement name, see how the name is shown in FlexDCA's Results panel.
In the following tables, blue colored name string text shown in brackets [text] and parenthesis (text) indicate measurement options.
Time Toolbar Measurements | Amplitude Toolbar Measurements | PAM Toolbar Measurements | |||||
---|---|---|---|---|---|---|---|
On Toolbar | meas['Name'] Key Value Examples |
On Toolbar | meas['Name'] Key Value Examples |
On Toolbar | meas['Name'] Key Value Examples |
||
Rise Time | Rise Time
|
Overshoot | Overshoot
|
Linearity | RLM (802.3 CL_94)
|
||
Fall Time | Fall Time
|
Average Power | Avg[Disp]
|
Levels | Level 3
|
||
Jitter | Jitter[rms]
|
OMA | OMA
|
Levels RMS | Level 3 RMS
|
||
Period | Period
|
Amplitude | Amplitude
|
||||
Δ Time | ΔT[+1Up,-2Lo]
|
Peak-Peak Amplitude | Peak-Peak(1.0E-2)
|
||||
Frequency | Frequency
|
RMS | RMS[AC,Disp]
|
||||
+ Pulse Width | + Pulse
|
Average | Average Power
|
||||
- Pulse Width | - Pulse
|
Waveform Top | Top
|
||||
Duty Cycle | Duty Cycle
|
Waveform Base | Base
|
||||
Time at Max | Time at Max
|
Maximum | Maximum
|
||||
Time at Min | Time at Min
|
Minimum | Minimum
|
||||
Time at Edge | Time[+1Mid]
|
Preshoot | Preshoot
|
||||
Time at Amplitude | Time[+1,0 W] Time[-2,1.80 mV] Time[+2,900 μV] |
Amplitude at Time | Ampl[16.10000 ns]
|
||||
Phase | Phase[+]
|
Amplitude at Upper | Ampl at Upper
|
||||
Amplitude at Middle | Ampl at Middle
|
||||||
Amplitude at Lower | Ampl at Lower
|
||||||
Peak-Peak at Hit Ratio | Peak-Peak
|
Blue text describes measurement options which are selected when a measurement is run. Multiple instances of a measurement can be run each having different options. Refer to the Results panel for the exact name.
Time Toolbar Measurements | Adv Eye Toolbar Measurements | PAM Toolbar Measurements | |||||
---|---|---|---|---|---|---|---|
On Toolbar | meas['Name'] Key Value Examples |
On Toolbar | meas['Name'] Key Value Examples |
On Toolbar | meas['Name'] Key Value Examples |
||
Extinction Ratio | Ext. Ratio
|
TJ
|
TJ (1.0E-12, RJ: 3fs)
|
TDECQ | TDECQ
|
||
TDEC | TDEC[OMA XP] | DJ (δ - δ) | DJ (δ - δ, RJ: 2fs)
|
Ceq Noise Gain | Ceq
|
||
Jitter | Jitter[rms]
|
RJ (rms) | RJ (rms, fixed)
|
Trans. Time | Trans. Time (Slowest; 5,6)
|
||
OMA at Crossing | OMA XP
|
Jn | J2 0/1 (RJ: 1fs)
|
Outer OMA | Outer OMA
|
||
VECP | VECP[OMA XP]
|
TI | TI 3 (1.0E-12, RN: μW)
|
PAM Overshoot | Overshoot(1.0E-2)
|
||
Average Power | Average Power
|
DI (δ - δ) | DI 3 (δ - δ, RN: μV)
|
PAM Undershoot | Undershoot(1.0E-2)
|
||
Rise Time | Rise Time
|
RN (rms) | RN (rms, fixed)
|
Outer Extinction Ratio | Outer ER
|
||
Fall Time | Fall Time
|
Linearity | RLM (802.3 CL_94)
|
||||
One Level | One Level
|
Noise Margin (rms) | Noise Margin (rms)
|
||||
Zero Level | Zero Level
|
Pk-Pk Amplitude | Pk-Pk Power(1.0E-2)
|
||||
Eye Height | Eye Height[Ampl]
|
Tx Power Excursion | Power Excursion(1.0E-2)
|
||||
Eye Width | Eye Width[Time]
|
Partial SER | Partial SER (2/3 L)
|
||||
Crossing % | Crossing %
|
Partial TDECQ | Partial TDECQ (2/3 L)
|
||||
Signal to Noise Ratio | SNR
|
Partial Noise Margin | Noise Margin (2/3 L)
|
||||
Duty Cycle Distortion | DCD[Time] | Levels | Level 3
|
||||
Bit Rate | Bit Rate
|
Levels RMS | Level 2 RMS
|
||||
Eye Amplitude | Eye Ampl
|
Levels Peak-Peak | Level 3 Peak-Peak
|
||||
Δ Time | Δ Time
|
Level Skews | Level 2 Skew
|
||||
Crossing Time | Crossing Time
|
Eye Levels | Eye 1/2 Level
|
||||
Database Peak Hits | Database Peak Hits
|
Eye Skews | Eye 2/3 Skew
|
||||
Vertical Eye Closure | Eye 0/1 VEC
|
||||||
Eye Heights | Eye 1/2 Height
|
||||||
Eye Widths | Eye 2/3 Width
|
Blue text describes measurement options which are selected when a measurement is run. Multiple instances of a measurement can be run each having different options. Refer to the Results panel for the exact name.
Time Toolbar Measurements | Amplitude Toolbar Measurements | |||
---|---|---|---|---|
On Toolbar | meas['Name'] Key Value Examples |
On Toolbar | meas['Name'] Key Value Examples |
|
Rise Time | Rise Time
|
Average | Avg[Disp]
|
|
Fall Time | Fall Time
|
Maximum | Maximum
|
|
Delta Time | Δ Time
|
Minimum | Minimum
|
|
Time at Max | Time at Max
|
Amplitude at Time | Ampl[1.60200 ns]
|
|
Time at Min | Time at Min
|
Excess Capacitance | Excess C[Left]
|
|
Time at Amplitude | Time[+1,0 V]
|
Excess Inductance | Excess L[Left]
|
|
Time at Edge | Time[+1Mid]
|
Blue text describes measurement options which are selected when a measurement is run. Multiple instances of a measurement can be run each having different options. Refer to the Results panel for the exact name.