un po' di roba
This commit is contained in:
@@ -41,9 +41,10 @@ my ($fileDate, $fileTime);
|
||||
my $matlab_rt = "/usr/local/MATLAB/MATLAB_Runtime/v93";
|
||||
my $matlab_func_dir = "/usr/local/matlab_func/";
|
||||
my $matlab_error = '';
|
||||
my $matlab_timeout = '1200';
|
||||
my $email_addr = 'andrea.carri@aseltd.eu,roberto.savi@aseltd.eu,alessandro.battilani@gmail.com';
|
||||
my $matlab_timeout = '1800';
|
||||
my $email_addr = 'andrea.carri@aseltd.eu,roberto.savi@aseltd.eu,edoardo.cavalca@aseltd.eu,alessandro.battilani@gmail.com,alessandro.valletta@aseltd.eu';
|
||||
my ($email_msg, $email_obj);
|
||||
my $G201_fcheck = 0;
|
||||
|
||||
|
||||
sub getTimeStamp{ # parm [ts] => timestamp for filename; log => timestamp for log
|
||||
@@ -411,20 +412,17 @@ if ( $db_name ne 'asega' ) {
|
||||
}
|
||||
|
||||
my ( $filecsvname, $path, $suffix ) = fileparse( $filename, qr/\.[^.]*/ );
|
||||
|
||||
if ( $filecsvname =~ m/^(\d\d_\d\d\d\d_|)(DT\d\d\d\d|LOC\d.*|GD\d*)_\d*$/i ) {
|
||||
($fileDate, $fileTime) = split( /\s/, <FILE> );
|
||||
($unittype, $unit ) = split( /\s/, uc <FILE> );
|
||||
$unit =~ s/;+$//;
|
||||
} elsif ( $filecsvname =~ m/^(\d\d_\d\d\d\d_|)(\d\d\d\d\d\d\d\d\d\d\d\d\d\d_)(G201_ID\d\d\d\d_DT\d\d\d\d)_\d*$/i ) {
|
||||
|
||||
# da mettere il controllo ^^^^^^^^^^^^^^^ se ha mese ed anno all'inivio
|
||||
my @strings = $filecsvname =~ /(.{1,4})(.{1,2})(.{1,2})(.{1,2})(.{1,2})(.{1,2})_(.{1,4})_(.{1,6})_(.{1,6}).*/;
|
||||
$fileDate = $strings[0] . "/" . $strings[1] . "/" . $strings[2];
|
||||
$fileTime = $strings[3] . ":" . $strings[4] . ":" . $strings[5];
|
||||
$unittype = $strings[6];
|
||||
$unit = $strings[7];
|
||||
$tool = $strings[8];
|
||||
} elsif ( $filecsvname =~ m/^G201_ID\d\d\d\d_DT\d\d\d\d_\d*_\d*$/i ) {
|
||||
my @strings = $filecsvname =~ /(.{1,4})_(.{1,6})_(.{1,6})_(.{1,4})(.{1,2})(.{1,2})(.{1,2})(.{1,2})(.{1,2}).*/;
|
||||
$unittype = $strings[0];
|
||||
$unit = $strings[1];
|
||||
$tool = $strings[2];
|
||||
$fileDate = $strings[3] . "/" . $strings[4] . "/" . $strings[5];;
|
||||
$fileTime = $strings[6] . ":" . $strings[7] . ":" . $strings[8];
|
||||
$tooltype = 'MUX';
|
||||
}
|
||||
|
||||
@@ -454,6 +452,11 @@ while ( my $line = <FILE> ) {
|
||||
$NodeData =~ s/;+$//;
|
||||
|
||||
#$NodeData =~ s/\r\n\z//;
|
||||
if ($unittype eq 'G201' and $G201_fcheck eq 0) {
|
||||
print getTimeStamp("log"). " - pid $$ >> Found $tooltype tool name: $tool\n";
|
||||
getNodesType();
|
||||
$G201_fcheck = 1;
|
||||
}
|
||||
|
||||
if ( $tooltype eq "MUX" ) {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user