Code covered by the BSD License
-
demoselector(varargin)
DEMOSELECTOR Application M-file for demoselector.fig
-
example_sel(varargin)
EXAMPLE_SEL Application M-file for example_sel.fig
-
getscopedata_gui(varargin)
GETSCOPEDATA_GUI Application M-file for getscopedata_gui.fig
-
valve_gui_batch(varargin)
VALVE_GUI_BATCH Integrated Measurement System Application
-
valve_gui_oc(varargin)
valve_gui_oc A GUI to control the throttle and view it's response
-
valve_gui_simple(varargin)
valve_gui_simple GUI to open, close, and relax the throttle
-
ConfigureTrigger(ai,TriggerDe...
Configure trigger
-
CreateAI(filename,vendor,boar...
-
CreateDIO(vendor,boardid,chan...
CreateDIO Create and configure dio object for throttle demo
-
daqtriggerreshape(data);
daqtriggerreshape Reshape triggered daq data
-
datalabel(state,marker_color)...
datalabel Interactive labeling of data points on a plot
-
export(filename,time,position...
export Create an Excel spreadsheet from recorded time and position
-
figshift(scale)
%FIGSHIFT ...
-
fillscreen
%fillscreen ...
-
find_transition(position,time...
find_transition Find the transition points
-
findpeaks(y)
FINDPEAKS Find peaks in real vector.
-
highlight_curve(h,lh);
Input
-
hout=suptitle(str)
SUPTITLE Puts a title above all subplots.
-
linelabel(state,ind)
-
plotdata(ai);
-
show_data(h);
-
subplot_varspace(nrows, ncols...
subplot_varspace SUBPLOT, which lets you specify spacing between subplots
-
throttle_cfit(t,position,make...
THROTTLE_CFIT Create plot of datasets and fits
-
valvebatch_function(Nruns,fil...
Run a whole bunch of tests of the valve
-
xlswrite(filename,m,colnames)...
Write a simple, 2-column Excel file with column headers
-
analyze_plot.m
-
cfit_analysis.m
-
daq1.m
-
daq_session.m
-
datainsight_signal.m
-
instr1.m
-
instr_session.m
-
rpt_AlgorithmDesign.m
-
rpt_AppendixDetails.m
-
rpt_ProductionTest.m
-
throttle_simulation_init.m
-
throttle_simulation_stopfcn.m
-
throttle_simulation_stopfcn1r...
-
throttle_simulation_validate.m
-
valve_walkthrough.m
-
throttle_simulation
-
View all files
from
Test and Measurement Seminar Demos
by Scott Hirsch
Source code for Test and Measurement Seminar Demos, including electronic throttle body case study.
|
| figshift(scale)
%FIGSHIFT Shifts current figure window away from previous figure
% Places figure window slightly offset from previous figure
% window, to allow for easy switching between windows.
%
% Optional scalar argument SCALE sets how |
function figshift(scale)
%FIGSHIFT Shifts current figure window away from previous figure
% Places figure window slightly offset from previous figure
% window, to allow for easy switching between windows.
%
% Optional scalar argument SCALE sets how far figure is offset from previous
% figure, as a percent of previous figure dimensions (0<SCALE<100)
%
% Call FIGSHIFT after opening window
% Scott Hirsch
% Copyright 2002 - 2003 The MathWorks, Inc
if nargin==0
scale=.05; %Default, 5% of figure size
else
scale=scale*.01;
end;
%Get Current Figure Handle
CurrentHandle=gcf;
%FigUnits=get(CurrentHandle,'Units');
scnsize=get(0,'ScreenSize');
ScnWidth=scnsize(3);
ScnHeight=scnsize(4);
if gcf==1
str='Can''t shift first figure';
% disp(str)
break %Do nothing if this is the first figure window
else
PrevHandle=gcf-1;
PrevPosition=get(PrevHandle,'Position');
Units=get(PrevHandle,'Units');
FigWidth=PrevPosition(3);
FigHeight=PrevPosition(4);
NewPosition=PrevPosition;
NewPosition(1)=PrevPosition(1)+FigWidth*scale; %Shift Over
NewPosition(2)=PrevPosition(2)-FigHeight*scale; %Shift Down
%Check if the new position is off of the screen
%If it is, move figure to upper left corner of screen
if ((NewPosition(1)+FigWidth) > ScnWidth) | ((NewPosition(2)+FigHeight) > ScnHeight)
NewPosition(1)=0;
NewPosition(2)=ScnHeight*.95 - FigHeight;
end;
set(gcf,'Units',Units,'Position',NewPosition);
end;
|
|
Contact us at files@mathworks.com