Changeset 4711
- Timestamp:
- Aug 4, 2005, 5:51:16 PM (21 years ago)
- Location:
- trunk/doc/pslib
- Files:
-
- 2 edited
-
ChangeLogSDRS.tex (modified) (2 diffs)
-
psLibSDRS.tex (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/doc/pslib/ChangeLogSDRS.tex
r4599 r4711 1 %%% $Id: ChangeLogSDRS.tex,v 1.16 1 2005-07-22 22:39:21price Exp $1 %%% $Id: ChangeLogSDRS.tex,v 1.162 2005-08-05 03:51:16 price Exp $ 2 2 3 3 \subsection{Changes from version 00 to version 01} … … 760 760 \item \code{psPixelCoord} now contains floats. 761 761 \item \code{psImageSlice} uses \code{psPixels} to output coordinates. 762 \end{itemize} 763 762 \item Added \code{psTimer} functions (prototypes by EAM). 763 \item \code{psLibInit} and \code{psLibCleanup} changed to 764 \code{psTimeInitialize} and \code{psTimeFinalize}. Calls to 765 functions that require the time tables before calling 766 \code{psTimeInitialize} shall produce an error. 767 \item Added \code{psArgument} functions to provide simple argument 768 handling. 769 \end{itemize} 770 -
trunk/doc/pslib/psLibSDRS.tex
r4598 r4711 1 %%% $Id: psLibSDRS.tex,v 1.32 1 2005-07-22 22:36:33price Exp $1 %%% $Id: psLibSDRS.tex,v 1.322 2005-08-05 03:51:16 price Exp $ 2 2 \documentclass[panstarrs,spec]{panstarrs} 3 3 … … 271 271 \subsection{Initialization} 272 272 273 PSLib may be initialized by calling \code{psLibInit} by the user 274 before use. This enables the library to perform the following tasks 275 that are required before general use: 276 \begin{itemize} 277 \item Set the error codes for PSLib. 278 \item Read the \code{psTime} configuration file (\code{timeConfig}) 279 and set up the appropriate \code{psTimeTable}s and predictions. 280 \end{itemize} 281 282 The prototype is: 283 \begin{prototype} 284 void psLibInit(const char *timeConfig); 285 \end{prototype} 286 287 \code{timeConfig} specifies the filename of the configuration file 288 for \code{psTime} metadata. 289 290 \subsection{Finalization} 291 292 \begin{prototype} 293 void psLibCleanup(void); 294 \end{prototype} 295 296 \code{psLibCleanup} shall free memory that was allocated by 297 \code{psLibInit}, allowing a subsequent search for leaked memory (even 298 memory marked as \code{persistent}). 273 Before certain \code{psTime} functions can be employed, the user must 274 call \code{psTimeInitialize}. 299 275 300 276 \subsection{Memory Management} … … 1628 1604 1629 1605 1630 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 1606 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 1631 1607 1632 1608 \subsection{Abort} … … 1639 1615 \end{prototype} 1640 1616 1641 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 1617 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 1618 1619 \subsection{Command-line arguments} 1620 1621 The following functions are provided to aid parsing of command-line 1622 arguments: 1623 1624 \begin{prototype} 1625 int psArgumentGet(int argc, char **argv, const char *arg); 1626 bool psArgumentRemove(int argnum, int *argc, char **argv); 1627 \end{prototype} 1628 1629 \code{psArgumentGet} shall return the index of the element in the 1630 argument list, \code{argv} with number of entries \code{argc}, that 1631 matches the specified argument, \code{arg}, or zero if there is no 1632 match. 1633 1634 \code{psArgumentRemove} shall remove from the argument list 1635 (\code{argv} with number of entries \code{argc}) the argument whose 1636 index is \code{argnum}. The number of entries in the argument list 1637 shall be decremented. The function shall return \code{true} if the 1638 \code{argnum} is in the argument list, and \code{false} otherwise. 1639 1640 \begin{prototype} 1641 int psArgumentVerbosity(int *argc, char **argv); 1642 \end{prototype} 1643 1644 \code{psArgumentVebosity} shall implement the various verbosity 1645 controls under the following guidelines: 1646 \begin{itemize} 1647 \item \code{-v} switch shall set the log level to 3. 1648 \item \code{-vv} switch shall set the log level to 4. 1649 \item \code{-vvv} switch shall set the log level to 5. 1650 \item \code{-logfmt someFormat} switch shall set the log format to 1651 \code{someFormat}. 1652 \item \code{-trace facility level} switch shall set the trace level 1653 for the specified \code{facility} to the specified \code{level}. 1654 \item \code{-trace-levels} switch shall print the trace levels as 1655 currently set. 1656 \end{itemize} 1657 1658 The above arguments shall be removed from the argument list as they 1659 are processed. The function shall return the resultant logging level. 1660 1661 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 1642 1662 1643 1663 \pagebreak … … 5730 5750 track the time system being represented. 5731 5751 5752 \subsubsection{Initialization and Finalization} 5753 5754 The conversions between various time standards, and the polar motion 5755 requires importing external data (``time tables''), the locations of 5756 which are specified in a configuration file. 5757 5758 \begin{prototype} 5759 void psTimeInitialize(const char *timeConfig); 5760 \end{prototype} 5761 5762 \code{psTimeInitialize} shall read the \code{psTime} configuration 5763 file (\code{timeConfig}) and set up the appropriate 5764 \code{psTimeTable}s and predictions. 5765 5766 {\bf Calls to \code{psTime} functions that require the time tables 5767 before calling \code{psTimeInitialize} shall result in an error.} 5768 5769 \begin{prototype} 5770 void psTimeFinalize(void); 5771 \end{prototype} 5772 5773 \code{psTimeFinalize} shall free memory that was allocated by 5774 \code{psTime} functions, allowing a subsequent search for leaked 5775 memory (even memory marked as \code{persistent}). 5776 5732 5777 \subsubsection{Data Types} 5733 5778 … … 5952 5997 and ``to'' dates of applicability will be specified through metadata 5953 5998 (\S\ref{sec:timeMetadata}). 5999 6000 {\bf Calls to \code{psTime} functions that require the time tables 6001 before calling \code{psTimeInitialize} shall result in an error.} 5954 6002 5955 6003 When a value is required, the tables shall shall be checked in … … 6017 6065 A series of test inputs is contained in \S\ref{sec:timetest}. 6018 6066 6067 \subsection{Timers} 6068 6069 It is useful to be able to time an operation. For this purpose, we specify 6070 the following: 6071 6072 \begin{prototype} 6073 bool psTimerStart(char *name); 6074 psF64 psTimerMark(char *name); 6075 psF64 psTimerStop(void); 6076 \end{prototype} 6077 6078 \code{psTimerStart} shall store the current time in a \code{psHash} of 6079 timers, under the supplied \code{name}. \code{psTimerMark} shall 6080 return the elapsed time, in seconds, for the timer specified by 6081 \code{name}. \code{psTimerStop} shall free all memory associated with 6082 the timers, so that no memory is leaked, and return the maximum time 6083 expended. 6084 6085 6019 6086 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 6020 6087
Note:
See TracChangeset
for help on using the changeset viewer.
