11#ifndef __TAL_SW_TIMER_H__
12#define __TAL_SW_TIMER_H__
14#include "tuya_cloud_types.h"
35typedef PVOID_T TIMER_ID;
37typedef VOID_T (* TAL_TIMER_CB)(TIMER_ID timer_id, VOID_T *arg);
INT_T tal_sw_timer_get_num(VOID_T)
Get timer node currently
OPERATE_RET tal_sw_timer_create(TAL_TIMER_CB func, VOID_T *arg, TIMER_ID *timer_id)
create a software timer
BOOL_T tal_sw_timer_is_running(TIMER_ID timer_id)
Identify the software timer is running
OPERATE_RET tal_sw_timer_start(TIMER_ID timer_id, TIME_MS time_ms, TIMER_TYPE timer_type)
Start the software timer
OPERATE_RET tal_sw_timer_stop(TIMER_ID timer_id)
Stop the software timer
TIMER_TYPE
the type of timer
Definition: tal_sw_timer.h:26
OPERATE_RET tal_sw_timer_release(VOID_T)
Release all resource of the software timer
OPERATE_RET tal_sw_timer_trigger(TIMER_ID timer_id)
Trigger the software timer
OPERATE_RET tal_sw_timer_remain_time_get(TIMER_ID timer_id, UINT32_T *remain_time)
Identify the software timer is running
OPERATE_RET tal_sw_timer_init(VOID_T)
Initializing the software timer
OPERATE_RET tal_sw_timer_delete(TIMER_ID timer_id)
Delete the software timer