<?xml version="1.0" encoding="UTF-8" standalone="no"?>

<?xml-model href="https://pds.nasa.gov/pds4/pds/v1/PDS4_PDS_1J00.sch" 
            schematypens="http://purl.oclc.org/dsdl/schematron"?>
<?xml-model href="https://pds.nasa.gov/pds4/mission/ody/v1/PDS4_ODY_1J00_1000.sch" 
            schematypens="http://purl.oclc.org/dsdl/schematron"?>

<Product_Observational xmlns="http://pds.nasa.gov/pds4/pds/v1"
  xmlns:pds="http://pds.nasa.gov/pds4/pds/v1"
  xmlns:ody="http://pds.nasa.gov/pds4/mission/ody/v1"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://pds.nasa.gov/pds4/pds/v1 https://pds.nasa.gov/pds4/pds/v1/PDS4_PDS_1J00.xsd
                      http://pds.nasa.gov/pds4/mission/ody/v1 https://pds.nasa.gov/pds4/mission/ody/v1/PDS4_ODY_1J00_1000.xsd">
  <Identification_Area>
    <logical_identifier>urn:nasa:pds:odyssey_grs_edr:data_hk_raw:message_log_20240708</logical_identifier>
    <version_id>1.0</version_id>
    <title>Mars Odyssey GRS raw housekeeping product: message_log_20240708</title>
    <information_model_version>1.19.0.0</information_model_version>
    <product_class>Product_Observational</product_class>
    <Modification_History>
      <Modification_Detail>
        <modification_date>2025-02-27</modification_date>
        <version_id>1.0</version_id>
        <description>Release 91</description>
      </Modification_Detail>
    </Modification_History>
  </Identification_Area>
  <Observation_Area>
    <Time_Coordinates>
      <start_date_time>2024-07-08T00:01:35.664Z</start_date_time>
      <stop_date_time>2024-07-08T23:41:28.241Z</stop_date_time>
    </Time_Coordinates>
    <Investigation_Area>
      <name>MARS Odyssey</name>
      <type>Mission</type>
      <Internal_Reference>
        <lid_reference>urn:nasa:pds:context:investigation:mission.2001_mars_odyssey</lid_reference>
        <reference_type>data_to_investigation</reference_type>
      </Internal_Reference>
    </Investigation_Area>
    <Observing_System>
      <Observing_System_Component>
        <name>2001 MARS ODYSSEY</name>
        <type>Host</type>
        <Internal_Reference>
          <lid_reference>urn:nasa:pds:context:instrument_host:spacecraft.ody</lid_reference>
          <reference_type>is_instrument_host</reference_type>
        </Internal_Reference>
      </Observing_System_Component>
      <Observing_System_Component>
        <name>GAMMA RAY SPECTROMETER</name>
        <type>Instrument</type>
        <Internal_Reference>
          <lid_reference>urn:nasa:pds:context:instrument:ody.grs</lid_reference>
          <reference_type>is_instrument</reference_type>
        </Internal_Reference>
      </Observing_System_Component>
    </Observing_System>
    <Target_Identification>
      <name>Mars</name>
      <type>Planet</type>
      <Internal_Reference>
        <lid_reference>urn:nasa:pds:context:target:planet.mars</lid_reference>
        <reference_type>data_to_target</reference_type>
      </Internal_Reference>
    </Target_Identification>
    <Mission_Area>
      <ody:ODY_Parameters>
        <ody:GRS_Observation_Information>
        <ody:release_number>91</ody:release_number>
        <ody:product_type>MESSAGE_LOG</ody:product_type>
        <ody:product_version_id>1.0</ody:product_version_id>
        <ody:mission_phase_name>EXTENDED MISSION</ody:mission_phase_name>
        <ody:spacecraft_clock_start>359645455839</ody:spacecraft_clock_start>
        <ody:spacecraft_clock_stop>359667265150</ody:spacecraft_clock_stop>
        </ody:GRS_Observation_Information>
      </ody:ODY_Parameters>
    </Mission_Area>
  </Observation_Area>
  <File_Area_Observational>
    <File>
      <file_name>message_log_20240708.dat</file_name>
      <local_identifier>message_log_data_table</local_identifier>
      <creation_date_time>2025-02-27T21:49:33.419</creation_date_time>
    </File>
    <Table_Binary>
      <offset unit="byte">0</offset>
      <records>210</records>
      <description>
        Messages returned by Common Electronics Box (CEB).
        Possible message id's are as follows:
        0 MSG_ERROR_START start of error messages
        1 MSG_START_ERR error during startup
        2 MSG_DMA_ERR error in DMA
        3 MSG_SC_DATA_NOT_READ error, data from SC not read
        4 MSG_DATA_NOT_SENT error, data packet not sent
        5 MSG_TABLE_UNKNOWN error, unknown analog table parameter
        6 MSG_TABLE_SETTING error, unknown analog setting
        7 MSG_TABLE_VALUE error, analog value is out of range
        8 MSG_2_MANY_CMDS error, too many commands in delayed list
        10 MSG_BAD_CHECKSUM error, bad checksum
        11 MSG_NOT_READ_SCBUF error, incorrect data in sc buffer
        12 MSG_OLD_COMMAND error, command is old
        13 MSG_HI_ENG_FULL error, engineering buffer full
        14 MSG_GAMMA_Q_FULL error, too many commands to gamma
        15 MSG_LANL_Q_FULL error, too many commands to lanl
        16 MSG_BAD_TRACE_LEVEL error, unknown debug level
        17 MSG_DUMP_TOO_LONG error, requested memory dump is too long
        18 MSG_DUMP_ADDRESS error, address is out of memory range
        19 MSG_UNDEF_CODE_INTER error, undefined code interrupt
        20 MSG_DIV_ZERO_INTER error, divide by zero interrupt
        21 MSG_INVALID_CMD error, command not in list
        22 MSG_EQ_CROSS_TOO_LATE error, equator crossing command came late
        23 MSG_EEPROM_WRITE_FAIL error, write to eeprom did not work
        24 MSG_CHG_SEQ_FAILED error, updating cmd sequence failed
        25 MSG_PWR_NOT_OK error, power on failed
        26 MSG_NO_DATA error, no data available
        27 MSG_BAD_SIZE error, size of data not what is expected
        28 MSG_BAD_LANL_REG error, LANL register not what is expected
        30 MSG_INVALID_CEB error, invalid ceb timer number
        31 MSG_NO_CMD_IN_SEQ error, no commands in a sequence
        32 MSG_DOOR_NOT_ENABLED error, door not enabled
        33 MSG_DOOR_STATE error, door already open or closed
        34 MSG_ANNEAL error, already anneal or not
        35 MSG_NOT_POWERED error, the instrument not yet on
        36 MSG_DOOR_TIME error, time to move door expired
        37 MSG_LATCH_TIME error, time to move door expired
        38 MSG_DOOR_ALREADY_MOVING error, the door is already in motion
        39 MSG_NO_DOOR_DITHER error, no door dither detected in close op
        40 MSG_ERR_BUF_FULL error, no room left in error buffer
        41 MSG_MSG_BUF_FULL error, no room left in message buffer
        42 MSG_COM_ERR error, communication problem
        43 MSG_NOT_ADD_UTIL error, task not added to util timers
        44 MSG_INVALID_INDEX error, invalid parameter index
        46 MSG_OVERRIDE error, override not enabled
        47 MSG_GAMMA_VOLTAGE warn, hi volt not turn on, temp not in range
        48 MSG_FUNC_CHECKSUM error, function checksum calc failed
        49 MSG_RAMP_ABORT error, gamma high voltage ramp abortted
        50 MSG_ADDR_CHECKSUM error, function address and size
        51 MSG_ANNEAL_NOT_ENABLED error, anneal not enabled
        52 MSG_CANT_SET_PARAM error, cant set DOOR and ANNEAL enable
        53 MSG_EEPROM_NOT_ENABLED error, attempt chng eeprom state w/o enable
        54 MSG_BAD_SEQ_NUM error, invalid sequence number
        70 MSG_RAM_CHECK_FAIL error, RAM check failed
        71 MSG_FSW_EEPROM_CHECK_FAIL error, FSW EEPROM checksum check failed
        72 MSG_MINI_MEM_CHECK_FAIL error, found error in mini memory check
        73 MSG_NOT_LOADER_CMD error, valid cmd but not handled by loader
        74 MSG_INVALID_MEM_ADDRESS error, invalid memory
        75 MSG_BAD_SIDE_PATTERN error, bad side pattern
        76 MSG_UART_INTER_IN_LOADER error, UART interrupt is received by loader
        80 MAX_ERR_MSG end of error messages
        81 MSG_ORBIT_PERIOD length of an orbit
        82 MSG_PIXEL_PERIODS length of a pixel for the instruments
        83 MSG_TABLE_CHANGE analog table has been changed
        84 MSG_SC_TIME1 spacecraft time was sent
        85 MSG_SC_TIME2 spacecraft time was sent
        86 MSG_EQ_CROSS_ASC ascending equator crossing command received
        87 MSG_CMD_DONE command has been executed
        88 MSG_TRACE_LEVEL debug level has been changed
        89 MSG_INTER_CNT number of times and interrupt has been run
        90 MSG_1.0 current fsw version
        91 MSG_ENTER function was entered
        92 MSG_EXIT function was exited
        93 MSG_DATA data was presented
        94 MSG_ADDED_DELAYED cmd added to delayed list
        95 MSG_TIMING amount of process time between heartbeats
        96 MSG_INTER_TIME time spent in interupts
        97 MSG_SHUTDOWN shutdown command received from S/C
        98 MSG_HEND_POWER hend power change
        99 MSG_ANNEAL_CMD received anneal door enable from S/C
        100 MSG_HEARTBEAT the number of hearbeat sent so far
        101 MSG_ACTION_COMPLETE a delayed action has been completed
        102 MSG_SC_TIME_DELTA delta between SC and CEB time
        103 MSG_POWER_CHANGE gamma, lanl or heater power changed
        104 MSG_CHANGE_ANNEAL_STATE went to a different annealing state
        105 MSG_SEQ_EXEC a sequence is being executed
        106 MSG_GAMMA_RAMP gamma has been ramped
        107 MSG_PARAM_CHANGE parameter has been changed
        108 MSG_ANNEAL_ENABLE_CMD received anneal enable from S/C
        130 MSG_FSW_EEPROM_PASSED ldr passed FSW EEPROM checksum checking
        131 MSG_LDR_MEM_PASSED ldr passed memory checking
        132 MSG_LDR_INIT_DONE ldr finished initialization
      </description>
      <Record_Binary>
        <fields>9</fields>
        <groups>0</groups>
        <record_length unit="byte">175</record_length>
        <Field_Binary>
          <name>SC_EV_TIME</name>
          <field_number>1</field_number>
          <field_location unit="byte">1</field_location>
          <data_type>UnsignedMSB8</data_type>
          <field_length unit="byte">8</field_length>
          <description>The spacecraft time this message was generated, in ticks (256 per second).</description>
        </Field_Binary>
        <Field_Binary>
          <name>UTC</name>
          <field_number>2</field_number>
          <field_location unit="byte">9</field_location>
          <data_type>ASCII_String</data_type>
          <field_length unit="byte">23</field_length>
          <description>SC_EV_TIME converted to UTC, stored as yyyy-mm-ddThh:mm:ss.sss.</description>
        </Field_Binary>
        <Field_Binary>
          <name>MSG_ID</name>
          <field_number>3</field_number>
          <field_location unit="byte">32</field_location>
          <data_type>UnsignedMSB2</data_type>
          <field_length unit="byte">2</field_length>
          <description>Identifies type of message. See Label for details.</description>
        </Field_Binary>
        <Field_Binary>
          <name>GRS_PIXEL_NUMBER</name>
          <field_number>4</field_number>
          <field_location unit="byte">34</field_location>
          <data_type>UnsignedMSB4</data_type>
          <field_length unit="byte">4</field_length>
          <description>Sequential counter of accumulation intervals, starts with one as grs orbit
            begins. Special case on reboot when the the CEB is in orbit 0, pixel 0.</description>
          <Special_Constants>
            <invalid_constant>0</invalid_constant>
          </Special_Constants>
        </Field_Binary>
        <Field_Binary>
          <name>GRS_ORBIT_NUMBER</name>
          <field_number>5</field_number>
          <field_location unit="byte">38</field_location>
          <data_type>UnsignedMSB4</data_type>
          <field_length unit="byte">4</field_length>
          <description>Sequential counter of orbits from GRS CEB boot.</description>
          <Special_Constants>
            <invalid_constant>0</invalid_constant>
          </Special_Constants>
        </Field_Binary>
        <Field_Binary>
          <name>ODY_ORBIT_NUMBER</name>
          <field_number>6</field_number>
          <field_location unit="byte">42</field_location>
          <data_type>UnsignedMSB4</data_type>
          <field_length unit="byte">4</field_length>
          <description>Orbit number common to all instruments aboard Odyssey. This orbit number is
            incremented by one as the spacecraft passes through the orbital descending node.</description>
          <Special_Constants>
            <invalid_constant>0</invalid_constant>
          </Special_Constants>
        </Field_Binary>
        <Field_Binary>
          <name>COUNTER</name>
          <field_number>7</field_number>
          <field_location unit="byte">46</field_location>
          <data_type>UnsignedByte</data_type>
          <field_length unit="byte">1</field_length>
          <description>The packet counter from the message pkt, values from 0 to 15.</description>
        </Field_Binary>
        <Field_Binary>
          <name>ORIGIN</name>
          <field_number>8</field_number>
          <field_location unit="byte">47</field_location>
          <data_type>UnsignedByte</data_type>
          <field_length unit="byte">1</field_length>
          <description>Origin of execution (loader or flight software).</description>
        </Field_Binary>
        <Field_Binary>
          <name>MESSAGE_TEXT</name>
          <field_number>9</field_number>
          <field_location unit="byte">48</field_location>
          <data_type>ASCII_String</data_type>
          <field_length unit="byte">128</field_length>
          <description>More verbose description of message.</description>
        </Field_Binary>
      </Record_Binary>
    </Table_Binary>
  </File_Area_Observational>
  <File_Area_Observational_Supplemental>
    <File>
      <file_name>message_log_20240708.lbl</file_name>
    </File>
    <Stream_Text>
      <offset unit="byte">0</offset>
      <parsing_standard_id>PDS3</parsing_standard_id>
      <description>PDS3 label</description>
      <record_delimiter>Carriage-Return Line-Feed</record_delimiter>
    </Stream_Text>
  </File_Area_Observational_Supplemental>
</Product_Observational>