Tool: decode_ldp

Description

This tool decodes one or more Swift large data products from a stream of packets and places the results in one or more files.

Option Summary

OptionArgument TypeDefault Value
-checksum Boolean true
-extra_header_size Integer 0
-format_check Boolean false
-header_strip Boolean true
-infile String -
-outfile String -
-split_output_files Boolean false

Only the initial unique characters of each option are significant. Each option must be followed by an argument of the given type. Boolean "true" and "false" are indicated with "y" and "n" respectively. A boolean option without a value is assumed to be "true". For filename arguments, "-" means either stdin or stdout as appropriate. Each option is described in detail below.

Parameters

checksum Boolean (default = true)
Do the packets in the input file contain checksums? Checksums are optional according to the LDP specification, but both the XRT and BAT currently plan to use them.

extra_header_size Integer (default = 0)
This is the size of the non-standard part of the LDP header to be stripped from the output if the header_strip parameter is set.

format_check Boolean (default = false)
If set, the program will do a number of detailed format checks on the incoming LDP packets. This option assumes that there is only one LDP (i.e. one APID and product number) in the incoming data [check this! - also add checksum verification to LDPChecker].

header_strip Boolean (default = true)
If set, the program will strip off the standard LDP header plus the number of bytes specified by the extra_header_size parameter before writing the output data. You might choose this option if you are running decode_ldp on the output from encode_ldp. That programs prepends the standard part of the LDP header to the original data, so this option would restore the original file extra_header_bytes=0.

infile String (default = -)
This is the file containing the LDP packets to be decoded.

outfile String (default = -)
This is the name of the file where the decoded results will be written. See the "split_output_files" parameter for more information.

split_output_files Boolean (default = false)
If set and the input data contain more than one LDP, then each LDP will go to a different file. The name of each file will be the file specified in the output parameter with the APID and product number appended. Note this option is ignored if the output is being sent to stdout (i.e. outfile="-").