Using the State-of-Health information

Updated 12-June-2001 by ardila@astron.berkeley.edu

DISCLAIMER:  This document is still under development, as is the analysis software itself.  Please report any errors when trying these examples to D.R. Ardila at the above email address.

The State-of-Health data contains informations about various sensors in the spacecraft. To use it, you should know either the name of the keyword of a given register or some substring of its word description (see below).
In any of the instructions below, you can use the keyword /SOH_INCLUDE_ALL. With this, all packets are included, even those marked as bad by hsi_bad_pak. If not set, only good packets are included. hsi_bad_pak checks for a lot of things, including time problems.

Start by defining your object:

IDL> o=hsi_sohdata()

Then do

IDL>o->plot,filename='XXX'

where 'XXX' is the file name. This will call up a widget. to plot. Then you can enter part of the word description of the register you are interested in, or part of its name. The search routine tries to match the target string to a substring in the name of the register or its description.  For example 'temperature' will search for the words 'temperature', 'Temperature'  and 'TEMPERATURE'  in the word descriptions and names of the registers (there are more than 20!). Alternatively, you can use 'ICP1T', which will return the contents of the register that contains the  "Cold plate temperature monitor # 1'.More information on registers can be found in here.
You can also limit the time range of the search. After some registers have been found that match your description, you can select them to plot them.

The actual data can be obtained from:

IDL> p=o->getdata(filename='XXX', soh_label=['YYY1','YYY2',...], [soh_time_range=[A,B],...])

where 'XXX' is the file name, soh_label is an array of strings containing part of the word description for the register or the tags, and soh_time_range is the time range wanted (only two control keywords are defined specifically for this object). The output is an array of pointers, where each element points to an array containing the data for the register. What each data vector contains can be found out from the info structure:

IDL>o->print,/info_only

It contains the following tags:

 SOH_ABSOLUTE_TIME_RANGE
                    DOUBLE  = Array[2]
 SOH_TIME_ARRAY
                   POINTER   = <NullPointer>
 SOH_INFO
                    POINTER   = <NullPointer>
SOH_DATA_FILES
                    STRUCT    -> <Anonymous> Array[1]

SOH_ABSOLUTE_TIME_RANGE follows the usual HESSI time conventions for absolute times.
SOH_TIME_ARRAY is a pointer to an array of absolute times, where each element of the array indicates the collect time of the register content.
SOH_DATA_FILES contains the information present in the HESSI*.PDB files (where the register is in the packet, its data type, etc)
SOH_INFO is an array of pointers. Each element points to an informational structure that contains stuff about the register (this information can also be found here). There are two kinds of informational structures: the analog kind and the "other" kind.

The analog kind has the following tags:

   MNEMONIC        STRING    ''
   NAME            STRING    ''
   DESTINATION     STRING    ''
   UNITS           STRING    ''
   RED_LOW         DOUBLE          -1.0000000
   YELL_LOW        DOUBLE          -1.0000000
   RED_HIGH        DOUBLE          -1.0000000
   YELL_HIGH       DOUBLE          -1.0000000
   POLY_TERMS      POINTER   <NullPointer>

MNEMONIC has the obscure tag name
NAME has the word description, as given in the HESSITY001.PDB file
DESTINATION is the data type of the original data.
UNITS are the units of the data
RED_LOW, YELL_LOW, RED_HIGH, YELL_HIGH are the red and yellow limits of the data
POLY_TERMS is a pointer to an array of floats that contain the polynomial numbers used in obtaining the data.

The other kind contains information about non-analog data, and has the following tags:

   MNEMONIC        STRING    ''
   NAME            STRING    ''
   DESTINATION     STRING    ''
   UNITS           STRING    ''
   TEXT            POINTER   <NullPointer>

The meaning of the tags is the same. TEXT is a pointer to a string that contains information relevant to the register.