Index Page scpart_c

A B C D E F G H I J K L M N O P Q R S T U V W X

Procedure Abstract Required_Reading Keywords Brief_I/O Detailed_Input | Detailed_Output Parameters Exceptions Files Particulars Examples | Restrictions Literature_References Author_and_Institution Version Index_Entries

#### Procedure

       void scpart_c ( SpiceInt        sc,
                       SpiceInt      * nparts,
                       SpiceDouble   * pstart,
                       SpiceDouble   * pstop  )

#### Abstract

       Get spacecraft clock partition information from a spacecraft
       clock kernel file.

#### Required_Reading

       SCLK

#### Keywords

       TIME

#### Brief_I/O

       Variable  I/O  Description
       --------  ---  --------------------------------------------------
       sc         I   NAIF spacecraft identification code.
       nparts     O   The number of spacecraft clock partitions.
       pstart     O   Array of partition start times.
       pstop      O   Array of partition stop times.
       MXPART     P   Maximum number of partitions.

#### Detailed_Input

       sc         is the NAIF ID for the spacecraft whose clock partition
                  information is being requested.

#### Detailed_Output

       nparts     is the number of spacecraft clock time partitions
                  described in the kernel file for spacecraft SC.

       pstart     is an array containing nparts partition start times
                  represented as double precision, encoded SCLK ("ticks").
                  The values contained in pstart are whole numbers.

       pstop      is an array containing nparts partition end times
                  represented as double precision, encoded SCLK ("ticks").
                  The values contained in pstop are whole numbers.

#### Parameters

       MXPART     is the maximum number of partitions for any
                  spacecraft clock. MXPART is currently set to
                  9999.

#### Exceptions

       1)  If the kernel variables containing the spacecraft clock
           partition start and stop times have not been loaded in the
           kernel pool, the error will be diagnosed by routines called
           by this routine.

       2)  If the number of start and stop times are different then
           the error SPICE(NUMPARTSUNEQUAL) is signalled.

#### Files

       An SCLK kernel containing spacecraft clock partition start
       and stop times for the spacecraft clock indicated by SC must
       be loaded into the kernel pool before this routine may be called.

#### Particulars

       scpart_c looks for two variables in the kernel pool for each
       spacecraft's partition information. If sc = -nn, then the names of
       the variables are

          "SCLK_PARTITION_START_nn"
          "SCLK_PARTITION_END_nn"

       The start and stop times returned are in units of "ticks."

#### Examples

       1)  The following program fragment finds and prints out partition
           start and stop times in clock format for the Galileo mission.
           In this example, Galileo partition times are assumed to be
           in the kernel file sclk.ker.

              #include <stdio.h>
              #include "SpiceUsr.h"

              void main()
              {
                 #define   CLKLEN        30
                 #define   SC            -32
                 #define   MXPART        9999

                 SpiceChar               start  [ CLKLEN ];
                 SpiceChar               stop   [ CLKLEN ];
                 SpiceDouble             pstart [ MXPART ];
                 SpiceDouble             pstop  [ MXPART ];

                 SpiceInt                nparts;
                 SpiceInt                i;

                 furnsh_c ( "sclk.ker" );

                 scpart_c ( SC, &nparts, pstart, pstop );

                 for ( i = 0;  i < nparts;  i++ )
                 {
                    scfmt_c ( SC, pstart[ i ], CLKLEN, start );
                    scfmt_c ( SC, pstop [ i ], CLKLEN, stop  );

                    printf  ( "\n"
                              "Partition %d:\n"
                              "Start = %s\n"
                              "Stop  = %s\n"
                              "\n",
                              i,
                              start,
                              stop                );
                 }
              }

#### Restrictions

       1) This routine assumes that an SCLK kernel appropriate to the
          spacecraft identified by SC has been loaded into the kernel
          pool.

#### Literature_References

       None.

#### Author_and_Institution

       N.J. Bachman   (JPL)
       J.M. Lynch     (JPL)
       R.E. Thurman   (JPL)

#### Version

       -CSPICE Version 1.1.1, 19-MAR-2014   (NJB)

          Minor header comment updates were made.

       -CSPICE Version 1.1.0, 11-FEB-2008   (NJB)

          Definition of constant macro MXPART was deleted.
          Documentation was updated to reflect current
          MXPART value of 9999.

       -CSPICE Version 1.0.1, 14-AUG-2006   (EDW)

          Replace mention of ldpool_c with furnsh_c.

       -CSPICE Version 1.0.0, 08-FEB-1998 (NJB)

          Based on SPICELIB Version 1.1.0, 22-MAR-1993 (JML)

#### Index_Entries

       spacecraft_clock partition information

#### Link to routine scpart_c source file scpart_c.c

    Wed Apr  5 17:54:42 2017