Die Migration der Bereiche "Docker Registry" und "Artifiacts" ist fast abgeschlossen. Die letzten Daten werden im Laufe des heutigen Abend (05.08.2021) noch vollständig hochgeladen. Das Anlegen neuer Images und Artifacts funktioniert bereits wieder.

Commit 5e0a61fa authored by Markus Mueller-Trapet's avatar Markus Mueller-Trapet
Browse files

add support for accelerometer and velocity calibration

parent ba0fe51c
......@@ -20,8 +20,24 @@ hw_ch = MC(1).hardware_channel;
preamp_var = false;
switch(lower(MCE.type))
case {'sensor'}
sInit.Reference = '94';
sInit.Unit = 'dB re Pa';
tmp = itaValue(1,'V')/MCE.sensitivity;
switch tmp.unit
case 'Pa'
sInit.Reference = '94';
sInit.Unit = 'dB re Pa';
case 'm/s'
sInit.Reference = '1';
sInit.Unit = 'm/s';
case 'm/s^2'
sInit.Reference = '9.8';
sInit.Unit = 'm/s^2';
case 'N'
sInit.Reference = '1';
sInit.Unit = 'N';
otherwise
sInit.Reference = '1';
sInit.Unit = '1';
end
case {'preamp','ad','preamp_robo_fix','preamp_modulita_fix','preamp_aurelio_fix'}
sInit.Reference = '1';
sInit.Unit = 'V';
......@@ -148,8 +164,10 @@ oldSens = MCE.sensitivity;
sInit.Channel = hw_ch;
if strcmpi(sInit.Unit,'V')
sInit.Reference = itaValue(pList{1},'V');
else
elseif strcmpi(sInit.Unit,'dB re Pa')
sInit.Reference = itaValue(10^(pList{1}/20)*2e-5,'Pa');
else
sInit.Reference = itaValue(pList{1},sInit.Unit);
end
sInit.samplingRate = pList{2};
sInit.length = pList{3}*sInit.samplingRate;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment