package GlobalHK;
use strict;
use English;
use Carp;
use vars
qw(@ISA $VERSION $name $author $date $version @instList $numberOfStreams);
@ISA = qw(Module);
use ModuleResources;
# Declare identity, version, author, date, etc.
$name = __PACKAGE__;
$VERSION = '1.68';
$version = $VERSION;
$author="Richard West,Dean Hinshaw,Duncan John Fyfe,Ed Chapin";
$date="2013-06-11";
#
# ChangeLog
# =========
#
# Version 1.68 - 2013-06-11 (EC)
# ------------
#
# + Merge changes from SOC version.
#
# Version 1.67 - 2006-09-28 (DJF)
# ------------
#
# + Commented out redundant work. Was calling findFile and newFile then doing nothing with returned values.
#
# Version 1.66 - 2006-07-05 (DJF)
# ------------
#
# + Changed numberOfStreams to use standerdized function.
#
# Version 1.65 - 2002-02-04 (DH)
# ------------
#
# + Remove creation of 'Good Attitude Data GTI', as it will no longer
# be used.
# + Add '!isNull(DAHFPNT) &&' to tabgti expression for creating the
# attitude GTI. Note that the cutoff of 3 acrmin is tighter than
# the rgsproc default of 5 acrmin.
#
# Version 1.64 - 2001-03-21 (DH)
# ------------
#
# + Create GTI of good attitude data, for use by other modules
#
# Version 1.63 - 2001-03-16 (DH)
# ------------
#
# + Print out version number in performAction() for
# tracking purposes.
#
# Version 1.62 - 2001-02-14 (DH)
# ------------
#
# + Change column name for test to make attitude GTIs
# from DAHFNOM to DAHFPNT.
#
# Version 1.61 - 2000-11-22 (DH)
# ------------
#
# + First production version.
#
@instList=qw(all);
sub numberOfStreams
{
return 1;
}
sub evaluateRules {
# ignore for slew processing
return ignore() if ($ENV{'PCMS_ISSLEW'});
#
start() if complete(module => 'MakeCIF', instrument => 'all');
}
sub performAction {
info("Module version number: $version");
# Create attitude HK file
#
my $hkFile=newFile(class => 'product',
instrument => 'all',
content => 'Attitude time series');
doCommand('atthkgen',
atthkset => $hkFile,
timestep => 1.0)
or return exception();
# Create GTI from attitude data
#
my $gtiFile=newFile(class => 'intermediate',
instrument => 'all',
content => 'Attitude GTI');
doCommand('tabgtigen',
table => "$hkFile:ATTHK",
expression => '!isNull(DAHFPNT) && DAHFPNT < 3.0/60.0',
gtiset => $gtiFile,
prefraction => 0.0,
postfraction => 0.0)
or return exception();
# Create orbit file
#
# my $inOrbit=findFile(class => 'odf',
# content => 'Reconstructed orbit',
# required => 'true');
# my $outOrbit=newFile(class => 'intermediate',
# content => 'Spacecraft orbit');
# doCommand('orbit', useodf => 'no', set => $inOrbit, outfile => $outOrbit)
# or return exception();
success();
}
1;