Spice is a system of data files (kernels) and software developed and maintained by the Navigation Ancillary Information Facility (NAIF) at JPL for the purpose of sharing mission data and definitional information. ODTK uses a subset of the SPICE software to provide access to SPICE kernels containing ephemeris for planetary bodies and spacecraft. In addition to ephemeris information, ODTK must also load the SPICE leap second kernel to enable accurate time conversions within SPICE. The leap second kernel is available for update through the Data Update Utility to stay current with newly announced leap seconds.
SPICE files are loaded at ODTK startup and are then available to be referenced by components of ODTK. Central bodies can be configured to use SPICE for position information in the EphemerisData section of the (*.cb) file.
|Files||Read only list of SPICE files loaded at ODTK startup. Each
SPICE file contains ephemeris information for one or more bodies.
Files are shown in the order of loading, see below for the
importance of loading order and directory locations from which
SPICE files are loaded. Note that the leap second kernel is not
shown in this list. Each entry contains two settings:
ODTK has an automatic loading scheme for SPICE files which begins when the ODTK application is started. First, all SPICE files located in ODTK Install Directory\STKData\Spice are loaded. Next, all SPICE files in ODTK_ALL_USERS_DIR\STKData\Spice are loaded; then, all SPICE files in USER_CONFIG_DIR\Spice are loaded.
NOTE: The ODTK_ALL_USERS_DIR is usually loaded in C:\Documents and Settings\All Users\Application Data\AGI on machines with x86 (32 bit) operating systems and in C:\ProgramData\AGI\ on machines with x64 (64 bit).
NOTE: ODTK must be exited and restarted for newly placed SPICE files to be loaded.
NOTE: You must be careful concerning the use of multiple SPICE files that contain ephemeris for the object. When an object's ephemeris is not uniquely determined (e.g. there are multiple definitions of the ephemeris of the object at a given time because of multiple files containing overlapping data), SPICE itself resolves the conflict, using the latest file loaded that can handle the ephemeris request.
Thus, in these cases, the order of the file loading is important. Since ODTK does not allow the user to set the order of the file loading, it is a best practice to resolve these conflicts outside of ODTK by using SPICE files that do not have overlapping ephemeris. SPICE utilities, provided by NAIF of JPL (maintainers of the SPICE capability), can be used for this purpose. Consult STKData/Spice/ReadMe/ReadMe.txt located in the ODTK installation directory for more information regarding which ephemerides are loaded by ODTK at startup.
Typically, natural bodies are identified by positive integer ids in SPICE, while artificial satellites are given negative integer ids. In addition to the integer ids, bodies usually have textural names as well. You can help SPICE resolve the names associated with integer ids that are not recognized by supplying a special SPICE kernel that establishes the mapping. This kernel (data file) can be located in any of the directories loaded by ODTK at startup. A simple example of such a kernel is shown below. Note that as is shown in the example, it is important to use "+=" and not "=" in the assignment statements to avoid wiping out the prior contents of the SPICE variables.
NAIF_BODY_NAME +=('MSL', 'LRO')