PDS_VERSION_ID          = PDS3
RECORD_TYPE             = STREAM
OBJECT                  = TEXT
  PUBLICATION_DATE      = 1999-05-14
  NOTE                  = "Information on spectral editing masks"
END_OBJECT              = TEXT
END
 
 
The TES onboard Data Editor aggregates the spectral data from the six
detectors, in order to reduce the total amount of data to be downlinked.
Data editing is performed according to the Detector and Spectral Masks
specified by the sequence. Detector masks are applied prior to spectral
masks.
 
Spectral masks are applied to combine data in the spectral domain. The
data from each spectral sample may either be selected/rejected, or 
averaged with the data from adjacent samples. The selection or average
option is determined by a bit in the spectral mask itself.

The detectors make up an array three detectors wide by two detectors tall.
Detectors are numbered from left to right across the array, starting with
1 in the upper left, ending with 6 in the lower right. Each detector has an 
associated spectral buffer with the same number. There are two
spectral masks associated with the data acquired by the central and
peripheral detectors respectively. The center mask is used on spectral
buffers 2 and 5, while the periphery mask is used on spectral buffers
1,3,4, and 6.

At the end of all additions, each data point is divided by the total
number of samples used to generate it. In this division any failed
detectors are taken into account so that the final numbers are an
average of the data from active detectors only. The spectral data
is then scanned and shifted appropriately so that the highest value
is represented in a 12 bit wide number (sign bit plus 11 bit mantissa).
The amount of shifting is the exponent which is also included in the
downlinked packet.

Data editing is all done "in-place" with the edited data replacing
the original values in the spectral buffers. The TES onboard Data Editor
keeps track of the final lengths of the six spectral buffers after editing.

TES has 19 spectral masks loaded onboard at all times (residing in PROM).
The names of these 19 masks are listed below (the bits are in specmask.tbl).
Other spectral masks can be designed on the ground and then loaded on board
during regular sequence command uploads.

Mask 00         Full_Select
Mask 01         Half_Select
Mask 02         Third_Select
Mask 03         Quarter_Select
Mask 04         Eighth_Select
Mask 05         Full_Average
Mask 06         Half_Average
Mask 07         Third_Average
Mask 08         Quarter_Average
Mask 09         Eighth_Average
Mask 10         Half+CO2_Select
Mask 11         Third+CO2_Select
Mask 12         Quarter+CO2_Select
Mask 13         Half+CO2_Average
Mask 14         Third+CO2_Average
Mask 15         Quarter+CO2_Average
Mask 16         Half+H2O+CO2_Select
Mask 17         Half+H2O+CO2_Average
Mask 18         Polar_Half_Average