monoZ docs
MZ_timer.h File Reference

This file contains APIs for create,delete,start and stop of timers. Maximum 5 timers can be created. If create API returns the value 0xFFFF then timer will not create, it means already 5 timers created. More...

#include "MZ_error_handler.h"
#include "MZ_sys_cmsis_os2.h"

Go to the source code of this file.

Macros

#define MZ_TIMER_H_
 Define monoZ Timer. More...
 
#define AT_TIME_1SEC   (1000)
 Define 1 Second AT command Time. More...
 
#define AT_TIME_2SEC   (AT_TIME_1SEC * 2)
 Define 2 Second AT command Time. More...
 
#define AT_TIME_5SEC   (AT_TIME_1SEC * 5)
 Define 5 Second AT command Time. More...
 
#define AT_TIME_10SEC   (AT_TIME_1SEC * 10)
 Define 10 Second AT command Time. More...
 
#define AT_TIME_15SEC   (AT_TIME_1SEC * 15)
 Define 15 Second AT command Time. More...
 
#define AT_TIME_20SEC   (AT_TIME_1SEC * 20)
 Define 20 Second AT command Time. More...
 
#define AT_TIME_25SEC   (AT_TIME_1SEC * 25)
 Define 25 Second AT command Time. More...
 
#define AT_TIME_30SEC   (AT_TIME_1SEC * 30)
 Define 30 Second AT command Time. More...
 
#define AT_TIME_1MIN   (AT_TIME_1SEC * 60)
 Define 60 Second AT command Time. More...
 
#define AT_TIME_2MIN   (AT_TIME_1MIN * 2)
 Define 2 Min AT command Time. More...
 
#define AT_TIME_5MIN   (AT_TIME_1MIN * 5)
 Define 5 Min Second AT command Time. More...
 
#define AT_TIME_10MIN   (AT_TIME_1MIN * 10)
 Define 10 Min AT command Time. More...
 
#define MZ_TIMER_NOT_AVAILABLE   (0xFFFF)
 Defines Availability of Monoz Timer. More...
 

Typedefs

typedef mz_timer_fp mz_tm_cb
 [TODO] More...
 

Enumerations

enum  en_mz_tm { MZ_TM_EMPTY , MZ_TM_START , MZ_TM_RUNNING , MZ_TM_STOP }
 Enumeration for monoZ Timer. More...
 

Functions

size_t mz_tm_create (char *_name, TickType_t _tick, UBaseType_t _auto, mz_tm_cb _cb)
 Function to Create a Monoz Timer. More...
 
size_t mz_tm_create_one (char *_name, TickType_t _tick, mz_tm_cb _cb)
 Function to Create a One Shot Timer. More...
 
size_t mz_tm_create_recursive (char *_name, TickType_t _tick, mz_tm_cb _cb)
 Function to Create a Recursive Timer. More...
 
mz_error_t mz_tm_start (size_t _id)
 Function to Start the Timer. More...
 
mz_error_t mz_tm_create_start (char *_name, TickType_t _tick, UBaseType_t _auto, mz_tm_cb _cb)
 Function to Create and Start Timers. More...
 
mz_error_t mz_tm_create_start_one (char *_name, TickType_t _tick, mz_tm_cb _cb)
 Function to Create and Start Recursive timers. More...
 
mz_error_t mz_tm_create_start_recursive (char *_name, TickType_t _tick, mz_tm_cb _cb)
 Function to Create and Start One Shot Timers. More...
 
mz_error_t mz_tm_stop (size_t _id)
 Function to STOP the Timer. More...
 
mz_error_t mz_tm_delete (size_t _id)
 Function to Delete the Timer. More...
 

Detailed Description

This file contains APIs for create,delete,start and stop of timers. Maximum 5 timers can be created. If create API returns the value 0xFFFF then timer will not create, it means already 5 timers created.

Date
Apr 27, 2021
Author
SKM

Definition in file MZ_timer.h.

Macro Definition Documentation

◆ MZ_TIMER_H_

#define MZ_TIMER_H_

Define monoZ Timer.

Definition at line 10 of file MZ_timer.h.

◆ AT_TIME_1SEC

#define AT_TIME_1SEC   (1000)

Define 1 Second AT command Time.

Definition at line 18 of file MZ_timer.h.

◆ AT_TIME_2SEC

#define AT_TIME_2SEC   (AT_TIME_1SEC * 2)

Define 2 Second AT command Time.

Definition at line 19 of file MZ_timer.h.

◆ AT_TIME_5SEC

#define AT_TIME_5SEC   (AT_TIME_1SEC * 5)

Define 5 Second AT command Time.

Definition at line 20 of file MZ_timer.h.

◆ AT_TIME_10SEC

#define AT_TIME_10SEC   (AT_TIME_1SEC * 10)

Define 10 Second AT command Time.

Definition at line 21 of file MZ_timer.h.

◆ AT_TIME_15SEC

#define AT_TIME_15SEC   (AT_TIME_1SEC * 15)

Define 15 Second AT command Time.

Definition at line 22 of file MZ_timer.h.

◆ AT_TIME_20SEC

#define AT_TIME_20SEC   (AT_TIME_1SEC * 20)

Define 20 Second AT command Time.

Definition at line 23 of file MZ_timer.h.

◆ AT_TIME_25SEC

#define AT_TIME_25SEC   (AT_TIME_1SEC * 25)

Define 25 Second AT command Time.

Definition at line 24 of file MZ_timer.h.

◆ AT_TIME_30SEC

#define AT_TIME_30SEC   (AT_TIME_1SEC * 30)

Define 30 Second AT command Time.

Definition at line 25 of file MZ_timer.h.

◆ AT_TIME_1MIN

#define AT_TIME_1MIN   (AT_TIME_1SEC * 60)

Define 60 Second AT command Time.

Definition at line 26 of file MZ_timer.h.

◆ AT_TIME_2MIN

#define AT_TIME_2MIN   (AT_TIME_1MIN * 2)

Define 2 Min AT command Time.

Definition at line 27 of file MZ_timer.h.

◆ AT_TIME_5MIN

#define AT_TIME_5MIN   (AT_TIME_1MIN * 5)

Define 5 Min Second AT command Time.

Definition at line 28 of file MZ_timer.h.

◆ AT_TIME_10MIN

#define AT_TIME_10MIN   (AT_TIME_1MIN * 10)

Define 10 Min AT command Time.

Definition at line 29 of file MZ_timer.h.

◆ MZ_TIMER_NOT_AVAILABLE

#define MZ_TIMER_NOT_AVAILABLE   (0xFFFF)

Defines Availability of Monoz Timer.

Definition at line 42 of file MZ_timer.h.

Typedef Documentation

◆ mz_tm_cb

[TODO]

Definition at line 48 of file MZ_timer.h.

Enumeration Type Documentation

◆ en_mz_tm

enum en_mz_tm

Enumeration for monoZ Timer.

Enumerator
MZ_TM_EMPTY 

monoZ timer empty

MZ_TM_START 

monoZ timer start

MZ_TM_RUNNING 

monoZ timer running

MZ_TM_STOP 

monoZ timer stop

Definition at line 34 of file MZ_timer.h.