SPICEApplications.jl
The SPICEApplications
module is not included within SPICE
. To access the functions documented on this page, install SPICEApplications
using Julia's package manager: Pkg.install("SPICEApplications")
.
The JPL SPICE Toolkit provides executables for interacting with SPICE kernels, such as mkspk
, brief
, and others. SPICEApplications.jl
provides idiomatic Julia interfaces to these executables, which themselves are packaged by CSPICE_jll.jl
.
Usage
Each executable can be called through its corresponding function without arguments, or programatically using function arguments. For example, the SPICE Toolkit's BRIEF
program prints the description of a provided kernel. When the brief
executable is called without arguments, it prints its "help" text; this can be replicated by calling SPICEApplications.brief()
without arguments. Alternatively, you can pass the kernel that you want to inspect as a positional argument: brief(kernel_file)
.
All SPICE Toolkit executables are documented within the SPICE Toolkit Documentation.
julia> using SPICEApplications
julia> kernel = download("https://naif.jpl.nasa.gov/pub/naif/CASSINI/kernels/spk/000202R_SK_V1P32_V2P12.bsp")
"/tmp/jl_rejuxwlcdC"
julia> brief(kernel);
BRIEF -- Version 4.1.0, September 17, 2021 -- Toolkit Version N0067 Summary for: /tmp/jl_rejuxwlcdC Body: CASSINI (-82) Start of Interval (ET) End of Interval (ET) ----------------------------- ----------------------------- 1998 MAY 28 21:23:03.184 1999 JUL 06 16:01:04.183
Example
For a concrete usage example, see how SPICEApplications
is used to generate docstrings for SPICEKernels.jl
.
Reference
SPICEApplications.SPICEApplications
— ModuleCall all SPICE Utilities from within Julia!
This package is not affiliated with or endorsed by NASA, JPL, Caltech, or any other organization! This is an independently written package by an astrodynamics hobbyist.
Extended help
README
SPICEApplications
Generate ephemeris kernel files using NASA JPL's SPICEApplications
program, all from within Julia!
Installation
Choose one of the following two lines!
import Pkg; Pkg.add("SPICEApplications");
]add SPICEApplications # in Julia's REPL
Documentation
The documentation for SPICEApplications.jl
is hosted within the SPICE.jl
documentation.
Credits
NASA JPL developed and maintains the NAIF SPICE Toolkit, including SPICEApplications
. Helge Eichhorn developed and maintains SPICE.jl
, as well as the Julia wrappers around the SPICE Toolkit.
License
Exports
brief
chronos
ckbrief
commnt
dskbrief
dskexp
frmdiff
inspekt
mkdsk
mkspk
msopck
spacit
spkdiff
spkmerge
tobin
toxfr
Imports
Base
Core
DocStringExtensions
SPICEApplications.brief
— Methodbrief(
file;
tabular,
single,
centers,
utc,
utcdoy,
etsec,
sec,
min,
hour,
day,
bytime,
bycoverage,
byid,
byname,
body,
center,
at,
from,
to,
listfile,
help,
version,
stdout,
stderr,
stdin,
append,
wait
)
BRIEF is a command-line utility program that displays a contents and time coverage summary for one or more binary SPK or binary PCK files.
Extended Help
All descriptions below were manually parsed from the commandline program's help/usage output.
Argument | Equivalent | Description |
---|---|---|
tabular | -t | Display summary in a tabular format |
single | -a | Treat all files as a single file |
centers | -c | Displays centers of motion/relative-to frames |
utc | -utc | Display times in UTC calendar date format (needs LSK) |
utcdoy | -utcdoy | Display times in UTC day-of-year format (needs LSK) |
etsec | -etsec | Display times as ET seconds past J2000 |
sec | -sec | Display times "rounded inward" to second |
min | -min | Display times "rounded inward" to minute |
hour | -hour | Display times "rounded inward" to hour |
day | -day | Display times "rounded inward" to day |
bytime | -s | Display summary sorted by start time for each body/frame |
bycoverage | -g | Display summary grouped by coverage |
byid | -n | Display bodies/frames using numeric id-codes |
byname | -o | Display summary ordered by body/frame name |
body | -sb[bod] | Display summary for body [bod] |
center | -sc[cen] | Display summary for center of motion/relative-to frame [cen] |
at | -at [time] | Display summary if coverage contains epoch [time] |
from | -from [beg] | Display summary if coverage contains interval [beg]:[end] |
to | -to [end] | Display summary if coverage contains interval [beg]:[end] |
listfile | -f [list] | Summarize kernels listed in the [list] file |
help | -h | Display help |
version | -v | Display version |
SPICEApplications.chronos
— Methodchronos(
file;
from,
fromtype,
to,
totype,
format,
time,
sc,
center,
landingtime,
sol1index,
nolabel,
trace,
help,
usage,
template,
stdout,
stderr,
stdin,
append,
wait
)
CHRONOS is a command-line program that converts between several time systems and time formats.
Extended Help
All descriptions below were manually parsed from the commandline program's help/usage output.
Argument | Equivalent | Description |
---|---|---|
from | -FROM <arg> | "from" time system |
fromtype | -FROMTYPE <arg> | "from" time system type |
to | -TO <arg> | "to" time system |
totype | -TOTYPE <arg> | "to" time system type |
format | -FORMAT <arg> | output time format picture |
time | -TIME <time> | input time |
sc | -SC <ID> | sc ID |
center | -CENTER <ID> | central body ID |
landingtime | -LANDINGTIME <time> | UTC time of the landing |
sol1index | -SOL1INDEX <index> | index of the first SOL |
nolabel | -NOLABEL | |
trace | -TRACE | |
help | -HELP | display help |
usage | -USAGE | display usage |
template | -TEMPLATE | display setup file template |
SPICEApplications.ckbrief
— Methodckbrief(
file;
dump,
boundaries,
relframes,
idframes,
tabular,
single,
bycoverage,
utc,
utcdoy,
sclk,
dpsclk,
id,
summarize,
help,
version,
stdout,
stderr,
stdin,
append,
wait
)
CKBRIEF is a command-line utility program that displays a contents and time coverage summary for one or more binary CK files.
Extended Help
All descriptions below were manually parsed from the commandline program's help/usage output.
Argument | Equivalent | Description |
---|---|---|
dump | -dump | display interpolation intervals boundaries |
boundaries | -nm | display segment boundaries |
relframes | -rel | display relative-to frames |
idframes | -n | display frames associated with structure IDs |
tabular | -t | display summary in a tabular format |
single | -a | treat all files as a single file |
bycoverage | -g | display summary grouped by coverage |
utc | -utc | display times in UTC calendar date format |
utcdoy | -utcdoy | display times in UTC day-of-year format |
sclk | -sclk | display times as SCLK strings |
dpsclk | -dpsclk | display times as SCLK ticks |
id | [ID] | display summmary for structure with [ID] |
summarize | -f | summarize kernels listed in the [list] file |
help | -h | display help |
version | -v | display version |
SPICEApplications.commnt
— Functioncommnt(; ...)
commnt(kernelfile; ...)
commnt(
kernelfile,
commentfile;
add,
extract,
read,
delete,
help,
stdout,
stderr,
stdin,
append,
wait
)
COMMNT is a command-line program that reads, adds, extracts, or deletes comments from SPICE binary kernel files.
Extended Help
All descriptions below were manually parsed from the commandline program's help/usage output.
Argument | Equivalent | Description |
---|---|---|
add | -a | add comments to binary kernel |
extract | -e | extract comments from a binary kernel |
read | -r | read the comments in a binary kernel |
delete | -d | delete the comments from the binary kernel |
help | -h | display the help message |
SPICEApplications.dskbrief
— Methoddskbrief(
file;
single,
gaps,
extended,
timebounds,
bysegment,
full,
sigdigs,
version,
help,
usage,
stdout,
stderr,
stdin,
append,
wait
)
DSKBRIEF is a command-line utility program that displays a summary of the spatial coverage and additional attributes of one or more binary Digital Shape Kernel (DSK) files.
Extended Help
All descriptions below were manually parsed from the commandline program's help/usage output.
Argument | Equivalent | Description |
---|---|---|
single | -a | treat all DSK files as a single file |
gaps | -gaps | display coverage gaps (aplies only when -a is used) |
extended | -ext | display extended summaries: these include data type, data class, and time bounds |
timebounds | -tg | require segment time bounds to match when grouping segments |
full | -full | display a detailed summary for each segment, including data-type-specific parameters |
sigdigs | -d <n> | display n significant digits of floating point values |
version | -v | display the version of the program |
help | -h | display help text |
usage | -u | display usage text |
SPICEApplications.dskexp
— Methoddskexp(
;
dsk,
text,
format,
precision,
stdout,
stderr,
stdin,
append,
wait
)
DSKEXP is a command-line program that exports data from DSK files to text files.
Extended Help
All descriptions below were manually parsed from the commandline program's help/usage output.
Argument | Equivalent | Description |
---|---|---|
dsk | -dsk <arg> | DSK kernel |
text | -text <name> | output name |
format | -format <arg> | MKSDK format code/name |
precision | -prec <number> | number of vertex mantissa digits |
SPICEApplications.frmdiff
— Methodfrmdiff(
;
kernels,
from1,
to1,
frame1,
supporting_kernels1,
from2,
to2,
frame2,
supporting_kernels2,
angular,
angularframe,
start,
stop,
numpoints,
timestep,
timeformat,
report,
rotation,
units,
sigdigs,
stdout,
stderr,
stdin,
append,
wait
)
FRMDIFF is a program that samples orientation of a reference frame known to SPICE or computes differences between orientations of two reference frames known to SPICE, and either displays this orientation or these differences, or shows statistics about it or them.
Extended Help
All descriptions below were manually parsed from the commandline program's help/usage output.
Argument | Equivalent | Description |
---|---|---|
kernels | -k <kernels> | supporting kernel(s) name(s) |
from1 | -f1 <arg> | first "from" frame, name or ID |
to1 | -t1 <arg> | first "to" frame, name or ID |
frame1 | -c1 <arg> | first frame for coverage look up, name or ID |
supporting_kernels1 | -k1 <kernels> | additional supporting kernel(s) for first file |
from2 | -f2 <arg> | second "from" frame, name or ID |
to2 | -t2 <arg> | second "to" frame, name or ID |
frame2 | -c2 <arg> | second frame for coverage look up, name or ID |
supporting_kernels2 | -k2 <kernels> | additional supporting kernel(s) for second file |
angular | `-a <yes | no>` |
angularframe | `-m <from | to>` |
start | -b <start> | interval start time |
stop | -e <stop> | interval stop time |
numpoints | -n <number> | number of points 1 to 1000000 (default: 1000) |
timestep | -s <time step> | time step in seconds |
timeformat | -f <format> | time format: one of et , sclk , sclkd , ticks , picture_for_TIMOUT , (default: et ) |
report | -t <report options> | report options: basic , stats , dumpaa , dumpm , dumpqs , dumpqo , dumpea , dumpc , dumpg |
rotation | -o <order> | rotation axes order (default: z y x) |
units | -x <units> | units for output angles (only for -t dumpaa and -t dumpea ) |
sigdigs | -d <num> | number of significant digits (6 to 17, default 14) |
SPICEApplications.inspekt
— Methodinspekt(; stdout, stderr, stdin, append, wait)
INSPEKT is an interactive program that examines the contents of an events component (ESQ) of an E-kernel.
SPICEApplications.mkdsk
— Methodmkdsk(
;
setup,
input,
output,
help,
template,
usage,
version,
stdout,
stderr,
stdin,
append,
wait
)
MKDSK is a utility program that creates a SPICE Digital Shape Kernel (DSK) file from a text file containing shape data for an extended object.
Extended Help
All descriptions below were manually parsed from the commandline program's help/usage output.
Argument | Equivalent | Description |
---|---|---|
setup | -setup <filename> | setup file name |
input | -input <filename> | input shape data file name |
output | -output <filename> | output DSK file name |
help | -h ,-help | display help |
template | -t ,-template | display template |
usage | -u ,-usage | display usage |
version | -v ,-version | display version |
SPICEApplications.mkspk
— Methodmkspk(
;
setup,
input,
output,
add,
usage,
help,
template,
stdout,
stderr,
stdin,
append,
wait
)
MKSPK is a program that creates an SPK file from a text file containing trajectory information.
Extended Help
All descriptions below were manually parsed from the commandline program's help/usage output.
Argument | Equivalent | Description |
---|---|---|
setup | -setup <filename> | setup file name |
input | -input <filename> | input shape data file name |
output | -output <filename> | output DSK file name |
add | -append | append; output file must be new |
help | -h ,-help | display help |
template | -t ,-template | display template |
usage | -u ,-usage | display usage |
SPICEApplications.msopck
— Methodmsopck(
;
setup,
input,
output,
stdout,
stderr,
stdin,
append,
wait
)
MSOPCK is a command-line program that converts attitude data provided in a text file as UTC, SCLK, or ET-tagged quaternions, Euler angles, or matrices, optionally accompanied by angular velocities, into a type 1, 2, or 3 SPICE C-kernel.
SPICEApplications.spacit
— Methodspacit(; stdout, stderr, stdin, append, wait)
SPACIT is an interactive program that converts kernels in transfer format to binary format, converts binary kernels to transfer format, and summarizes the contents of binary kernels.
SPICEApplications.spkdiff
— Methodspkdiff(
;
kernels,
body1,
center1,
frame1,
supporting_kernels1,
body2,
center2,
frame2,
supporting_kernels2,
start,
stop,
timestep,
numstates,
timeformat,
sigdigs,
report,
stdout,
stderr,
stdin,
append,
wait
)
SPKDIFF provides means for comparing the trajectories of two bodies or sampling the trajectory of a single body using data from SPICE kernels.
Extended Help
All descriptions below were manually parsed from the commandline program's help/usage output.
Argument | Equivalent | Description |
---|---|---|
kernels | -k <kernels> | supporting kernel(s) name(s) |
body1 | -b1 <arg> | first body name or ID |
center1 | -c1 <arg> | first center name or ID |
frame1 | -r1 <arg> | first reference frame name |
supporting_kernels1 | -k1 <kernels> | additional supporting kernel(s) for first SPK |
body2 | -b2 <arg> | second body name or ID |
center2 | -c2 <arg> | second center name or ID |
frame2 | -r2 <arg> | second reference frame name |
supporting_kernels2 | -k2 <kernels> | additional supporting kernel(s) for second SPK |
start | -b <start> | interval start time |
stop | -e <stop> | interval stop time |
timestep | -s <time step> | time step in seconds |
numstates | -n <number> | number of states: 2 to 1000000 (default: 1000) |
timeformat | -f <arg> | output time format (default: TDB seconds past J2000) |
sigdigs1 | -d <arg> | number of significant digits: 6 to 17 (default: 14) |
report | -t <type> | report type: basic ,stats ,dump ,dumpvf ,dumpc ,dumpg (def.: basic ,dump ) |
SPICEApplications.spkmerge
— Functionspkmerge(; ...)
spkmerge(commandfile; stdout, stderr, stdin, append, wait)
SPKMERGE is a program that subsets or merges one or more SPK files into a single SPK file.
SPICEApplications.tobin
— Functiontobin(; ...)
tobin(kernelfile; stdout, stderr, stdin, append, wait)
TOBIN is a command-line program that converts transfer format SPK, CK, PCK, DSK and EK files to binary format.
SPICEApplications.toxfr
— Functiontoxfr(; ...)
toxfr(kernelfile; stdout, stderr, stdin, append, wait)
TOXFR is a command-line program that converts binary format SPK, CK, PCK, DSK and EK files to transfer format.