1.39.17.8 RTC_Timer32CallbackRegister Function

C

void RTC_Timer32CallbackRegister ( RTC_TIMER32_CALLBACK callback, uintptr_t context )

Summary

Register the callback function to be called when an 32-bit Timer Interrupt occurs.

Description

This function registers the callback function that the library will call when an interrupt occurs. The library will return the event that has caused the interrupt and the application specified context in the callback function.

Precondition

The RTC_Initialize() function should have been called to initialize the RTC module. The module should have been configured for 32-bit Timer Counter operation in MHC. The library should have been configured for Interrupt mode operation.

Parameters

Param Description
callback A pointer to a function with a calling signature defined by the RTC_TIMER32_CALLBACK data type. Passing a NULL value disables the callback
context A value (usually a pointer) that passed into the callback function when the callback function is called

Returns

None.

Example

// Refer to the description of the RTC_TIMER32_CALLBACK datatype for
// example usage of this function.

Remarks

To disable the callback function, pass a NULL for the callback parameter. See the RTC_TIMER32_CALLBACK type definition for additional information.