0
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
1 % CB_DRAWCONTROLS draws the user controls depending on which signal type is
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
2 % selected.
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
3 %
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
4 % M Hewitson
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
5 %
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
6 % $Id: cb_drawControls.m,v 1.1 2008/10/19 11:42:40 hewitson Exp $
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
7 %
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
8
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
9 function cb_drawControls(varargin)
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
10
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
11 % Settings
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
12 hmarg = 0.01;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
13 vmarg = 0.02;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
14 commHeight = 0.08;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
15
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
16 % Get selected signal type
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
17 sigType = varargin{2};
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
18 % main figure
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
19 mainfig = varargin{1};
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
20 % Panel to draw on
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
21 pan = findobj(mainfig.handle, 'Tag', 'ControlsPanel');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
22
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
23 % Delete all children
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
24 delete(get(pan, 'Children'))
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
25 drawnow
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
26
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
27 % Draw the requested controls
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
28 switch lower(sigType)
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
29 case 'sine wave'
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
30 draw_Sine_Wave(pan,mainfig,commHeight,hmarg,vmarg);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
31 case 'white noise'
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
32 draw_WhiteNoise(pan,mainfig,commHeight,hmarg,vmarg);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
33 case 'chirp'
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
34 draw_Chirp(pan,mainfig,commHeight,hmarg,vmarg);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
35 case 'gaussian pulse'
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
36 draw_GaussPulse(pan,mainfig,commHeight,hmarg,vmarg);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
37 case 'square wave'
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
38 draw_SquareWave(pan,mainfig,commHeight,hmarg,vmarg);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
39 case 'sawtooth'
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
40 draw_Sawtooth(pan,mainfig,commHeight,hmarg,vmarg);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
41 case 'noise generator'
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
42 draw_NoiseGenerator(pan,mainfig,commHeight,hmarg,vmarg);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
43 case 'polynomial'
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
44 draw_Polynomial(pan,mainfig,commHeight,hmarg,vmarg);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
45 case 'custom'
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
46 draw_Custom(pan,mainfig,commHeight,hmarg,vmarg);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
47 otherwise
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
48 warning('!!! No controls for signal type: %s', sigType);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
49 end
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
50
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
51 end
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
52
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
53 %--------------------------------------------------------------------------
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
54 % Draw controls for a polynomial
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
55 %
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
56 function draw_Polynomial(pan,mainfig,commHeight,hmarg,vmarg)
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
57
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
58 Lwidth = 0.25;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
59 Ewidth = 0.65;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
60 h = commHeight;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
61
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
62 %--- Coeffs
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
63
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
64 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
65 b = 1-2*vmarg-h;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
66 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
67 'String', 'Coeffs',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
68 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
69 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
70 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
71 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
72 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
73
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
74 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
75 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
76 clsh = uicontrol(pan, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
77 'Style', 'edit', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
78 'Units', 'normalized',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
79 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
80 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
81 'String', '1', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
82 'Position', [l b Ewidth h],...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
83 'Tag', 'Poly_Coeffs', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
84 'Tooltip', 'Polynomial coefficients');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
85
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
86 % nsecs
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
87 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
88 b = b - h - 2*vmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
89 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
90 'String', 'Length [s]',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
91 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
92 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
93 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
94 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
95 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
96
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
97 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
98 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
99 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
100 'String', '1',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
101 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
102 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
103 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
104 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
105 'Tag', 'Poly_Length',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
106 'Tooltip', 'Length of signal in seconds');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
107
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
108
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
109 end
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
110
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
111 %--------------------------------------------------------------------------
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
112 % Draw controls for a custom f(t)
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
113 %
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
114 function draw_Custom(pan,mainfig,commHeight,hmarg,vmarg)
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
115
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
116 Lwidth = 0.25;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
117 Ewidth = 0.65;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
118 h = commHeight;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
119
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
120 %--- Fcn
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
121
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
122 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
123 b = 1-2*vmarg-h;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
124 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
125 'String', 'F(t)',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
126 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
127 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
128 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
129 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
130 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
131
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
132 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
133 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
134 clsh = uicontrol(pan, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
135 'Style', 'edit', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
136 'Units', 'normalized',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
137 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
138 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
139 'String', 't', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
140 'Position', [l b Ewidth h],...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
141 'Tag', 'Custom_Fcn', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
142 'Tooltip', 'A valid MATLAB function of the variable ''t''');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
143
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
144 % nsecs
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
145 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
146 b = b - h - 2*vmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
147 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
148 'String', 'Length [s]',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
149 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
150 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
151 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
152 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
153 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
154
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
155 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
156 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
157 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
158 'String', '1',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
159 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
160 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
161 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
162 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
163 'Tag', 'Custom_Length',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
164 'Tooltip', 'Length of signal in seconds');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
165
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
166
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
167 end
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
168
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
169 %--------------------------------------------------------------------------
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
170 % Draw controls for a noise generation
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
171 %
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
172 function draw_NoiseGenerator(pan,mainfig,commHeight,hmarg,vmarg)
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
173
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
174 Lwidth = 0.25;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
175 Ewidth = 0.65;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
176 h = commHeight;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
177
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
178 %--- Gains
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
179
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
180 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
181 b = 1-2*vmarg-h;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
182 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
183 'String', 'Gain',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
184 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
185 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
186 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
187 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
188 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
189
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
190 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
191 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
192 clsh = uicontrol(pan, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
193 'Style', 'edit', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
194 'Units', 'normalized',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
195 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
196 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
197 'String', '1', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
198 'Position', [l b Ewidth h],...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
199 'Tag', 'NoiseGen_Gain', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
200 'Tooltip', 'Overall Gain');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
201
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
202
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
203 % Poles
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
204 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
205 b = b - h - 2*vmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
206 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
207 'String', 'Poles',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
208 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
209 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
210 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
211 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
212 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
213
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
214 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
215 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
216 'String', '{1,1}',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
217 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
218 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
219 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
220 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
221 'Tag', 'NoiseGen_Poles',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
222 'Tooltip', 'Pole Frequencies (and Q''s). (help pzmodel)');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
223
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
224 % Poles
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
225 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
226 b = b - h - 2*vmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
227 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
228 'String', 'Zeros',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
229 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
230 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
231 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
232 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
233 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
234
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
235 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
236 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
237 'String', '10',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
238 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
239 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
240 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
241 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
242 'Tag', 'NoiseGen_Zeros',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
243 'Tooltip', 'Zero Frequencies (and Q''s). (help pzmodel)');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
244
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
245 % nsecs
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
246 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
247 b = b - h - 2*vmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
248 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
249 'String', 'Length [s]',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
250 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
251 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
252 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
253 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
254 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
255
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
256 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
257 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
258 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
259 'String', '1',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
260 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
261 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
262 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
263 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
264 'Tag', 'NoiseGen_Length',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
265 'Tooltip', 'Length of signal in seconds');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
266
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
267
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
268 end
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
269
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
270 %--------------------------------------------------------------------------
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
271 % Draw controls for a sawtooth
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
272 %
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
273 function draw_Sawtooth(pan,mainfig,commHeight,hmarg,vmarg)
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
274
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
275 Lwidth = 0.25;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
276 Ewidth = 0.65;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
277 h = commHeight;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
278
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
279 %--- F
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
280
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
281 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
282 b = 1-2*vmarg-h;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
283 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
284 'String', 'Frequency [Hz]',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
285 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
286 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
287 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
288 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
289 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
290
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
291 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
292 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
293 clsh = uicontrol(pan, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
294 'Style', 'edit', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
295 'Units', 'normalized',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
296 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
297 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
298 'String', '0', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
299 'Position', [l b Ewidth h],...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
300 'Tag', 'Sawtooth_F', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
301 'Tooltip', 'Frequency [Hz] (help sawtooth)');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
302
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
303
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
304 % Width
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
305 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
306 b = b - h - 2*vmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
307 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
308 'String', 'Width [0-1]',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
309 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
310 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
311 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
312 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
313 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
314
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
315 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
316 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
317 'String', '1',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
318 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
319 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
320 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
321 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
322 'Tag', 'Sawtooth_Width',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
323 'Tooltip', 'Width [0-1] (help sawtooth)');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
324
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
325 % nsecs
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
326 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
327 b = b - h - 2*vmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
328 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
329 'String', 'Length [s]',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
330 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
331 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
332 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
333 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
334 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
335
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
336 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
337 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
338 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
339 'String', '1',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
340 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
341 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
342 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
343 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
344 'Tag', 'Sawtooth_Length',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
345 'Tooltip', 'Length of signal in seconds');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
346
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
347
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
348 end
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
349
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
350 %--------------------------------------------------------------------------
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
351 % Draw controls for a square wave
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
352 %
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
353 function draw_SquareWave(pan,mainfig,commHeight,hmarg,vmarg)
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
354
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
355 Lwidth = 0.25;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
356 Ewidth = 0.65;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
357 h = commHeight;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
358
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
359 %--- F
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
360
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
361 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
362 b = 1-2*vmarg-h;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
363 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
364 'String', 'Frequency [Hz]',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
365 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
366 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
367 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
368 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
369 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
370
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
371 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
372 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
373 clsh = uicontrol(pan, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
374 'Style', 'edit', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
375 'Units', 'normalized',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
376 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
377 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
378 'String', '0', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
379 'Position', [l b Ewidth h],...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
380 'Tag', 'SquareWave_F', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
381 'Tooltip', 'Frequency [Hz]');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
382
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
383
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
384 % Duty
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
385 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
386 b = b - h - 2*vmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
387 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
388 'String', 'Duty Cycle [%]',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
389 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
390 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
391 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
392 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
393 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
394
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
395 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
396 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
397 'String', '1',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
398 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
399 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
400 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
401 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
402 'Tag', 'SquareWave_Duty',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
403 'Tooltip', 'Duty Cycle [%]');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
404
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
405 % nsecs
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
406 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
407 b = b - h - 2*vmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
408 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
409 'String', 'Length [s]',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
410 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
411 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
412 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
413 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
414 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
415
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
416 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
417 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
418 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
419 'String', '1',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
420 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
421 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
422 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
423 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
424 'Tag', 'SquareWave_Length',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
425 'Tooltip', 'Length of signal in seconds');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
426
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
427
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
428 end
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
429
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
430 %--------------------------------------------------------------------------
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
431 % Draw controls for a gaussian pulse
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
432 %
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
433 function draw_GaussPulse(pan,mainfig,commHeight,hmarg,vmarg)
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
434
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
435 Lwidth = 0.25;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
436 Ewidth = 0.65;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
437 h = commHeight;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
438
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
439 %--- F0
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
440
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
441 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
442 b = 1-2*vmarg-h;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
443 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
444 'String', 'F0 [Hz]',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
445 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
446 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
447 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
448 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
449 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
450
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
451 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
452 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
453 clsh = uicontrol(pan, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
454 'Style', 'edit', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
455 'Units', 'normalized',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
456 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
457 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
458 'String', '0', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
459 'Position', [l b Ewidth h],...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
460 'Tag', 'GPulse_F0', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
461 'Tooltip', 'Center Frequency [Hz]');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
462
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
463
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
464 % BW
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
465 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
466 b = b - h - 2*vmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
467 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
468 'String', 'BW',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
469 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
470 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
471 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
472 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
473 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
474
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
475 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
476 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
477 'String', '1',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
478 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
479 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
480 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
481 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
482 'Tag', 'GPulse_BW',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
483 'Tooltip', 'Fractional Bandwidth [Hz]');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
484
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
485 % nsecs
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
486 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
487 b = b - h - 2*vmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
488 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
489 'String', 'Length [s]',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
490 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
491 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
492 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
493 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
494 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
495
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
496 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
497 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
498 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
499 'String', '1',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
500 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
501 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
502 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
503 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
504 'Tag', 'GPulse_Length',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
505 'Tooltip', 'Length of signal in seconds');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
506
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
507
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
508 end
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
509
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
510 %--------------------------------------------------------------------------
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
511 % Draw controls for a chirp signal
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
512 %
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
513 function draw_Chirp(pan,mainfig,commHeight,hmarg,vmarg)
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
514
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
515 Lwidth = 0.25;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
516 Ewidth = 0.65;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
517 h = commHeight;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
518
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
519 %--- F0
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
520
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
521 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
522 b = 1-2*vmarg-h;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
523 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
524 'String', 'F0',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
525 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
526 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
527 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
528 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
529 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
530
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
531 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
532 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
533 clsh = uicontrol(pan, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
534 'Style', 'edit', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
535 'Units', 'normalized',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
536 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
537 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
538 'String', '0', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
539 'Position', [l b Ewidth h],...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
540 'Tag', 'Chirp_F0', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
541 'Tooltip', 'Instantaneous frequency at t=0');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
542
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
543
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
544 % F1
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
545 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
546 b = b - h - 2*vmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
547 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
548 'String', 'F1',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
549 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
550 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
551 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
552 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
553 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
554
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
555 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
556 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
557 'String', '1',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
558 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
559 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
560 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
561 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
562 'Tag', 'Chirp_F1', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
563 'Tooltip', 'Instantaneous freuqency at t=T1');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
564
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
565 % T1
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
566 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
567 b = b - h - 2*vmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
568 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
569 'String', 'T1',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
570 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
571 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
572 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
573 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
574 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
575
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
576 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
577 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
578 'String', '1',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
579 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
580 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
581 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
582 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
583 'Tag', 'Chirp_T1', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
584 'Tooltip', 'Time at which F1 is reached');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
585
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
586 % nsecs
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
587 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
588 b = b - h - 2*vmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
589 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
590 'String', 'Length [s]',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
591 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
592 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
593 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
594 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
595 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
596
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
597 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
598 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
599 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
600 'String', '1',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
601 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
602 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
603 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
604 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
605 'Tag', 'Chirp_Length',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
606 'Tooltip', 'Length of the signal in seconds');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
607
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
608
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
609 end
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
610
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
611 %--------------------------------------------------------------------------
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
612 % Draw controls for a white noise signal
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
613 %
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
614 function draw_WhiteNoise(pan,mainfig,commHeight,hmarg,vmarg)
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
615
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
616 Lwidth = 0.25;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
617 Ewidth = 0.65;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
618 h = commHeight;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
619 %--- Type
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
620
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
621 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
622 b = 1-2*vmarg-h;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
623 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
624 'String', 'Noise Type',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
625 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
626 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
627 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
628 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
629 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
630
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
631 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
632 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
633 clsh = uicontrol(pan, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
634 'Style', 'popupmenu', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
635 'Units', 'normalized',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
636 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
637 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
638 'String', {'Normal', 'Uniform'}, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
639 'Position', [l b Ewidth h],...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
640 'Tag', 'WhiteNoise_Type');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
641
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
642
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
643 % sigma
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
644 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
645 b = b - h - 2*vmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
646 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
647 'String', 'Sigma',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
648 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
649 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
650 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
651 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
652 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
653
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
654 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
655 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
656 'String', '1',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
657 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
658 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
659 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
660 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
661 'Tag', 'WhiteNoise_Sigma');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
662
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
663 % nsecs
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
664 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
665 b = b - h - 2*vmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
666 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
667 'String', 'Length [s]',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
668 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
669 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
670 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
671 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
672 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
673
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
674 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
675 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
676 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
677 'String', '1',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
678 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
679 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
680 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
681 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
682 'Tag', 'WhiteNoise_Length');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
683
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
684
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
685 end
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
686
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
687 %--------------------------------------------------------------------------
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
688 % Draw controls for a sine wave signal
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
689 %
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
690 function draw_Sine_Wave(pan,mainfig,commHeight,hmarg,vmarg)
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
691
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
692 Lwidth = 0.25;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
693 Ewidth = 0.65;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
694 h = commHeight;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
695 %--- Amplitudes
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
696 % label
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
697 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
698 b = 1-2*vmarg-h;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
699 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
700 'String', 'Amplitudes',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
701 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
702 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
703 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
704 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
705 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
706
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
707 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
708 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
709 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
710 'String', '1',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
711 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
712 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
713 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
714 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
715 'Tag', 'SineWave_Amplitudes');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
716
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
717 %--- Frequencies
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
718 % label
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
719 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
720 b = b - h - 2*vmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
721 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
722 'String', 'Frequencies [Hz]',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
723 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
724 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
725 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
726 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
727 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
728
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
729 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
730 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
731 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
732 'String', '1',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
733 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
734 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
735 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
736 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
737 'Tag', 'SineWave_Frequencies');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
738
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
739 %--- Phases
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
740 % label
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
741 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
742 b = b - h - 2*vmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
743 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
744 'String', 'Phases [deg]',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
745 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
746 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
747 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
748 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
749 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
750
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
751 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
752 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
753 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
754 'String', '0',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
755 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
756 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
757 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
758 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
759 'Tag', 'SineWave_Phases');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
760
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
761 %--- Nsecs
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
762 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
763 b = b - h - 2*vmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
764 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
765 'String', 'Lengths [s]',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
766 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
767 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
768 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
769 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
770 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
771
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
772 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
773 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
774 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
775 'String', '1',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
776 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
777 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
778 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
779 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
780 'Tag', 'SineWave_Lengths');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
781
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
782 %--- Toffs
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
783 l = hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
784 b = b - h - 2*vmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
785 sth = uicontrol(pan, 'Style','text',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
786 'String', 'Starts [s]',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
787 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
788 'HorizontalAlignment', 'right',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
789 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
790 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
791 'Position',[l b Lwidth h]);
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
792
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
793 % edit box
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
794 l = l + Lwidth + hmarg;
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
795 sth = uicontrol(pan, 'Style','edit',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
796 'String', '0',...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
797 'Units', 'normalized', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
798 'BackgroundColor', 'w', ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
799 'Fontsize', mainfig.Gproperties.fontsize, ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
800 'Position',[l b Ewidth h], ...
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
801 'Tag', 'SineWave_Starts');
|
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff
changeset
|
802 end
|