Orocos Real-Time Toolkit
2.9.0
|
#include <stdio.h>
#include <stdlib.h>
#include <errno.h>
#include <string.h>
#include <limits.h>
#include <float.h>
#include <assert.h>
#include "../oro_limits.h"
#include "../../rtt-config.h"
#include <sys/time.h>
#include <time.h>
#include <unistd.h>
#include "dlfcn.h"
Go to the source code of this file.
Classes | |
struct | RTOS_TASK |
struct | oro_timespec |
struct | rt_cond_t |
Macros | |
#define | HAVE_FOSI_API |
This file translates the FOSI (Framework Operating System Interface) from orocos calls to native RTOS calls. More... | |
#define | ORO_WAIT_ABS |
#define | ORO_WAIT_REL |
#define | ORO_SCHED_RT 0 /** Linux FIFO scheduler */ |
#define | ORO_SCHED_OTHER 1 /** Linux normal scheduler */ |
#define | rtos_printf printf |
Typedefs | |
typedef long long | NANO_TIME |
typedef long long | TICK_TIME |
typedef struct oro_timespec | TIME_SPEC |
typedef HANDLE | rt_sem_t |
typedef CRITICAL_SECTION | rt_mutex_t |
typedef CRITICAL_SECTION | rt_rec_mutex_t |
Functions | |
RTT_API unsigned int | sleep (unsigned int seconds) |
RTT_API int | usleep (unsigned int us) |
TIME_SPEC | ticks2timespec (TICK_TIME hrt) |
NANO_TIME | rtos_get_time_ns (void) |
Get "system" time in nanoseconds. More... | |
TICK_TIME | rtos_get_time_ticks () |
This function should return ticks, but we use ticks == nsecs in userspace. More... | |
int | win32_nanosleep (long long nano) |
int | rtos_nanosleep (const TIME_SPEC *rqtp, TIME_SPEC *rmtp) |
long long | nano2ticks (long long nano) |
No conversions are needed in userspace. More... | |
long long | ticks2nano (long long count) |
int | setenv (const char *name, const char *value, int overwrite) |
Variables | |
const TICK_TIME | InfiniteTicks = LLONG_MAX |
const NANO_TIME | InfiniteNSecs = LLONG_MAX |
const double | InfiniteSeconds = DBL_MAX |
#define HAVE_FOSI_API |
typedef CRITICAL_SECTION rt_mutex_t |
typedef CRITICAL_SECTION rt_rec_mutex_t |
typedef struct oro_timespec TIME_SPEC |
|
inline |
|
inline |
|
inline |
This function should return ticks, but we use ticks == nsecs in userspace.
Get "system" time in ticks FIXME see https://proj.fmtc.be/orocos-bugzilla/show_bug.cgi?id=60
Definition at line 134 of file fosi.h.
References rtos_get_time_ns().
Definition at line 149 of file fosi.h.
References win32_nanosleep().
int setenv | ( | const char * | name, |
const char * | value, | ||
int | overwrite | ||
) |
RTT_API int usleep | ( | unsigned int | us | ) |
Definition at line 58 of file fosi.cpp.
References win32_nanosleep().
Referenced by RTT::os::rtai_thread_wrapper().
|
inline |
Definition at line 139 of file fosi.h.
References rtos_get_time_ns().
Referenced by rtos_nanosleep(), and usleep().