test-bench-pd200/matlab/run_test.m
2021-01-22 11:34:24 +01:00

30 lines
716 B
Matlab

%%
tg = slrt;
f = SimulinkRealTime.openFTP(tg);
mget(f, 'data/data.dat');
close(f);
%% Convert the Data
data = SimulinkRealTime.utils.getFileScopeData('data/data.dat').data;
Vin = data(:, 1);
Vout = data(:, 2);
t = data(:, end);
%% Notes
pre_amp = struct('coupling', 'DC A', ...
'gain', 50000, ...
'LPF', '6dB 0.1Hz', ...
'input', 'SSI2V (20bits, +/- 10V)', ...
'HPF', '6dB 30kHz');
pd200 = struct('input', 'DAC', ...
'signal', 'sweep sine 0.1V 1Hz-5kHz', ...
'f_max', f1, ...
'load', '3 uF');
notes = struct('pd200', pd200);
%% Save
save('mat/tf_pd200_7_0_1V.mat', 't', 'Vin', 'Vout', 'notes');