15#include "freertos/FreeRTOS.h"
16#include "freertos/timers.h"
48 if (timer == NULL || cb == NULL) {
160 if (xTimerChangePeriod(timer->
__timer_handle, pdMS_TO_TICKS(new_period_ms), 0) != pdPASS) {
meshx_err_t
MeshX Error Codes.
Logging interface for MeshX with color-coded output.
Header file for MeshX RTOS Timer interface. Provides APIs for creating, starting, stopping,...
struct meshx_rtos_timer meshx_rtos_timer_t
void(* meshx_rtos_timer_callback_t)(void *)
void meshx_os_timer_fire_cb(const void *timer_handle)
meshx_err_t meshx_rtos_timer_stop(meshx_rtos_timer_t *timer)
Stops the RTOS timer.
static void timer_callback(TimerHandle_t xTimer)
Callback function for FreeRTOS timer events.
meshx_err_t meshx_rtos_timer_start(meshx_rtos_timer_t *timer)
Starts the RTOS timer.
meshx_err_t meshx_rtos_timer_delete(meshx_rtos_timer_t *timer)
Deletes the RTOS timer.
meshx_err_t meshx_rtos_timer_change_period(meshx_rtos_timer_t *timer, uint32_t new_period_ms)
Changes the period of the RTOS timer.
meshx_err_t meshx_rtos_timer_reset(meshx_rtos_timer_t *timer)
Resets the RTOS timer.
meshx_err_t meshx_rtos_timer_create(meshx_rtos_timer_t *timer, const char *name, meshx_rtos_timer_callback_t cb, void *arg, uint32_t period_ms, bool reload)
Creates a new RTOS timer.
meshx_rtos_timer_callback_t timer_cb