#include <stdio.h>
#include <stdlib.h>
#include <stdarg.h>
#include <sys/types.h>
#include <sched.h>
#include <assert.h>
#include <limits.h>
#include <float.h>
#include "../oro_limits.h"
#include "../../rtt-config.h"
#include <rtai_config.h>
#include <rtai_lxrt.h>
#include <rtai_sem.h>
Go to the source code of this file.
#define __LXRT_USERSPACE__ |
Definition at line 100 of file lxrt/fosi.h.
#define _GNU_SOURCE |
This file translates the FOSI (Framework Operating System Interface) from orocos calls to native RTOS calls
Definition at line 30 of file lxrt/fosi.h.
#define _XOPEN_SOURCE 600 |
Definition at line 35 of file lxrt/fosi.h.
#define CHK_LXRT_CALL | ( | ) |
Definition at line 165 of file lxrt/fosi.h.
#define CHK_LXRT_PTR | ( | a | ) |
Definition at line 166 of file lxrt/fosi.h.
#define HAVE_FOSI_API |
Definition at line 38 of file lxrt/fosi.h.
#define ORO_SCHED_OTHER 1 /** LXRT Soft real-time */ |
Definition at line 127 of file lxrt/fosi.h.
#define ORO_SCHED_RT 0 /** LXRT Hard real-time */ |
Definition at line 126 of file lxrt/fosi.h.
#define SCHED_LXRT_HARD 0 /** LXRT Hard real-time */ |
Definition at line 124 of file lxrt/fosi.h.
#define SCHED_LXRT_SOFT 1 /** LXRT Soft real-time */ |
Definition at line 125 of file lxrt/fosi.h.
typedef long long NANO_TIME |
Definition at line 108 of file lxrt/fosi.h.
typedef struct oro_rtai_cond_t rt_cond_t |
typedef rt_sem_t rt_mutex_t |
Definition at line 103 of file lxrt/fosi.h.
typedef rt_sem_t rt_rec_mutex_t |
Definition at line 104 of file lxrt/fosi.h.
typedef struct oro_rtai_sem_t rt_sem_t |
typedef CND RTOS_RTAI_CND |
Definition at line 71 of file lxrt/fosi.h.
typedef SEM RTOS_RTAI_SEM |
Definition at line 70 of file lxrt/fosi.h.
typedef RT_TASK RTOS_RTAI_TASK |
Definition at line 69 of file lxrt/fosi.h.
typedef long long TICK_TIME |
Definition at line 109 of file lxrt/fosi.h.
typedef struct timespec TIME_SPEC |
Definition at line 110 of file lxrt/fosi.h.
TICK_TIME nano2ticks | ( | NANO_TIME | nano | ) | [inline] |
Time conversions from nano seconds to system ticks.
Definition at line 175 of file lxrt/fosi.h.
static int rtos_cond_broadcast | ( | rt_cond_t * | cond | ) | [inline, static] |
Definition at line 364 of file lxrt/fosi.h.
static int rtos_cond_destroy | ( | rt_cond_t * | cond | ) | [inline, static] |
Definition at line 338 of file lxrt/fosi.h.
static int rtos_cond_init | ( | rt_cond_t * | cond | ) | [inline, static] |
Definition at line 331 of file lxrt/fosi.h.
static int rtos_cond_timedwait | ( | rt_cond_t * | cond, |
rt_mutex_t * | mutex, | ||
NANO_TIME | abstime | ||
) | [inline, static] |
Definition at line 353 of file lxrt/fosi.h.
static int rtos_cond_wait | ( | rt_cond_t * | cond, |
rt_mutex_t * | mutex | ||
) | [inline, static] |
Definition at line 344 of file lxrt/fosi.h.
static void rtos_disable_rt_warning | ( | ) | [inline, static] |
Definition at line 450 of file lxrt/fosi.h.
static void rtos_enable_rt_warning | ( | ) | [inline, static] |
Definition at line 446 of file lxrt/fosi.h.
NANO_TIME rtos_get_time_ns | ( | void | ) | [inline] |
Get "system" time in nanoseconds
Definition at line 169 of file lxrt/fosi.h.
TICK_TIME rtos_get_time_ticks | ( | void | ) | [inline] |
Get "system" time in ticks FIXME see <https://proj.fmtc.be/orocos-bugzilla/show_bug.cgi?id=60>
Definition at line 171 of file lxrt/fosi.h.
static int rtos_mutex_destroy | ( | rt_mutex_t * | m | ) | [inline, static] |
Definition at line 262 of file lxrt/fosi.h.
static int rtos_mutex_init | ( | rt_mutex_t * | m | ) | [inline, static] |
Definition at line 255 of file lxrt/fosi.h.
static int rtos_mutex_lock | ( | rt_mutex_t * | m | ) | [inline, static] |
Definition at line 282 of file lxrt/fosi.h.
static int rtos_mutex_lock_until | ( | rt_mutex_t * | m, |
NANO_TIME | abs_time | ||
) | [inline, static] |
Definition at line 306 of file lxrt/fosi.h.
static int rtos_mutex_rec_destroy | ( | rt_rec_mutex_t * | m | ) | [inline, static] |
Definition at line 276 of file lxrt/fosi.h.
static int rtos_mutex_rec_init | ( | rt_rec_mutex_t * | m | ) | [inline, static] |
Definition at line 268 of file lxrt/fosi.h.
static int rtos_mutex_rec_lock | ( | rt_rec_mutex_t * | m | ) | [inline, static] |
Definition at line 288 of file lxrt/fosi.h.
static int rtos_mutex_rec_lock_until | ( | rt_rec_mutex_t * | m, |
NANO_TIME | abs_time | ||
) | [inline, static] |
Definition at line 312 of file lxrt/fosi.h.
static int rtos_mutex_rec_trylock | ( | rt_rec_mutex_t * | m | ) | [inline, static] |
Definition at line 300 of file lxrt/fosi.h.
static int rtos_mutex_rec_unlock | ( | rt_rec_mutex_t * | m | ) | [inline, static] |
Definition at line 325 of file lxrt/fosi.h.
static int rtos_mutex_trylock | ( | rt_mutex_t * | m | ) | [inline, static] |
Definition at line 294 of file lxrt/fosi.h.
static int rtos_mutex_unlock | ( | rt_mutex_t * | m | ) | [inline, static] |
Definition at line 319 of file lxrt/fosi.h.
int rtos_nanosleep | ( | const TIME_SPEC * | rqtp, |
TIME_SPEC * | rmtp | ||
) | [inline] |
Definition at line 178 of file lxrt/fosi.h.
int rtos_printf | ( | const char * | fmt, |
... | |||
) | [inline] |
'real-time' print function.
Definition at line 370 of file lxrt/fosi.h.
static int rtos_sem_destroy | ( | rt_sem_t * | m | ) | [inline, static] |
Definition at line 193 of file lxrt/fosi.h.
static int rtos_sem_init | ( | rt_sem_t * | m, |
int | value | ||
) | [inline, static] |
Definition at line 185 of file lxrt/fosi.h.
static int rtos_sem_signal | ( | rt_sem_t * | m | ) | [inline, static] |
Definition at line 199 of file lxrt/fosi.h.
static int rtos_sem_trywait | ( | rt_sem_t * | m | ) | [inline, static] |
Definition at line 211 of file lxrt/fosi.h.
static int rtos_sem_value | ( | rt_sem_t * | m | ) | [inline, static] |
Definition at line 217 of file lxrt/fosi.h.
static int rtos_sem_wait | ( | rt_sem_t * | m | ) | [inline, static] |
Definition at line 205 of file lxrt/fosi.h.
static int rtos_sem_wait_timed | ( | rt_sem_t * | m, |
NANO_TIME | delay | ||
) | [inline, static] |
Definition at line 223 of file lxrt/fosi.h.
static int rtos_sem_wait_until | ( | rt_sem_t * | m, |
NANO_TIME | when | ||
) | [inline, static] |
Definition at line 239 of file lxrt/fosi.h.
NANO_TIME ticks2nano | ( | TICK_TIME | count | ) | [inline] |
Time conversions from system ticks to nano seconds.
Definition at line 176 of file lxrt/fosi.h.
TIME_SPEC ticks2timespec | ( | TICK_TIME | hrt | ) | [inline] |
Definition at line 144 of file lxrt/fosi.h.
TICK_TIME ticksPerSec | ( | void | ) | [inline] |
Definition at line 173 of file lxrt/fosi.h.
const NANO_TIME InfiniteNSecs = LLONG_MAX [static] |
Definition at line 121 of file lxrt/fosi.h.
const double InfiniteSeconds = DBL_MAX [static] |
Definition at line 122 of file lxrt/fosi.h.
const TICK_TIME InfiniteTicks = LLONG_MAX [static] |
Definition at line 120 of file lxrt/fosi.h.