GSFC/NGIMS-FSW-06 CONTOUR/NGIMS TELEMETRY M Paulkovich February 1, 2002 rev 2.9 DOCUMENT CHANGE HISTORY Version Date Change 2.7 09 Nov 01 First CM version. Update 1.3 (detailed scan segment fmt) with new data for words 75..78 2.8 27 Nov 01 Fix ESW 16 format 2.9 01 Feb 02 Add spare 4 bytes to Dump packet, 1.1.3.5. OVERVIEW This document provides an analysis of the TM requirements and constraints, and proposes a design solution. NGIMS telemetry (TM) consists of two types: packetized and non-packetized. Packetized TM consists of 244 bytes in CCSDS format. Non-packetized TM consists of eight 16-bit words. The NGIMS packetized TM data rate is required to be less than ~4.5 K bits/second. 1. Packetized Telemetry Format The plan is to use a modified CHARGE scheme, which is based on INMS and incorporates the philosophy that each subscan is completely self-descriptive. Also, a NGIMS TM packet on the Science channel contains both Science & HK. We have no plans to use the HK channel. A first-order definition of fields and an approximation of number of bits is given below (some of these numbers will change within this memo, as we continue the analysis). Again, this document is an analysis of the requirements and progresses to the solution as implemented. Another document, the SIS-2, will be generated to describe the formats for TCs and TM without the analysis process. Until then, the reader may wish to skip to the section of interest detailing the formats for: Memory Dumps 1.1.3.5 Scan Segment 1.3 HK 1.1.7 Non-Packetized TM 2. Table 1 - TM Packet Contents Block #bits Type Description A 48 CCSDS Pri Hdr Version, Type, SecHdr, AppProcID, SeqFg, SeqCnt, Len B 16 NGIMS Hdr Memory Dump, Subscan Offset C 540 Science 15*18 bits (Counter1) plus 15*18 bits (Counter2) (Or Dump Words & metadata) D 255 Sci Metadata 15*17 bits E 285 Mux (7+12)*15 IPs (12-bit mux, 7-bit ID) F 48 Last Cmd 16 bit OpCode, 16 bit Data, 16 bit S/N G HK Statuses, Vlv positions, TC Count & Errors, RFMon Avg, Temp Avg, etc. Note that the secondary header is not used. A delta from Cassini is that there is no CRC word at the end of each packet. The Lo Sens Squareroot-plus format will not be used; all counts in TM are raw 18-bits. For future reference, the chart below indicates sensitivity (counts/s) vs. Lo Sens Counter bit size for a hypothetical 15ms IP and 1:1000 ratio, and one bit for squareroot flag: Lo Sens #bits computation Cnts/s Hi Sens 12 (7FF2 ( 0.015)*1000 2.8*1011 11 (3FF2 ( 0.015)*1000 7.0*1010 10 (1FF2 ( 0.015)*1000 1.7*1010 9 (FF2 ( 0.015)*1000 4.3*109 8 (7F2 ( 0.015)*1000 1.1*109 7 (3F2 ( 0.015)*1000 2.6*108 1.1 Itemized Block Contents, Packetized TM 1.1.1 CCSDS Headers The CCSDS Standard has a 3-word (48-bit) Primary Header and an optional 1-word (16-bit) Secondary Header. The Secondary Header is not used (TBC). Constant Fields: VersionNumber = 0002 Type = 0 Grouping = 0 Segmentation = 112 Variable Fields: The SequenceCount field will be initialized to 0 and increment for each successive packet, modulo 16k. The Length field will be set to 244 octets. The AppProcID = 48016 for "Normal" (Science) packets 48116 for Memory Dump packets 48216 for Command Acknowledge packets 1.1.2 NGIMS Header Contents of the NGIMS header are shown below. Table 2 - NGIMS Header Field #bits Description vSSOffset 7 Indicates the offset to the first subscan within the packet. A value of zero means the first subscan begins at the first word of the Science section (the word immediately following the NGIMS header). spares 9 16 (Total) Format: 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 vSSOffset spare 1.1.3 Science The Science section of TM packets consists of 1616 bits: - Subscan Header - Hi Sens Counters - Lo Sens Counters - Config Words in Round Robin mode (or Flat Indexes in Flat Table mode) - Mux data - Last Command - Spares 1.1.3.1 Synch Word A Synch Word with the value EB90h is the first word in every Subscan in TM. 1.1.3.2 Orphan Header When the Synch Word would have been established as the last word in the Science section, that Subscan will instead be deferred to the next TM packet (the Subscan index vSSIndex on the next TM packet will be zero), and the location where the Synch Word would have been placed (the last word in the Science section) will be set to 146Fh. Counters. There are two counters: Counter1 - 15*18 bits Counter2 - 15*18 bits 1.1.3.4 Serial Data Transmission The Scan Segment of each packet is filled up serially with Subscan data, and Subscan sizes are such that they don't fit integrally into the packet (see §1.2), so any particular packet will contain at least one partial Subscan. The Subscan Offset field in the NGIMS header indicates the offset to the first complete subscan within the packet. 1.1.3.5 Memory Dumps When the AppProcID field indicates Dump Packet (see 1.1.1), the Scan segment contains Dump Words & metadata. The Data section holds requested memory contents and is 22 bytes (111 words) long. 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 TC Serial Number Source Chip spare StartAddress Length Data (222 bytes) MET MSBs (2 bytes) MET LSBs (2 bytes) Spare (4 bytes) Total Pkt Length (bytes) = 6 (CCSDS) + 8 (Dump hdr) + 222 + 4 + 4 = 6+ 8 + 222 + 4 + 4 = 244 Source: 0 = RAM, 2 = EERPROM, 3=IORAM Note that in non-standby mode, dump packets are only transmitted at a rate of one per scan. 1.1.4 Science Metadata Each IP is described by a word that specifies Mass, Freq, and ConfigTable number. 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 Mass Freq Config Tbl Each Scan should have metadata: Field #bits Description Subscan 5 0..31 Scan Mode 3 0=Init, 1=CS, 2=OS, 3=IM, 4=PM, 5=AS, 6=Flat (CS=Closed Source, OS=Open Source, IM=Ion Mode, PM=Programmed Masses, AS=Adaptive Scanning) 1.1.5 Mux Data Mux data consists of one 12-bit Mux value for every IP in the Subscan, plus a 7-bit MuxID as follows: First, 15 words with an Amux Value and 4 ID LSBs: Amux ID LSBs (1) Amux Value (1) Amux ID LSBs (2) Amux Value (2) ... Amux ID LSBs (15) Amux Value (15) Followed by the 15 MSB fields (3 bits each): MSBs 1 MSBs 2 MSBs 3 MSBs 4 MSBs 5 sp MSBs 6 MSBs 7 MSBs 8 MSBs 9 MSBs 10 sp MSBs 11 MSBs 12 MSBs 13 MSBs 14 MSBs 15 sp 1.1.6 Last Command The software is being designed such that it executes only one command per Subscan. Thus, if each Subscan TM block holds information regarding the last command that was executed, the Subscan data "stands alone" (that is, one can analyze the Subscan data because it also has the last command). LastCmd - 48 bits (16 bit OpCode word, 16 bit Data, 16 bit S/N). Refer to GSFC/NGIMS-FSW-05, CONTOUR/NGIMS Commanding. The LastCmd word is used for both Stored Commands and Telecommands. The Checksum portion of the command can be set aside as a spare; and another bit is added (we have chosen bit 8) for Valid, indicating if the command was acted upon or rejected. 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 VC sp sp CV sp OpCode Data Word 1 Dest SN Stored Commands are maintained by the S/C C&DH and transmitted to the NGIMS FC as TCs. 1.1.7 HK Certain signals are sent with every packet, and others are multiplexed. The table below describes the fields and their offset from the start of the HK section. Sent every packet: Ref# Field Offset Bits Notes HKF-01 Command Process Count 0 0..15 Command Process Count HKF-02 Command Execute Count 1 0..15 Command Execute Count HKF-03 vNbrTCs 2 0..15 number of TCs received since turn-on, mod 64k HKF-04 vNbrNacks 3 0..15 TCs rejected since turn-on, mod 64k HKF-05 ESW 1 - General Status 4 0..15 see section 2 HKF-06 ESW 2 - Subsystem Fail 5 0..15 see section 2 HKF-07 ESW 4 - General Err. Status 6 0..15 see section 2 HKF-08 ESW 7 - CDS Error Status 7 0..15 see section 2 HKF-09 MET MSBs 8 0..15 Combine with HKF-21 HKF-10 ESW 15 - vSubscan 9 0..15 Scan status HKF-11 ESW 16 - vSSIndex, vScanMode 10 0..15 Scan status HKF-12 spare 11 0..0 not used HKF-13 spare 11 1..1 not used HKF-14 spare 11 2..2 not used HKF-15 spare 11 3..3 not used HKF-16 vSTMCounter 11 4..11 number of STMs rcvd since turn-on, mod 255 HKF-17 vMplxID 11 12..15 Multiplex ID HKF-18 Multiplex_Data 12 0..31 (see below) HKF-19 VdacORide 14 1..29 one bit for each DAC HKF-20 Spare_0 14 29..31 spare HKF-21 MET LSBs 16 0..15 Combine with HKF-09 Multiplexed signals require an ID as metadata: Ref# Field bits Notes HKF-22 MplxID 4 indicates which of the below blocks the multiplexed TM section contains HKF-23 The 32-bit multiplexed block: ID signals bits Notes 0 ESW 9, 10 - TZero 1 ESW 11,12 - MET 32 see section 2 2 ESW 13 - SCM, ESW 14 - LOS 32 see section 2 3 DCON1 & DCON2 16, 16 see section 2 4 Config Table IDs, 0 & 1 16, 16 Digital Control words 5 Config Table IDs, 2 & 3 16, 16 (4 tables total) 6 RFMon Avg 0, RFMon Avg 1 16, 16 7 RFMon Avg 2, Temp Avg RF, 16, 16 (0) = HF, (1)=MF 8 Temp Avg Non RF, spare 16, 16 (2)=LF 9..15 7 spares, 32 bits each Total size of HK is 230 + 4 + 32 (+8 padding) = 272 bits (17 words). Note that there are enough spares to place all valve statuses (both commanded and readout positions) in the TM DCon word. 1.2 Placing scans into packets. With the number of bits now better estimated, we can fill in more of Table 1 - Table 1-A - TM Packet Bit-count Block #bits Type A 48 CCSDS Pri Hdr B 16 NGIMS Hdr C 540 Science D 255 Sci Metadata E 285 Mux F 96 Last TC, Last SC G 272 HK The CONTOUR CDS accepts packets of size 244 bytes (1952 bits). The format of a NGIMS packet actually has Science, Science Metadata, Mux and Last Cmd all in one segment (Scan Segment, shared with Dump Data). Subtracting the "non-scan" segment sizes from 1952 bits (recall that 244 bytes is the Packet Size), the scan segment is 1616 bits in size: #bits Type 48 CCSDS Pri Hdr 16 NGIMS Hdr 1616 Scan or Dump Data 272 HK 1.3 Detailed Scan Segment Format Each complete Subscan will be in the form shown below (may spill over into next TM packet). Science: Subscan Header - words 0..3 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 sp Synch MET MSBs MET LSBs Subscan# ScanMode Fractional MET LSBs Words 4..18: Counter2 - 16 LSBs Counter2 Word 1, LSBs ... Counter2 Word 15, LSBs Word 19 - has17th bit for Counter2 words, one per IP: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 sp Word 20 - has 18th bit for Counter2 words, one per IP: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 sp Words 21..35: Counter1 - 16 LSBs Counter1 Word 1, LSBs ... Counter1 Word 15, LSBs Word 36 - has17th bit for Counter1 words, one per IP: sp 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 Word 37 - has 18th bit for Counter1 words, one per IP: sp 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 Words 38..52 - Config Words for 15 IPs: (IP 1) Mass Freq Config (IP 2) Mass Freq Config ... (IP 15) Mass Freq Config Word 53: Sequence Index - Number of Subscans since turn-on, modulo 65k SeqIndex Words 54..71: Muxes Mux, MuxID, Mux, MuxID... Words 72..74 - Last Command: VC Valid sp sp OpCode Data Word 1 Dest SN or TimeTag Word 75: FSW Version Number Word 76: FSW Checksum Word 77: spare Scan Mode Subscan Table Index Word 78: spare Subscan Number Word 79: spare 1.4 TM Rate With the formatting done in 1.3, we see a single subscan consists of 1280 bits (80 words) including all subscan metadata. Thus ~1.26 Subscans can fit into the 1616-bit Scan segment of a packet. The TM Rate (bits per second) is thus as follows (doesn't include Acknowledge packets): For a 33 ms IP: # subscans/s = 15 IPs/subscan * 0.033s/IP = 2.02 2.02 subscans/s ( 1.26 Subscans/packet = 1.6 packets/s = 3.13 K b/s For a 22 ms IP: # subscans/s = 15 IPs/subscan * .022s/IP = 3.03 3.03 subscans/s ( 1.26 Subscans/packet = 2.4 packets/s = 4.69 K b/s 2. Non-Packetized TM (ESWs) There are 91 DACs plus 16 FSW Status ESWs, making 107 ESWs. These are sent on the NPTM channel as well as in a block in Science TM. Only 8 ESWs can be transmitted at a time, so they are multiplexed by forming groups using the following scheme: * 3 words -- ESW 1 & 2, and Imon (Imon is ESW #TBD) are always sent (NPTM words 2..4) * NPTM word 1 contains the ESW "Group Number" (0..TBD) plus spare bits. * NPTM Words 5..8 contain 4 ESWs as indicated by ESW Group number. This is illustrated in the following table. In effect, ESW 1 & 2 and Imon are included in all Groups. Table 2-1 Non-Packetized TM NPTM# Definition 0 Group, spare bits 1 ESW1 2 ESW2 3 Imon 4 ESWx 5 ESWx 6 ESWx 7 ESWx This scheme causes the full set of TBD ESWs to be sent every TBD seconds (NPTM is collected at 1 Hz by the S/C). The following table shows the association of ESW Groups. In the table below we are essentially considering Muxes to be ESWs 17..107. Table 2-2 ESW Groups ESW#s Meaning Group From To 0 3 6 Subsys Fail Latch General Error Stat TC Ack/Nack BIT Failure 1 7 10 User Exception SCP Status Tzero MSBs Tzero LSBs 2 11 14 MET MSBs MET LSBs ESW13 ESW14 3 15 18 Subscan# SSIndex, ScanMode Mux #1 Mux #2 4 19 22 Mux #3 Mux #4 Mux #5 Mux #6 5 23 26 Mux #7 Mux #8 Mux #9 Mux #10 6 27 30 Mux #11 12 13 14 7 31 34 Mux #15 16 17 18 8 35 38 Mux #19 20 21 22 9 39 42 Mux #23 24 25 26 10 43 46 Mux #27 28 29 30 11 47 50 Mux #31 32 33 34 12 51 54 Mux #35 36 37 38 13 55 58 Mux #39 40 41 42 14 59 62 Mux #43 44 45 46 15 63 66 Mux #47 48 49 50 16 67 70 Mux #51 52 53 54 17 71 74 Mux #55 56 57 58 18 75 78 Mux #59 60 61 62 19 79 82 Mux #63 64 65 66 20 83 86 Mux #67 68 69 70 21 87 90 Mux #71 72 73 74 22 91 94 Mux #75 76 77 78 23 95 98 Mux #79 80 81 82 24 99 102 Mux #83 84 85 86 25 103 106 Mux #87 88 89 90 26 107 spares Mux #91 spare Exception ID TC Execute Cnt The assignment of ESWs is as follows: Table 2-3 ESWs ESW Word Cassini Notes 1 General Status Y 2 Subsystem Fail Y Set bits indicate error 3 Subsystem Fail Latch Y same format as non-latched 4 General Error Status Y Set bits indicate error 5 Ack/Nack Y Nbr acks 8 bits; Nbr Nacks 8 bits 6 BIT Failure Y Set bits indicate error 7 CDS Error Status new (also has latched bits for all error flags) 8 SCP Status new (spare) 9, 10 TZero new Time to closest approach 11, 12 MET new Mission Elapsed Time 13 SCM new S/C Mode and instrument configuration 14 LOS new Line-of-sight angle (3 bits) 15, 16 Scan Status new Information about scanning 17-TBD Engineering (TBD Muxes) Color codes in this section: TEAL signifies new signal or change from Cassini. BLUE is used for notes. VIOLET indicates spares. The non-Mux ESWs are defined in the paragraphs that follow. There is substantial re-use from Cassini. ESW 1 - General Status Use Cassini format as baseline. "Latched" signals remain set forever after becoming set. Bit(s) Definition Notes MSB 0 CPU Idle Counter "Alive" counter, 0 | 1 (changed from 4 bits in Cassini) 1 EEPROM Boot Set when an EEPROM boot was done. 2 ALF Boot Spare 3 1553 Int Toggle 1553 Interrupt Toggle 4 Subscan Toggle Toggles each time a scan is performed 5 All Systems Go Current status of "All Systems" for Instrument 6 All Sys. Go Latched Latched status of "All Systems" - never resets until reboot. 7 vPriDet Spare 8 Init Mode Signifies that instrument is in Initial mode (follows power-on or reboot, or receipt of {InitMode} command) 9 Standby Mode Signifies that instrument is in Standby mode as result of receiving a {Standby} TC 10 vNVSafemode Non-volatile safemode 11 TC Toggle Toggles each time a TC is received 12 TGO Toggle Moved from General Error Status 13 vBlindMode Ignore TCs 14 System Initialized LSB 15 vFlatMode Signifies system is performing Flat Table scans ESW 2 - Subsystem Fail Bit Signal Name Description MSB 0 vFatalError Set when any of the fatal error conditions occur. Causes sounding of audible alarm in breadboard configuration. 1 vTMBuffOvflw Set when the allotted memory buffer area for TM packets would have overflowed. 2 vUserException An exception occurred. The User Exception number is reported in telemetry (ESW 7). 3 vMetLate Set when FSW detects that the S/C has sent the Mode & Time message too late (later than 1.125s) 4 vMetReverseJump Set when FSW detects that the MET received from the S/C is less than the most recently received MET. 5 vMetSame Set when FSW detects that the MET received from the S/C is equal to the most recently received MET. 6 vUSeqIntLate Set when Useq misses an external interrupt 7 vUSeqiOffline Set when FSW detects that MET from the S/C was not received 8 vUSeqError Set when any Useq error is detected. 9 v1750ME Set when the 1750 Machine Error interrupt occurs 10 vCmdBufferOverflw Set when too many commands have been sent too quickly and the internal FSW command buffer has overflowed. 11 vPromChecksumFail Bootstrap has reported that the checksum on PROM has failed. 12 vMET_In_TM_Fail Set when FSW detects that the MET it is packing into the subscan portion of a TM packet is less than the previously packed MET. 13 vMetForwardJump Set when FSW detects that the MET received from the S/C is greater than 1 second more than the most recently received MET. 14 vRteError unused LSB 15 vInstrumBitFail Set when any of the tests in the bootstrap BIT fail ESW 3 - Subsystem Fail Latch Generated by Oring ESW3 with ESW2 every time any signal in ESW2 becomes set. ESW 4 - General Error Status Use Cassini format as baseline. Bit(s) Definition MSB 0 TGO Detect Set if bootstrap detects that reboot was a result of TGO timer expiration. 1 Exc. No Handler Exception occurred, no Ada handler to process it. (moved from General Status) 2 IC Error (Wayward IC) 3 Spare 4-7 Submodule ID Programmer use 8-9 Trap Flag Programmer use LSB 10-15 Module ID Programmer use ESW 5 - TC Ack/Nack Upper byte: vNbrNacks (truncated to 8 bits) Lower byte: vNbrTCs (truncated to 8 bits) ESW 6 - BIT Failure Bit Signal MSB 0 1750 BIT Fail 1 RAM BIT Fail 2 ROM BIT Fail 3 IORAM BIT Fail 4 EEPROM 1 Fail 5 EEPROM 2 Fail 6 CDSo BIT Fail 7 CDSi BIT Fail 8 Spare 9 Bus 1553 BIT Fail 10 Spare 11 Spare 12 Spare 13 Spare 14 Spare LSB 15 Spare ESW 7 - Most Recent User Exception Code (16 bits) Code Hex Module Procedure Type 1 1 Robin_Scanning Next_Subscan other 11 B CmdDist Execute_Core other 12 C Flat_Scanning Flat_EEPROM_Address constraint 13 D Flat_Scanning Flat_EEPROM_Address other 14 E Flat_Scanning Increment_Flat_Index constraint 15 F Flat_Scanning Increment_Flat_Index other 16 10 Flat_Scanning Retrieve_Flat_IP constraint 17 11 Flat_Scanning Retrieve_Flat_IP other 18 12 qp_transforms Mass_Transform constraint 19 13 qp_transforms Mass_Transform other 20 14 UseqDrvr Load_IP constraint 21 15 UseqDrvr Load_IP other 34 22 UseqDrvr Useq_Computations_Type constraint 35 23 UseqDrvr Useq_Computations_Type other 40 UseqDrvr EI_Handler constraint 41 UseqDrvr EI_Handler other 43 NGIMS Main_Start tasking 44 NGIMS Main_Start other 45 Sc_Health Analyze_MET constraint 46 Sc_Health Analyze_MET other 50 EngEsa Dcon other 50 NGIMS Main other 51 ScanC Robin_Subscan other 52 ScanC Next_IP other 53 Tartan_Workaround Monitor_Configuration_Word constraint 54 Tartan_Workaround Monitor_Configuration_Word other ESW 8 - SCP Status ESW 9 .. 12 -- Tzero & MET ESW Signal bits 9, 10 vTZero 32 11, 12 vMETc 32 Mission Elapsed Time ESW 13 - SC Mode and Instrument Config Bit Signal Name Description MSB 0 vSCM Set means Encounter - used for AutoStart processing 1 vALFBootMode not used 2 vEEPROMBootMode not used 3 vBootMode not used 4 vTablesCopied Set means an EEPROM Tablecopy Boot was performed 5 vTablesUpdated {TableUpdate} (AMB transfer from EEPROM to RAM) was performed 6 spare 7 spare 8 spare 9 spare 10 spare 11 spare 12 spare 13 spare 14 spare LSB 15 spare ESW 14 - Line Of Sight Angle 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 vLOS sp sp sp sp sp sp sp sp sp sp sp sp 0 = not valid 1 = 0.0 degrees 2 = 0.5 degrees 3 = 2.5 degrees 4 = 6.0 degrees ESW 15, 16 -- Scan Status v3.6.0: 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 vSubscan Vssindex vScanMode spares v3.7+: Vssindex vScanMode spares 3. Acknowledge Packets Each time a valid command is executed, the Command Executed counter increments and an Acknowledge packet is transmitted. Acknowledge packets have an Application/Process ID of 482h and contain up to eight "Command Echo" blocks (3-word copies of the executed command). The format is: MET (32 bits) vNbrTCs (16 bits) vNbrNacks (16 bits) Command_Count (16 bits) Command Echoes An OpCode of zero indicates the end of the Command Echo block. CCSDS HEADER (App/Proc ID=482) MET MSBs MET LSBs vNbrTCs vNbrNacks Command_Count vNbrTCs vNbrTCs VC Valid sp sp OpCode Data Word 1 Dest SN or TimeTag VC Valid sp sp OpCode Data Word 1 Dest SN or TimeTag VC Valid sp sp OpCode Data Word 1 Dest SN or TimeTag VC Valid sp sp OpCode Data Word 1 Dest SN or TimeTag VC Valid sp sp OpCode Data Word 1 Dest SN or TimeTag VC Valid sp sp OpCode Data Word 1 Dest SN or TimeTag VC Valid sp sp OpCode Data Word 1 Dest SN or TimeTag VC Valid sp sp OpCode Data Word 1 Dest SN or TimeTag 1