Table of contents
CSPICE_CKLPF loads a CK pointing file for use by the CK readers.
This routine returns that file's handle, to be used by other CK
routines to refer to the file.
Given:
fname the string name of a CK file to be loaded.
help, fname
STRING = Scalar
the call:
cspice_cklpf, fname, handle
returns:
handle a scalar integer file handle assigned to the file upon loading.
help, handle
LONG = Scalar
Almost every other CK routine will subsequently use this number
to refer to the file.
FTSIZE is the maximum number of pointing files that can
be loaded by cspice_cklpf at any given time for use by
the readers.
Any numerical results shown for this example may differ between
platforms as the results depend on the SPICE kernels used as input
and the machine specific arithmetic implementation.
1) The following example will extract the entire comment area of a
CK file, displaying the comments on the terminal screen.
Use the CK kernel below as input file for the example. This file
contains pointing data for the CASSINI spacecraft.
04161_04164ra.bc
Example code begins here.
PRO cklpf_ex1
;;
;; Define the CK file from which to extract the comment area.
;;
CKNAME = '04161_04164ra.bc'
SPICEFALSE = 0L
;;
;; Define the size of the comment area to read from the CK.
;; Maximum of 300 lines, each with length 100 characters.
;;
BUFSIZE = 300L
LINLEN = 100L
;;
;; Open the CK for reading, return the corresponding
;; file handle to `handle'. This operation could have been
;; done using cspice_dafopr.
;;
cspice_cklpf, CKNAME, handle
done = SPICEFALSE
cspice_dafec, handle, BUFSIZE, LINLEN, n, buf, done
for i=0,n-1 do print, buf[i]
print, ''
if ( done ) then begin
print, 'All comments read from file.'
endif else begin
print, 'Not all comments read from file.'
endelse
;;
;; Unload the CK file.
;;
cspice_ckupf, handle
END
When this program was executed on a Mac/Intel/IDL8.x/64-bit
platform, the output was:
\beginlabel
PDS_VERSION_ID = PDS3
RECORD_TYPE = FIXED_LENGTH
RECORD_BYTES = 1024
^SPICE_KERNEL = "04161_04164ra.bc"
MISSION_NAME = "CASSINI-HUYGENS"
SPACECRAFT_NAME = "CASSINI ORBITER"
DATA_SET_ID = "CO-S/J/E/V-SPICE-6-V1.0"
KERNEL_TYPE_ID = CK
PRODUCT_ID = "04161_04164ra.bc"
PRODUCT_CREATION_TIME = 2005-06-29T21:28:09
PRODUCER_ID = "CASSINI_AACS/JPL"
MISSION_PHASE_NAME = "SCIENCE CRUISE"
PRODUCT_VERSION_TYPE = ACTUAL
PLATFORM_OR_MOUNTING_NAME = "N/A"
START_TIME = 2004-06-09T12:00:03.631
STOP_TIME = 2004-06-12T11:58:57.943
SPACECRAFT_CLOCK_START_COUNT = "1/1465475046.160"
SPACECRAFT_CLOCK_STOP_COUNT = "1/1465734182.160"
TARGET_NAME = "N/A"
INSTRUMENT_NAME = "CASSINI ORBITER"
NAIF_INSTRUMENT_ID = -82000
SOURCE_PRODUCT_ID = "N/A"
NOTE = "See comments in the file for details"
OBJECT = SPICE_KERNEL
INTERCHANGE_FORMAT = BINARY
KERNEL_TYPE = POINTING
DESCRIPTION = "Reconstructed Cassini Spacecraft
Orientation CK file. "
END_OBJECT = SPICE_KERNEL
\endlabel
Cassini Spacecraft Orientation Reconstructed CK File
======================================================================***
Comments added by Lee Elson, NAIF/JPL, Wed Jun 29 15:05:33 PDT 2005
Orientation Data in the File
--------------------------------------------------------
This file contains reconstructed orientation and angular velocity
data for the Cassini Orbiter spacecraft frame, 'CASSINI_SC_COORD',
relative to the 'J2000' inertial frame. The NAIF ID code for the
'CASSINI_SC_COORD' frame is -82000.
Status
--------------------------------------------------------
The data in this file were created by the Cassini Project for
archiving with the Planetary Data System (PDS).
Pedigree
--------------------------------------------------------
Reconstructed CK files were delivered to the Cassini Project by the
Attitude and Articulation Subsystem (AACS). These reconstructed
files contain spacecraft orientation and angular rates returned
in Cassini spacecraft telemetry. The data were packaged by AACS
using the SPICE utility MSOPCK provided by NAIF. Later files
were created by accessing the MSOPCK software through the AACS
C-Kernel Generation Tool (ACKT) user interface.
Files generated prior to January 2004 have been merged to remove
redundant data and in some cases provide longer interpolation
intervals since the spacecraft was primarily earth pointed during
that time.
Approximate Time Coverage
--------------------------------------------------------
This file covers the following interval of the mission:
Coverage Begin UTC Coverage End UTC
------------------------ ------------------------
2004-JUN-09 12:00:03.631 2004-JUN-12 11:58:57.943
This file is a type 3 CK file which allows linear interpolation
between orientation data points extracted from telemetry. Such
interpolation is not applicable to the whole file but only inside
intervals where enough orientation telemetry data are available
and orientation data points were close enough to each other in time
for such interpolation to make sense.
The nominal quaternion time spacing in the telemetry stream is
4 seconds but a spacing as large as 16 seconds may exist between
adjacent data points.
A table containing the complete list of valid interpolation inter***
in the file is provided in Appendix 2.
Related Information
--------------------------------------------------------
AACS has carried out comparisons between some predicted CK
files and the corresponding reconstructed CK files. Numerical
values for comparison statistics as well as interval and gap
[...]
Warning: incomplete output. Only 100 out of 273 lines have been
provided. 2 lines extended past the right margin of the header
and have been truncated. These lines are marked by "***" at the
end of each line.
Before a file can be read by the C-kernel readers, it must be
loaded by cspice_cklpf, which among other things load the file into
the DAF subsystem.
Up to FTSIZE files may be loaded for use simultaneously, and a
file only has to be loaded once to become a potential search
target for any number of subsequent reads.
Once a C-kernel has been loaded, it is assigned a file
handle, which is used to keep track of the file internally, and
which is used by the calling program to refer to the file in all
subsequent calls to CK routines.
If there is room for a new file, cspice_cklpf opens the file for
reading. This routine must be called prior to a call to cspice_ckgp or
cspice_ckgpav.
CK readers search files loaded with cspice_cklpf in the reverse order
in which they were loaded. That is, last-loaded files are
searched first.
This routine, and all kernel file load routines requiring
explicit file handle management has been superseded by
cspice_furnsh. NAIF recommends users load all kernel files for
read-only data access with cspice_furnsh.
1) If an attempt is made to load more DAF files than is
specified by the parameter FTSIZE in DAF system, an error
is signaled by a routine in the call tree of this routine.
2) If an attempt is made to load more files than is specified by
the parameter FTSIZE in the CK subsystem, and if the DAF
system has room to load another file, the error
SPICE(CKTOOMANYFILES) is signaled by a routine in the call
tree of this routine. The current setting of FTSIZE does not
allow this situation to arise: the DAF system will trap the
error before this routine has the chance.
3) If the file specified by `fname' can not be opened, an error
is signaled by a routine in the call tree of this routine.
4) If the file specified by `fname' has already been loaded,
it will become the "last-loaded" file. The readers
search the last-loaded file first.
5) If the input argument `fname' is undefined, an error is
signaled by the IDL error handling system.
6) If the input argument `fname' is not of the expected type, or
it does not have the expected dimensions and size, an error is
signaled by the Icy interface.
7) If the output argument `handle' is not a named variable, an
error is signaled by the Icy interface.
The C-kernel file specified by `fname' is loaded. The file is
assigned an integer handle by cspice_cklpf. Other CK routines will refer
to this file by its handle.
None.
CK.REQ
DAF.REQ
ICY.REQ
None.
J. Diaz del Rio (ODC Space)
E.D. Wright (JPL)
-Icy Version 1.0.1, 03-NOV-2021 (JDR)
Edited the header to comply with NAIF standard. Added complete code
example based on that present in cspice_dafec.
Added -Parameters, -Exceptions, -Files, -Restrictions,
-Literature_References and -Author_and_Institution sections, and
completed -Particulars section.
Removed reference to the routine's corresponding CSPICE header from
-Abstract section.
Added arguments' type and size information in the -I/O section.
-Icy Version 1.0.0, 16-JUN-2003 (EDW)
load CK pointing file
|