|
FreeRTOS:
POSIX
|
| Return to main page ↑ |
Implementation of timer functions in time.h. More...
#include <stddef.h>#include "FreeRTOS_POSIX.h"#include "FreeRTOS_POSIX/errno.h"#include "FreeRTOS_POSIX/pthread.h"#include "FreeRTOS_POSIX/signal.h"#include "FreeRTOS_POSIX/time.h"#include "FreeRTOS_POSIX/utils.h"#include "timers.h"Data Structures | |
| struct | timer_internal_t |
| Internal timer structure. More... | |
Macros | |
| #define | TIMESPEC_IS_ZERO(xTimespec) ( xTimespec.tv_sec == 0 && xTimespec.tv_nsec == 0 ) |
| #define | TIMESPEC_IS_NOT_ZERO(xTimespec) ( !( TIMESPEC_IS_ZERO( xTimespec ) ) ) |
Functions | |
| void | prvTimerCallback (TimerHandle_t xOpaqueTimerHandle) |
| int | timer_create (clockid_t clockid, struct sigevent *evp, timer_t *timerid) |
| Create a per-process timer. More... | |
| int | timer_delete (timer_t timerid) |
| Delete a per-process timer. More... | |
| int | timer_getoverrun (timer_t timerid) |
| Get the timer overrun count. More... | |
| int | timer_settime (timer_t timerid, int flags, const struct itimerspec *value, struct itimerspec *ovalue) |
| Set the time until the next expiration of the timer. More... | |
| int | timer_gettime (timer_t timerid, struct itimerspec *value) |
| Get the amount of time until the timer expires. More... | |
Implementation of timer functions in time.h.
| #define TIMESPEC_IS_ZERO | ( | xTimespec | ) | ( xTimespec.tv_sec == 0 && xTimespec.tv_nsec == 0 ) |
Check for 0.
| #define TIMESPEC_IS_NOT_ZERO | ( | xTimespec | ) | ( !( TIMESPEC_IS_ZERO( xTimespec ) ) ) |
Check for not 0.
Create a per-process timer.
http://pubs.opengroup.org/onlinepubs/9699919799/functions/timer_create.html
| 0 | - Upon successful completion, with location referenced by timerid updated. |
| -1 | - If an error occurs. errno is also set. |
| int timer_delete | ( | timer_t | timerid | ) |
Delete a per-process timer.
http://pubs.opengroup.org/onlinepubs/9699919799/functions/timer_delete.html
| 0 | - Upon successful completion. |
| int timer_getoverrun | ( | timer_t | timerid | ) |
Get the timer overrun count.
http://pubs.opengroup.org/onlinepubs/9699919799/functions/timer_getoverrun.html
| 0 | - Always return 0, since signals are not supported. |
| int timer_settime | ( | timer_t | timerid, |
| int | flags, | ||
| const struct itimerspec * | value, | ||
| struct itimerspec * | ovalue | ||
| ) |
Set the time until the next expiration of the timer.
http://pubs.opengroup.org/onlinepubs/9699919799/functions/timer_settime.html
| 0 | - Upon successful completion. |
| -1 | - An error occurred, errno is also set. |
| int timer_gettime | ( | timer_t | timerid, |
| struct itimerspec * | value | ||
| ) |
Get the amount of time until the timer expires.
http://pubs.opengroup.org/onlinepubs/9699919799/functions/timer_gettime.html
| 0 | - Upon successful completion. |