5 releases

0.1.4 Dec 14, 2023
0.1.3 Dec 10, 2023
0.1.2 Sep 24, 2023
0.1.1 Aug 21, 2023
0.1.0 Aug 18, 2023

#2 in #astrodynamics

MIT license

21KB
421 lines

parse-tle

License:MIT

TLE parser in Rust

Install

Command Line:

cargo install parse-tle

or add to your cargo.toml:

[dependencies]
parse-tle = "0.1.3"

Usage

API


CLI

To build:

cargo build --release

To run:

./target/release/parse_tle.exe -h

Which generates the help page:

Parse two line element set

Usage: parse_tle.exe [OPTIONS] [TWO_LINE_ELEMENT] [COMMAND]

Commands:
  celestrak  Query celestrak for tles
  help       Print this message or the help of the given subcommand(s)

Arguments:
  [TWO_LINE_ELEMENT]  Two line element directly in cli

Options:
  -v, --verbose                    Verbose printing
  -f, --file-path <FILE_PATH>      path to .txt file holding tle information
  -o, --output-path <OUTPUT_PATH>  Path to write json formatted output
  -h, --help                       Print help
  -V, --version                    Print version

To run an example of reading from file:

./target/release/parse_tle.exe -f ./examples/starlink_1007_tle.txt
STARLINK-1007
Catalog #: 44713U
Intl Desig: 19074A
Epoch: 2023-11-05T00:04:07 UTC
Mean Motion: 15.06420179
Mean Motion prime: 0.00013448
Mean Motion prime 2: 0
Radiation Pressure: 91.946
Inclination: 53.0548
Raan: 292.5095
Eccentricity: 0.0001422
Argument of Perigee: 105.9473
Mean Anomaly: 54.1673
Revolution #: 24322

Dependencies

~9–24MB
~371K SLoC