#! /usr/bin/perl # This program is used to calibrate the data for x-talk purposes. # So, when finished, only TDC's will be calibrated, leaving both # ADC's and TOT's raw and uncalibrated. These raw ADC's and TOT's # will eventually be plotted for determining where to cut out # cross talk. -- Amanda Heffner-Wong June 24, 2003 my $amacalib = "~/siegmund/amanda/amacalib/amacalib"; my $deff = "~/siegmund/merz/deff"; my $vmefile = "vmecal_2002.db"; my $calibfile = "amacalib.2002.020501.db"; # Get the files that have been run through run_reader.pl only. my $dir = "/home/hodges/crosstalk/2003"; my @infiles = ("ab_2003_052_6929_015.data.mu.min_bias.f2k", "ab_2003_052_6929_065.data.mu.min_bias.f2k", "ab_2003_065_6961_022.data.mu.min_bias.f2k", "ab_2003_095_7014_029.data.mu.min_bias.f2k", "ab_2003_095_7014_079.data.mu.min_bias.f2k", "ab_2003_095_7014_129.data.mu.min_bias.f2k"); foreach $infile (@infiles) { $outfile = "/home/aheffwong/crosstalk/$infile.out"; # The following will: 1. calibrate vme's; 2. assign ADC's; # 3. uncalibrate; and 4. calibrate TDC's, leaving ADC & TOT alone. $cmd = "less $dir/$infile". "| $amacalib -v -D $vmefile -Aa". "| $deff -P 22500:2500:9500:all". "| $amacalib -Z". "| $amacalib -T -P -Aa -z -D $calibfile". "> $outfile"; print $cmd; `$cmd`; }