Sync from remote server: 2025-10-12 18:56:41
This commit is contained in:
45
ATD/LastElab_bisRL.m
Executable file
45
ATD/LastElab_bisRL.m
Executable file
@@ -0,0 +1,45 @@
|
||||
function DatiElabRadialLink = LastElab_bisRL(conn,NodoRadialLink,rRL,...
|
||||
datainiRL,tempoiniRL,IDcentralina,DTcatena,FileName)
|
||||
|
||||
text = 'LastElab_bisRL function started';
|
||||
fileID = fopen(FileName,'a');
|
||||
fmt = '%s \r';
|
||||
fprintf(fileID,fmt,text);
|
||||
|
||||
NRadialLink = cell2mat(NodoRadialLink(:,2));
|
||||
NodeType = 'Radial Link';
|
||||
ii = 1; % contatore
|
||||
col = 9; % contatore colonne
|
||||
while ii <= rRL
|
||||
ini_col = col-8;
|
||||
nN = num2str(NRadialLink(ii,1));
|
||||
% Scarico di dati di spostamenti
|
||||
comando = ['select EventDate, EventTime, XShift, YShift, ZShift, X, Y, Z, T_node from ElabDataView where EventDate = ''' ...
|
||||
datainiRL ''' and EventTime >= ''' tempoiniRL ''' and UnitName = ''' IDcentralina ''' and ToolNameID = '''...
|
||||
DTcatena ''' and NodeType = ''' NodeType ''' and NodeNum = ''' nN ''' '];
|
||||
curs = exec(conn,comando);
|
||||
curs = fetch(curs);
|
||||
DATnodoRLd = curs.Data;
|
||||
% Scarico di dati di spostamenti
|
||||
comando = ['select EventDate, EventTime, XShift, YShift, ZShift, X, Y, Z, T_node from ElabDataView where EventDate > ''' ...
|
||||
datainiRL ''' and UnitName = ''' IDcentralina ''' and ToolNameID = '''...
|
||||
DTcatena ''' and NodeType = ''' NodeType ''' and NodeNum = ''' nN ''' '];
|
||||
curs = exec(conn,comando);
|
||||
curs = fetch(curs);
|
||||
DATnodoRL = curs.Data;
|
||||
[~,c1] = size(DATnodoRL);
|
||||
[~,c2] = size(DATnodoRLd);
|
||||
if c1 == c2
|
||||
DATnodoRL = [DATnodoRLd; DATnodoRL];
|
||||
elseif c1 < c2 % solo giorno di riferimento
|
||||
DATnodoRL = DATnodoRLd;
|
||||
end
|
||||
DatiElabRadialLink(:,ini_col:col) = DATnodoRL(:,:);
|
||||
col = col+9;
|
||||
ii = ii+1;
|
||||
end
|
||||
|
||||
text = 'LastElab_bisRL function worked correctly for Radial Link';
|
||||
fprintf(fileID,fmt,text);
|
||||
fclose(fileID);
|
||||
end
|
||||
Reference in New Issue
Block a user