|
@@ -4,7 +4,7 @@
|
|
|
%% sphear_af_power: return array of power for all capsules in a range of frequencies
|
|
%% sphear_af_power: return array of power for all capsules in a range of frequencies
|
|
|
%%
|
|
%%
|
|
|
%% usage:
|
|
%% usage:
|
|
|
-%% [R] = sphear_af_power(fmin, fmax, N, Npre)
|
|
|
|
|
|
|
+%% [R Fs] = sphear_af_power(fmin, fmax, N, Npre)
|
|
|
%%
|
|
%%
|
|
|
%% fmin, fmax: range of frequencies to consider
|
|
%% fmin, fmax: range of frequencies to consider
|
|
|
%% Npre: number of samples before the main impulse
|
|
%% Npre: number of samples before the main impulse
|
|
@@ -30,7 +30,7 @@
|
|
|
%% You should have received a copy of the GNU General Public License
|
|
%% You should have received a copy of the GNU General Public License
|
|
|
%% along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
%% along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
|
|
|
|
-function [R] = sphear_af_power(measurements, fmin, fmax, N, Npre)
|
|
|
|
|
|
|
+function [R Fs] = sphear_af_power(measurements, fmin, fmax, N, Npre)
|
|
|
pkg load signal;
|
|
pkg load signal;
|
|
|
|
|
|
|
|
%% read in reference microphone, select samples to process
|
|
%% read in reference microphone, select samples to process
|
|
@@ -47,11 +47,9 @@ function [R] = sphear_af_power(measurements, fmin, fmax, N, Npre)
|
|
|
|
|
|
|
|
capnames = cellstr(['LF'; 'RF'; 'LB'; 'RB']);
|
|
capnames = cellstr(['LF'; 'RF'; 'LB'; 'RB']);
|
|
|
|
|
|
|
|
- printf("... processing [%d] ", size(measurements));
|
|
|
|
|
%% all submitted measurements
|
|
%% all submitted measurements
|
|
|
i = 1;
|
|
i = 1;
|
|
|
for m = measurements
|
|
for m = measurements
|
|
|
- printf("%d ", m);
|
|
|
|
|
%% all capsules
|
|
%% all capsules
|
|
|
for c = 1:4
|
|
for c = 1:4
|
|
|
|
|
|
|
@@ -67,7 +65,6 @@ function [R] = sphear_af_power(measurements, fmin, fmax, N, Npre)
|
|
|
end
|
|
end
|
|
|
i = i + 1;
|
|
i = i + 1;
|
|
|
end
|
|
end
|
|
|
- printf(", done (%d)\n", size(R(:,:))(1));
|
|
|
|
|
|
|
|
|
|
end
|
|
end
|
|
|
|
|
|