RTEMS  5.1
Data Structures | Macros | Typedefs | Functions
timecounter.h File Reference

Timecounter API. More...

#include <rtems/score/timecounter.h>
#include <rtems/score/basedefs.h>

Go to the source code of this file.

Data Structures

struct  rtems_timecounter_simple
 Simple timecounter to support legacy clock drivers. More...
 

Macros

#define RTEMS_TIMECOUNTER_QUALITY_CLOCK_DRIVER   100
 Timecounter quality for the clock drivers. More...
 

Typedefs

typedef void rtems_timecounter_simple_at_tick(rtems_timecounter_simple *tc)
 At tick handling done under protection of the timecounter lock.
 
typedef uint32_t rtems_timecounter_simple_get(rtems_timecounter_simple *tc)
 Returns the current value of a simple timecounter.
 
typedef bool rtems_timecounter_simple_is_pending(rtems_timecounter_simple *tc)
 Returns true if the interrupt of a simple timecounter is pending, and false otherwise.
 

Functions

RTEMS_INLINE_ROUTINE void rtems_timecounter_install (struct timecounter *tc)
 Installs the timecounter. More...
 
RTEMS_INLINE_ROUTINE void rtems_timecounter_tick (void)
 Performs a timecounter tick. More...
 
void rtems_timecounter_simple_install (rtems_timecounter_simple *tc, uint32_t counter_frequency_in_hz, uint32_t counter_ticks_per_clock_tick, timecounter_get_t *get_timecount)
 Initializes and installs a simple timecounter. More...
 
RTEMS_INLINE_ROUTINE uint32_t rtems_timecounter_simple_scale (const rtems_timecounter_simple *tc, uint32_t value)
 Maps a simple timecounter value into its binary frequency domain. More...
 
RTEMS_INLINE_ROUTINE void rtems_timecounter_simple_downcounter_tick (rtems_timecounter_simple *tc, rtems_timecounter_simple_get get, rtems_timecounter_simple_at_tick at_tick)
 Performs a simple timecounter tick for downcounters. More...
 
RTEMS_INLINE_ROUTINE void rtems_timecounter_simple_upcounter_tick (rtems_timecounter_simple *tc, rtems_timecounter_simple_get get, rtems_timecounter_simple_at_tick at_tick)
 Performs a simple timecounter tick for upcounters. More...
 
RTEMS_INLINE_ROUTINE uint32_t rtems_timecounter_simple_downcounter_get (struct timecounter *tc_base, rtems_timecounter_simple_get get, rtems_timecounter_simple_is_pending is_pending)
 Gets the simple timecounter value mapped to its binary frequency domain for downcounters. More...
 
RTEMS_INLINE_ROUTINE uint32_t rtems_timecounter_simple_upcounter_get (struct timecounter *tc_base, rtems_timecounter_simple_get get, rtems_timecounter_simple_is_pending is_pending)
 Gets the simple timecounter value mapped to its binary frequency domain for upcounters. More...
 

Detailed Description

Timecounter API.