include/native/timer.h

Go to the documentation of this file.
00001 
00022 #ifndef _XENO_TIMER_H
00023 #define _XENO_TIMER_H
00024 
00025 #include <nucleus/timer.h>
00026 #include <native/types.h>
00027 
00028 #define TM_UNSET   XN_NO_TICK
00029 #define TM_ONESHOT XN_APERIODIC_TICK
00030 
00031 typedef struct rt_timer_info {
00032 
00033     RTIME period;       /* !< Current status (unset, aperiodic, period). */
00034     RTIME date;         /* !< Current wallclock time. */
00035     RTIME tsc;          /* !< Current tsc count. */
00036 
00037 } RT_TIMER_INFO;
00038 
00039 #ifdef __cplusplus
00040 extern "C" {
00041 #endif
00042 
00043 SRTIME rt_timer_ns2ticks(SRTIME ns);
00044 
00045 SRTIME rt_timer_ticks2ns(SRTIME ticks);
00046 
00047 SRTIME rt_timer_ns2tsc(SRTIME ns);
00048 
00049 SRTIME rt_timer_tsc2ns(SRTIME ticks);
00050 
00051 int rt_timer_inquire(RT_TIMER_INFO *info);
00052 
00053 RTIME rt_timer_read(void);
00054 
00055 RTIME rt_timer_tsc(void);
00056 
00057 void rt_timer_spin(RTIME ns);
00058 
00059 int rt_timer_set_mode(RTIME nstick);
00060 
00061 static inline int __deprecated_call__ rt_timer_start(RTIME nstick)
00062 {
00063     return 0;
00064 }
00065 
00066 static inline void __deprecated_call__ rt_timer_stop(void)
00067 {
00068 }
00069 
00070 #ifdef __cplusplus
00071 }
00072 #endif
00073 
00074 #endif /* !_XENO_TIMER_H */

Generated on Mon Dec 25 13:57:10 2006 for Xenomai API by  doxygen 1.4.6