1.29.5.6 OSC32KCTRL_CFD_CALLBACK Typedef
C
typedef void (*OSC32KCTRL_CFD_CALLBACK)(uintptr_t context);
Summary
Defines the data type and function signature for the External 32KHz Oscillator clock failure detection callback function.
Description
This data type defines the function signature for the External 32KHz Oscillator clock failure detection callback function. The External 32KHz Oscillator will call back the client's function with this signature when it needs to notify the client of oscillator failure. The context parameter is an application defined data object specified at the time of registering the callback function and is returned in the context parameter of the callback function.
Precondition
The CLOCK_Initialize() initialize function should have been called. The callback function should have been registered through OSC32KCTRL_CallbackRegister() function.
Parameters
Param | Description |
---|---|
context | Allows the caller to provide a context value (usually a pointer to the callers context for multi-instance clients). |
Returns
None.
Example
void MyOscillatorFailureCallback (uintptr_t context ) { // This means the 32KHz clock has failed. } // Register the callback function. Specify the context as NULL. OSC32KCTRL_CallbackRegister(MyOscillatorFailureCallback, (uintptr_t)NULL);
Remarks
None.