Skip to main content

Struct Extract Interface

Warning: This page is a Work In Progress

For projects that use telemetry data files (files of packets), XINA Mining (struct_mining) and Export (struct_export) delegates the decoding and conversion of mnemonic data to a mission specific tool, which we will reference as struct_extract. This tool should implement the following interface for seamless integration with XINA.

Environment
  • By default, a cmdline app with the name of struct_extract is executed and should be available from the PATH env of the user that executes the Mining Task.
  • The app should be runnable on Ubuntu 22.04.
  • If possible, the app should be self-contained and not have any external dependencies. However, the environment can be configured as needed if dependencies are required.
Input

struct_extract should accept a single argument which is the path to a JSON file. The JSON file defines all of the parameters needed to extract the desired mnemonic data. A JSON file is used to allow for flexibility without XINA being aware of the app's specific cmdline options. Mission specific keys can be added as needed. The following table defines the standard parameters:

Note: If raw, eng, or sci are not provided, all mnemonics should be extracted as "science".

Key Required Description
dir The path to the dir containing the archive file and any ancillary files needed for processing
dest The path to the dir that all output (e.g. xbin file) should be placed
mission TBC: The mission which may be needed to determine how the archive file is processed
model TBC: The mission's model which may be needed to determine how the archive file is processed
raw The mnemonic IDs of the mnemonics that should be extracted and output, unconverted
eng The mnemonic IDs of the mnemonics that should be extracted and output with the engineering conversion applied
sci The mnemonic IDs of the mnemonics that should be extracted and output with the science conversion applied
time_mode For projects that support it, defines which time source should be used when timestamping the mnemonic data. Either "pkt" or "grt" (ground receipt time). If not provided, it should default to packet time.

Example JSON configuration file:

{
}
Output

The output of the tool should be a xbin file. XINA's tools will then process the xbin file to produce the required mine or export products.

For mission specific data, struct_extract should output using one of the following options [TBD]:

  • Self generate the data file and corresponding XINA JSON import file. XINA will take care of importing the data.
  • Output the data into the xbin file. XINA will take care of the rest.