rt_get_time(3)

rt_get_time3

Get the current time

Usage

#define MODULE
#include <linux/module.h>
#include <linux/kernel.h>
#include <linux/version.h>
#include <linux/errno.h>
#include <linux/rt_sched.h>

RTIME rt_get_time(void);

Warning

This is RTL v1.x compatibility function. Please do not use it for new programs.

Overview

rt_get_time returns the number of real-time clock ticks since system bootup. This is primarily helpful in conjunction with the defined constant RT_TICKS_PER_SECOND for scheduling real-time tasks. For example, a time interval of 100 msecs could be referred to as

RTIME intvl = (RT_TICKS_PER_SECOND / 10);

Then, for example,

rt_task_make_periodic(&mytask, rt_get_time() + 5 * intvl, intvl);

would schedule mytask to run at 100 msec intervals starting 500 msec from the present time.

Return value

The number of clock ticks since system bootup time is returned.

Errors

None.

From rtlinux 2.0rel-1 in Debian 2.2 (Potato). Parsed by carta from the page's man source.