NAME

xrthkproc -- Process the Swift XRT Housekeeping Header Packets file.

USAGE

xrthkproc hdfile outfile [parameter = < value >]

DESCRIPTION

'xrthkproc' processes the Swift XRT Housekeeping Header Packets file and corrects the TIME and ENDTIME columns for the frames corresponding to Windowed Timing (WT) and Photodiode (PD) modes.
The time values for the TIME and ENDTIME columns are calculated with the same algorithm used to time tag the events in the WT and PD modes (see 'xrttimetag' help). The algorithm requires the source position in detector coordinates (DETX and DETY specified through the parameters 'srcdetx' and 'srcdety'). If the parameters 'srcdetx' and 'srcdety' are set to a negative value the source detector coordinates are calculated using the celestial coordinates of the source (specified through the parameters 'srcra' and 'srcdec'), the RA and Dec of the nominal pointing (parameters 'ranom' and 'decnom') and the attitude file (parameter 'attfile'). During the slews the time tag of the events assumes that all the events are at position (300,300) in detector coordinates and the input 'srcra','srcdec' are ignored.
'xrthkproc' also calculates the values of the column HKTIME that contains the times when the HK are measured on-board.
The keyword XRTTIMES set to TRUE (T) is added to the header to indicate that the file has been already processed by the task and an extra raw is added to the the 'hdfile' with only the value for the column TIME set equal to the ENDTIME of the previous raw.

'xrthkproc' can be re-run, for example for a different input source position and the columns can be overwritten.

PARAMETERS

hdfile [file name]
Name of the input Housekeeping Header Packets FITS file.

outfile [file name]
Name of the output FITS file. Type 'DEFAULT' to use the standard name.

attfile [file name]
Name of the input Attitude FITS file.

srcdetx [integer]
Source detector coordinate x. If <0 the parameters 'srcra', 'srcdec', 'ranom', 'decnom' and 'attfile' are used.

srcdety [integer]
Source detector coordinate y. If <0 the parameters 'srcra', 'srcdec', 'ranom', 'decnom' and 'attfile' are used.

srcra [real]
Source RA position (degrees).

srcdec [real]
Source DEC position (degrees).

ranom [real]
Nominal Right Ascension (degrees).

decnom [real]
Nominal Declination (degrees).

(aberration=no)[boolen]
If set to no, the aberration correction is not applied to the data.

(attinterpol=no)[boolen]
If set to no, the attitude parameters correspond to the closest time value to the time of each frame.

(teldef = CALDB) [file name]
Name of the input TELDEF file. Type CALDB to use the file in the Calibration Database.

(clobber=no) [boolean]
If 'clobber'=yes and 'outfile'=filename, the file with the same name will be overwritten if it exists.

(history=yes) [boolean]
If set to 'yes', write history keywords to the output file.

(chatter = 2) [integer]
Chatter level (min=0, max=5)

EXAMPLES

  1. Process the housekeeping file sw00073232001xhd.hk using the maximum verbosity level.

     xrthkproc hdfile=sw00073232001xhd.hk  outfile=DEFAULT
         attfile=sw00073232001sattm.fits ranom=89.17 decnom=0.53 
         srcra=89.2 srcdec=0.43 chatter=5 
    

BUGS

SEE ALSO

LAST MODIFIED

March 2005