listEns
changeset 34 3b4bcd55e1ea
parent 33 307630665c6c
child 37 40d85448debf
equal deleted inserted replaced
33:307630665c6c 34:3b4bcd55e1ea
     1 #!/usr/bin/perl
     1 #!/usr/bin/perl
     2 #======================================================================
     2 #======================================================================
     3 #                    L I S T E N S 
     3 #                    L I S T E N S 
     4 #                    doc: Sat Jan 18 18:41:49 2003
     4 #                    doc: Sat Jan 18 18:41:49 2003
     5 #                    dlm: Thu Mar 17 07:39:49 2016
     5 #                    dlm: Tue Apr 19 21:11:12 2016
     6 #                    (c) 2003 A.M. Thurnherr
     6 #                    (c) 2003 A.M. Thurnherr
     7 #                    uE-Info: 49 0 NIL 0 0 72 2 2 4 NIL ofnI
     7 #                    uE-Info: 181 53 NIL 0 0 72 2 2 4 NIL ofnI
     8 #======================================================================
     8 #======================================================================
     9 
     9 
    10 # Print useful info from the ensemble list or dump ensembles to
    10 # Print useful info from the ensemble list or dump ensembles to
    11 # separate files.
    11 # separate files.
    12 
    12 
    44 #				  - added active header line to -E output
    44 #				  - added active header line to -E output
    45 #	Mar  4, 2014: - added partial support for DATA_SOURCE_ID
    45 #	Mar  4, 2014: - added partial support for DATA_SOURCE_ID
    46 #				  - added support for missing PITCH/ROLL/HEADING
    46 #				  - added support for missing PITCH/ROLL/HEADING
    47 #	Sep  8, 2014: - added -B)T  
    47 #	Sep  8, 2014: - added -B)T  
    48 #   Mar 17, 2016: - adapted to new Getopt library
    48 #   Mar 17, 2016: - adapted to new Getopt library
       
    49 #	Apr 19, 2016: - added %date, %time to -E output
    49 
    50 
    50 # Notes:
    51 # Notes:
    51 #	- -E outputs data in earth coordinates, unless -b is set also
    52 #	- -E outputs data in earth coordinates, unless -b is set also
    52 #	- -E output is always in ANTS format, ignoring -A
    53 #	- -E output is always in ANTS format, ignoring -A
    53 #	- no soundspeed correction
    54 #	- no soundspeed correction
   174 			my($file) = "$dta{ENSEMBLE}[$e]->{NUMBER}$opt_E";
   175 			my($file) = "$dta{ENSEMBLE}[$e]->{NUMBER}$opt_E";
   175 		
   176 		
   176 			open(P,">$file") || die("$file: $!\n");
   177 			open(P,">$file") || die("$file: $!\n");
   177 			print(P "#!/usr/bin/perl -S list\n");
   178 			print(P "#!/usr/bin/perl -S list\n");
   178 			print(P "#ANTS#PARAMS# " .
   179 			print(P "#ANTS#PARAMS# " .
       
   180 					"date{$dta{ENSEMBLE}[$e]->{DATE}} " .
       
   181 					"time{$dta{ENSEMBLE}[$e]->{TIME}} " .
   179 					"BT_u{$dta{ENSEMBLE}[$e]->{BT_VELOCITY}[0]} " .
   182 					"BT_u{$dta{ENSEMBLE}[$e]->{BT_VELOCITY}[0]} " .
   180 					"BT_v{$dta{ENSEMBLE}[$e]->{BT_VELOCITY}[1]} " .
   183 					"BT_v{$dta{ENSEMBLE}[$e]->{BT_VELOCITY}[1]} " .
   181 					"BT_w{$dta{ENSEMBLE}[$e]->{BT_VELOCITY}[2]} " .
   184 					"BT_w{$dta{ENSEMBLE}[$e]->{BT_VELOCITY}[2]} " .
   182 					"BT_e{$dta{ENSEMBLE}[$e]->{BT_VELOCITY}[3]} " .
   185 					"BT_e{$dta{ENSEMBLE}[$e]->{BT_VELOCITY}[3]} " .
   183 					"BT_cor1{$dta{ENSEMBLE}[$e]->{BT_CORRELATION}[0]} " .
   186 					"BT_cor1{$dta{ENSEMBLE}[$e]->{BT_CORRELATION}[0]} " .