PDK API Guide for J721E
ClockP.h File Reference

Introduction

Clock module for the RTOS Porting Interface. This implements the software timer support. For hardware timer support, please check TimerP.h.

============================================================================

The ClockP module can be used to create a software (OS) timer and configure it to invoke a User callback when timer expires.

The timer can be configured as a one-shot or a continuous mode timer.


Go to the source code of this file.

Data Structures

struct  ClockP_Params
 Basic ClockP Parameters. More...
 

Typedefs

typedef void * ClockP_Handle
 Opaque client reference to an instance of a ClockP. More...
 
typedef void(* ClockP_FxnCallback) (void *args)
 Callback that is called when the clock expires. More...
 

Enumerations

enum  ClockP_Status { ClockP_OK = 0, ClockP_FAILURE = (-(int32_t)1) }
 Status codes for ClockP APIs. More...
 
enum  ClockP_RunMode { ClockP_RunMode_ONESHOT = ((uint8_t) 0), ClockP_RunMode_CONTINUOUS = ((uint8_t) 1) }
 Timer runtime modes for ClockP APIs. More...
 
enum  ClockP_StartMode { ClockP_StartMode_USER = ((uint8_t) 0), ClockP_StartMode_AUTO = ((uint8_t) 1) }
 Timer start modes for ClockP APIs. More...
 

Functions

void ClockP_Params_init (ClockP_Params *params)
 Initialize params structure to default values. More...
 
ClockP_Handle ClockP_create (ClockP_FxnCallback clockfxn, const ClockP_Params *params)
 Function to create a clock. More...
 
ClockP_Status ClockP_delete (ClockP_Handle handle)
 Function to delete a clock. More...
 
ClockP_Status ClockP_start (ClockP_Handle handle)
 Function to start a clock. More...
 
ClockP_Status ClockP_stop (ClockP_Handle handle)
 Function to stop a clock. More...