140 likes | 289 Views
Gamma-ray Large Area Space Telescope. GLAST Large Area Telescope Instrument Flight Software Flight Unit Design Review 16 September 2004 Telecommand and Telemetry Data Dictionary Services Sergio Maldonado Stanford Linear Accelerator Center smaldona@slac.stanford.edu 650-926-4355.
E N D
Gamma-ray Large Area Space Telescope GLAST Large Area Telescope Instrument Flight Software Flight Unit Design Review 16 September 2004 Telecommand and Telemetry Data Dictionary Services Sergio Maldonado Stanford Linear Accelerator Center smaldona@slac.stanford.edu 650-926-4355
Telecommand and Telemetry Data Dictionary:Requirements • Flight Software General Requirements (2 new of 198): • LAT Housekeeping Data to SC (5.3.5.1.1) • The SIU FSW shall provide housekeeping data to the SC, via the CTDB, on a schedule defined in GLAST 1553 Bus Protocol ICD. • Diagnostic Telemetry (5.3.5.2) • The FSW shall send diagnostic telemetry messages, as defined in the LAT Flight Software Telecommand and Telemetry Formats document, to the SC via the CTDB. Diagnostic telemetry is sent in response to a command and downlinked immediately while the SC in contact with the ground. If not in contact, the telemetry is downlinked at the next contact. • Alert Telemetry (5.3.5.3) • The FSW shall send alert telemetry messages, as defined in the LAT Flight Software Telecommand and Telemetry Formats document, to the SC via the CTDB. Alert telemetry is generated internally by the LAT and sent to the SC to be downlinked immediately. If not in contact, the SC recognizes the telemetry as Alert and activates a TDRSS link for immediate downlink. • Flight Software General Requirements (derived): • The Telecommand and Telemetry Data Dictionary function shall generate a data dictionary defining the full set of telecommands and telemetry associated with the instrument FSW component of the mission. This data dictionary shall be provided in a format that can be processed to produce ITOS, or other representations of the data. Flight Unit Peer Review - Telecommands and Telemetry
Telecommands and Telemetry Data Dictionary:The Issue • Constraints • During the mission, MOC will use the Integrated Test and Operations System (ITOS) • During satellite integration, Spectrum Astro will use an ITOS compatible system • LAT FSW must produce a telecommand and telemetry data dictionary • LAT FSW must produce code corresponding to the telecommand and telemetry data dictionary document • This code defines all types of commands consumed and telemetry packets issued by FSW tasks: • commands to tasks • housekeeping telemetry • alert telemetry • diagnostic telemetry • Many products, but all derived from the same basic information • A maintenance nightmare, if all products are maintained independently • The FSW solution: the LCAT (LAT Command and Telemetry) tool Flight Unit Peer Review - Telecommands and Telemetry
The CCSDS Packet Format • LCAT doesn’t concern itself with details of the 1553 bus protocol and CCSDS packet assembly, which are handled by the CTDB and CCSDS FSW packages, respectively. However, it’s worth pointing out a few details about the CCSDS format for context. • CCSDS command and telemetry packets have a header, a payload, and a checksum. • The header contains: • Fields that define the packet type, length, sequence order and count, timestamps, etc. • An APID that identifies destination tasks (in the case of telecommands) or source tasks (for telemetry) for routing purposes • For telecommand packets, a function code that identifies a routine to be executed by a destination task • Payloads can be variable length. Payloads can be segmented into bitfields or fields. • A checksum. • Using LCAT, developers: • Define the payload structure of the telecommand packets received by or telemetry packets issued by their subsystems. • Define the APID (and function code) to be included in the packet header. Flight Unit Peer Review - Telecommands and Telemetry
CCSDS Payloads: Field Data Typesand Constraints • Command and telemetry fields can have one of 7 data types: • * (unsigned) char * (unsigned) short • * (unsigned) int * (unsigned) long long • * float * double • * string • Values in some fields should naturally be constrained or converted. • For instance, temperature telemetry data may be compared against thresholds -- green (safe), yellow (watch), and red (warning) -- and should be reported in telemetry accordingly. • Values for these thresholds (limits) must be specified. • Command field constraints: • Some telecommand field data is enumerated • Some fields should be restricted to an accepted range of values • Telemetry field constraints: • Limit sets: some values in telemetry fields should be mapped to green, yellow, and red threshold limits • Telemetry fields can also be converted using discrete and analog conversion rules • Telemetry fields may have engineering units (e.g., °C) that must be identified Flight Unit Peer Review - Telecommands and Telemetry
Telecommands and Telemetry Data Dictionary:The Design • A tools-based approach • Define a private, XML-based representation of this information • Provide an editor tool to manipulate the XML files • Provide extraction tools to produce • ITOS database interchange records • Telecommand and telemetry web pages and book • Source code for inclusion by FSW applications • Integration into developer’s environment • Any package defining telecommands or telemetry will have a /cat directory • Developer will create package-specific telecommand / telemetry XML files in /cat • XML files are code managed under our present system • Deriving source code files from XML files will be built into our build scheme • ITOS, books and web pages are created by processing /cat directories in all packages Flight Unit Peer Review - Telecommands and Telemetry
ITOS DatabaseInterchange Records Telecommands and Telemetry Data Dictionary:Workflow Tools Products pkgA Development Area /<pkgA> /cat <pkgA>.catc Editing /Validation /src GenerateSource pkgB Development Area /<pkgB> /cat <pkgB>.catc <pkgB>.[ch] /src GenerateITOS pkgC Development Area /<pkgC> /cat <pkgC>.catc GenerateBook / Web Documentation /src Flight Unit Peer Review - Telecommands and Telemetry
Telecommands and Telemetry:The LCAT Tool • LCAT, the “LAT Command and Telemetry” definition tool • LCAT allows developers to: • 1) Create a centralized XML representation of all commands and telemetry associated with their software subsystems • 2) Generate two general categories of code: • Source code • C structures corresponding to each command and telemetry packet, each field within those packets, and all constraints on those fields • C structures used by the ITC (inter-task communications) system to register APIDs, function codes, and callback functions • Callback function prototypes and function stubs for commands • Database interchange records for ground-based communications systems • For each command and each telemetry message, database records used by the GLAST mission operations folks • Equivalent records used by the Spacecraft manufacturer to test LAT-Spacecraft integration • 3) Generate command and telemetry documentation • 4) Manage all these products centrally with a GUI tool (next slide) • 5) Automate source and interchange code production with a command line utility Flight Unit Peer Review - Telecommands and Telemetry
The LCAT GUI Flight Unit Peer Review - Telecommands and Telemetry
LCAT C&T Definitions: Product Hierarchy • The primary storage mechanism for LCAT definitions are XML files. • All information is organized into a strict hierarchy, which is enforced by the application’s XML parser and the associated Document Type Definition (DTD) file. • A single top level “container” file holds a reference to each definition file and allows for the sharing or reuse of data content between them. • Command and telemetry definitions are stored in multiple “definition" files. Once created, these definition files can be imported into other command and telemetry containers/projects: • Fields (cmd and tlm) • Bitfields (cmd and tlm) • Structs (cmd and tlm) • Packets (cmd and tlm) • Ranges (cmd only) • Enumerations • Discrete Conversions • Analog Conversions • Limit Sets Flight Unit Peer Review - Telecommands and Telemetry
Production of ITOS and AstroRT by LCAT • LCAT outputs ITOS database interchange records as character-delimited dbx files, one file for commands and one file for telemetry. • These interchange files are used to populate the databases that support the ITOS and AstroRT systems. • ITOS interchange format: • The cmd_itos.dbx file contains a record that defines the subsystem, and records for each command definition and command enumeration definition. • The tlm_itos.dbx file contains a record for the subsystem definition, and records for each telemetry definition, each conversion definition (discrete and analog), and each limit definition. • AstroRT interchange format: • The dbx files are nearly identical to the ITOS versions. However, they do not contain records to define subsystems. • AstroRT records are not generated by the LCAT tool; the AstroRT software converts from ITOS • Individual programmers produce database interchange records for the subsystems they write. • Since APIDs do not overlap, the whole set of records is imported into ITOS or AstroRT to create the master command and telemetry database. Flight Unit Peer Review - Telecommands and Telemetry
LCAT Command Line Tool • A command-line version of the tool is provided for build automation. • Command-line version capabilities: • Validate XML container files against the DTD* Generate C source* Generate ITOS* Print dependency list for container* Print xml dump of the container including all referenced definition files Flight Unit Peer Review - Telecommands and Telemetry
LCAT Development Environment • For the full LCAT GUI: • Python 2.2.2 or later • PyXML version 0.8.1 or later • 4Suite version 1.0a3 or later • Qt/X11 GPL/Non-Commercial version 3.1.1 or later – A platform independent C++ application development framework • QScintilla version 1.53-x11-gpl or later – A port to Qt of the Scintilla C++ editor class • SIP version x11-gpl-3.6 or later -- Python bindings for C++ • PyQt gpl version 3.6 or later – A python interface to Qt libraries Flight Unit Peer Review - Telecommands and Telemetry
Telecommands and Telemetry Data Dictionary:Testing • By and large, this function will be tested in use, through verification and inspection: • As FSW code packages that consume telecommands and return telemetry are refined and completed, developers will check that valid source code was generated by the T&T database tool set. • As FSW hardware subsystems are refined and completed, engineers will send telecommands generated using the T&T tool set and verify in action whether the appropriate telecommands are sent and correct telemetry is received. • As consumers such as the ISIS and the ISOC utilize the data dictionary, they will validate that the correct representation of T&T data has been delivered. Flight Unit Peer Review - Telecommands and Telemetry