Skip to content
Snippets Groups Projects
Commit 65ad0a0a authored by Cristian Galperti's avatar Cristian Galperti
Browse files

All new node 02 inputs matching with std acq

The only differences are due to ADC calibration
differences
parent 43368a14
No related branches found
No related tags found
No related merge requests found
...@@ -41,7 +41,11 @@ classdef SCDclass_taskmdsloadprevADC < SCDclass_task ...@@ -41,7 +41,11 @@ classdef SCDclass_taskmdsloadprevADC < SCDclass_task
switch(obj.node) switch(obj.node)
case 2 case 2
[~,value]=obj.getdataNode02ACQ196(shot); %% Here we need to switch betweeen old and new acquisition unit and tcv standard also if shot<65113
[~,value]=obj.getdataNode02ACQ196(shot); %% Here we need to switch betweeen old and new acquisition unit and tcv standard also
else
[~,value]=obj.getdataNode02tst(shot); %% Here we need to switch betweeen old and new acquisition unit and tcv standard also
end
end end
end end
...@@ -121,6 +125,33 @@ classdef SCDclass_taskmdsloadprevADC < SCDclass_task ...@@ -121,6 +125,33 @@ classdef SCDclass_taskmdsloadprevADC < SCDclass_task
end end
end end
function [obj, value] = getdataNode02tst(obj, shot)
% TODO: this should go away as soon as we use the official rtc
% tree
mdsopen('rtctst',shot);
T=timeseries;
timebase=mdsvalue('dim_of(\top.tcvrt02.adc.adc_001)'); %% TODO: check with marte
d_time = double(mdsvalueraw( '\top.tcvrt02.params:d_time' ))*1.0e-6;
%timebase = round(timebase.*1/d_time)*d_time-d_time/2;
timebase = round(timebase.*1/d_time)*d_time-d_time/100;
T.Time=timebase;
T.Data=zeros(numel(timebase),192);
if obj.verbose==1
fprintf('Getting data for bus: ''%s'' (%s, shot %d) ', obj.modelbus, obj.classname, shot);
end
for ii=1:192
channelstr=sprintf('\\top.tcvrt02.adc.adc_%03d.raw',ii);
T.Data(:,ii)=int16(mdsvalue(channelstr));
if obj.verbose==1 && mod(ii,4)==0
fprintf('.');
end
end
value=T;
if obj.verbose==1
fprintf('\n');
end
end
end end
end end
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment