Changeset 2d1bdc8 in rtems for doc/user/clock.t


Ignore:
Timestamp:
Dec 24, 2013, 5:38:42 AM (7 years ago)
Author:
Chris Johns <chrisj@…>
Branches:
4.11, 5, master
Children:
9f9c0bb
Parents:
c2b7528
git-author:
Chris Johns <chrisj@…> (12/24/13 05:38:42)
git-committer:
Chris Johns <chrisj@…> (12/24/13 05:46:19)
Message:

cpukit/rtems: Add rtems_clock_get_uptime_nanoseconds to the RTEMS API.

Add Timestamp support in the score to return a timestamp in nanoseconds.
Add a test.
Update the RTEMS API documentation.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • doc/user/clock.t

    rc2b7528 r2d1bdc8  
    1919@item @code{@value{DIRPREFIX}clock_get_tod} - Get date and time in TOD format
    2020@item @code{@value{DIRPREFIX}clock_get_tod_timeval} - Get date and time in timeval format
    21 @item @code{@value{DIRPREFIX}clock_get_seconds_since_epoch} - Get seconds since epoch 
     21@item @code{@value{DIRPREFIX}clock_get_seconds_since_epoch} - Get seconds since epoch
    2222@item @code{@value{DIRPREFIX}clock_get_ticks_per_second} - Get ticks per second
    2323@item @code{@value{DIRPREFIX}clock_get_ticks_since_boot} - Get ticks since boot
     
    2525@item @code{@value{DIRPREFIX}clock_get_uptime_timeval} - Get time since boot in timeval format
    2626@item @code{@value{DIRPREFIX}clock_get_uptime_seconds} - Get seconds since boot
     27@item @code{@value{DIRPREFIX}clock_get_uptime_nanoseconds} - Get nanoseconds since boot
    2728@item @code{@value{DIRPREFIX}clock_set_nanoseconds_extension} - Install the nanoseconds since last tick handler
    2829@item @code{@value{DIRPREFIX}clock_tick} - Announce a clock tick
     
    8687supported when setting the system date and time using the
    8788@code{@value{DIRPREFIX}clock_set} directive.  Some applications
    88 expect to operate on a "UNIX-style" date and time data structure.  The 
     89expect to operate on a "UNIX-style" date and time data structure.  The
    8990@code{@value{DIRPREFIX}clock_get_tod_timeval} always returns
    90 the date and time in @code{struct timeval} format.  The 
     91the date and time in @code{struct timeval} format.  The
    9192@code{@value{DIRPREFIX}clock_get} directive can optionally return
    92 the current date and time in this format. 
     93the current date and time in this format.
    9394
    9495The @code{struct timeval} data structure has two fields: @code{tv_sec}
     
    143144@code{@value{DIRPREFIX}event_receive},
    144145@code{@value{DIRPREFIX}semaphore_obtain} and
    145 @code{@value{DIRPREFIX}region_get_segment} directives. 
    146 Each task may have one and only one timeout active at a time. 
     146@code{@value{DIRPREFIX}region_get_segment} directives.
     147Each task may have one and only one timeout active at a time.
    147148When a timeout expires, it unblocks the task with a timeout status code.
    148149
     
    193194@code{@value{DIRPREFIX}clock_get_options}:
    194195
    195 @findex rtems_clock_get_options 
     196@findex rtems_clock_get_options
    196197
    197198@itemize @bullet
     
    323324has not been set with a previous call to
    324325@code{@value{DIRPREFIX}clock_set}, then the
    325 @code{@value{RPREFIX}NOT_DEFINED} status code is returned. 
     326@code{@value{RPREFIX}NOT_DEFINED} status code is returned.
    326327The caller can always obtain the number of ticks per second (option is
    327328@code{@value{RPREFIX}CLOCK_GET_TICKS_PER_SECOND}) and the number of
     
    334335indicated below:
    335336
    336 @findex rtems_clock_get_options 
     337@findex rtems_clock_get_options
    337338@ifset is-C
    338339@itemize @bullet
     
    418419has not been set with a previous call to
    419420@code{@value{DIRPREFIX}clock_set}, then the
    420 @code{@value{RPREFIX}NOT_DEFINED} status code is returned. 
     421@code{@value{RPREFIX}NOT_DEFINED} status code is returned.
    421422
    422423@subheading NOTES:
     
    469470has not been set with a previous call to
    470471@code{@value{DIRPREFIX}clock_set}, then the
    471 @code{@value{RPREFIX}NOT_DEFINED} status code is returned. 
     472@code{@value{RPREFIX}NOT_DEFINED} status code is returned.
    472473
    473474@subheading NOTES:
     
    520521has not been set with a previous call to
    521522@code{@value{DIRPREFIX}clock_set}, then the
    522 @code{@value{RPREFIX}NOT_DEFINED} status code is returned. 
     523@code{@value{RPREFIX}NOT_DEFINED} status code is returned.
    523524
    524525@subheading NOTES:
     
    621622
    622623This directive simply returns the number of times the dirivective
    623 @code{@value{DIRPREFIX}clock_tick} has been invoked since the 
     624@code{@value{DIRPREFIX}clock_tick} has been invoked since the
    624625system was booted.
    625626
     
    737738@c
    738739@page
     740@subsection CLOCK_GET_UPTIME_NANOSECONDS - Get the nanoseconds since boot
     741
     742@cindex clock get nanoseconds uptime
     743@cindex uptime
     744
     745@subheading CALLING SEQUENCE:
     746
     747@ifset is-C
     748@findex rtems_clock_get_uptime_nanoseconds
     749@example
     750uint64_t rtems_clock_get_uptime_nanoseconds(void);
     751@end example
     752@end ifset
     753
     754@subheading DIRECTIVE STATUS CODES:
     755
     756The system uptime in nanoseconds.
     757
     758@subheading DESCRIPTION:
     759
     760This directive returns the nanoseconds since the system was booted.
     761
     762@subheading NOTES:
     763
     764This directive may be called from an ISR.
     765
     766@c
     767@c
     768@c
     769@page
    739770@subsection CLOCK_SET_NANOSECONDS_EXTENSION - Install the nanoseconds since last tick handler
    740771
     
    766797@subheading DESCRIPTION:
    767798
    768 This directive is used by the Clock device driver to install the 
     799This directive is used by the Clock device driver to install the
    769800@code{routine} which will be invoked by the internal RTEMS method used to
    770801obtain a highly accurate time of day.  It is usually called during
     
    781812This directive may be called from an ISR.
    782813
    783 This directive is called as part of every service to obtain the 
     814This directive is called as part of every service to obtain the
    784815current date and time as well as timestamps.
    785816
     
    829860microseconds per tick and number of ticks per timeslice,
    830861respectively.
    831 
Note: See TracChangeset for help on using the changeset viewer.