No BSD License  

Highlights from
Data Visualization Application - Agilent EXA, MXA, and PSA Spectrum Analyzers

image thumbnail

Data Visualization Application - Agilent EXA, MXA, and PSA Spectrum Analyzers

by

 

28 Jan 2008 (Updated )

Data Visualization Software for the Agilent EXA, MXA, and PSA Signal and Spectrum Analyzers

ADV_Reset( handle )
function ADV_Reset( handle )
%ADV_INITPERSISTBUFFER Summary of this function goes here
%   Detailed explanation goes here

global g_ADVPersistBuffer
global g_ADVPersistAmplPoints
global g_ADVSlope
global g_ADVIntercept
global g_ADVXAxis
global g_ADVYAxis
global g_ADVTraceFIFO
global g_ADVTraceFIFOSize
global g_ADVTraceCount
global g_ADVDisplayMode

% Read a trace to get the number of points
data = MXA_AcquireData( handle );

% Initialize the FIFO
g_ADVTraceFIFO = zeros( size( data, 1 ), g_ADVTraceFIFOSize ) - 150;
g_ADVTraceCount = 0;

% Build the x- and y-axis vectors
g_ADVXAxis = MXA_GetXAxisArray( handle );
if g_ADVDisplayMode <= 1
    [yMin, yMax] = MXA_GetYScaling( handle );
    g_ADVYAxis = yMax:-(yMax - yMin) / (g_ADVPersistAmplPoints - 1):yMin;
else
    g_ADVYAxis = 1:g_ADVTraceFIFOSize;
end
    
% Create the persistence buffer initialized to zero
g_ADVPersistBuffer = zeros( g_ADVPersistAmplPoints, size( data, 1 ) );

% Get the scaling from the MXA
[yMin, yMax] = MXA_GetYScaling( handle );

% Calculate slope and intercept for determining data position in matrix
g_ADVSlope = (g_ADVPersistAmplPoints - 1) / (yMin - yMax);
g_ADVIntercept = g_ADVPersistAmplPoints - g_ADVSlope * yMin;

Contact us