Loading...
Searching...
No Matches
timers.h
1/*
2 * SPDX-FileCopyrightText: 2019 Gunar Schorcht
3 * SPDX-License-Identifier: LGPL-2.1-only
4 */
5
6/*
7 * FreeRTOS to RIOT-OS adaption module for source code compatibility
8 */
9
10#pragma once
11
12#ifndef DOXYGEN
13
14#include "freertos/FreeRTOS.h"
15
16#ifdef __cplusplus
17extern "C" {
18#endif
19
20typedef void* TimerHandle_t;
21typedef void (*TimerCallbackFunction_t)(void*);
22#define tmrTIMER_CALLBACK TimerCallbackFunction_t
23
24TimerHandle_t xTimerCreate (const char * const pcTimerName,
25 const TickType_t xTimerPeriod,
26 const UBaseType_t uxAutoReload,
27 void * const pvTimerID,
28 TimerCallbackFunction_t pxCallbackFunction);
29BaseType_t xTimerDelete(TimerHandle_t xTimer, TickType_t xBlockTime);
30BaseType_t xTimerStart (TimerHandle_t xTimer, TickType_t xBlockTime);
31BaseType_t xTimerStop (TimerHandle_t xTimer, TickType_t xBlockTime);
32BaseType_t xTimerReset (TimerHandle_t xTimer, TickType_t xTicksToWait);
33
34void *pvTimerGetTimerID(const TimerHandle_t xTimer);
35
36#ifdef __cplusplus
37}
38#endif
39
40#endif /* DOXYGEN */