RTC_SetAlarmParamAsync

Syntax

#include <nitro/rtc.h>
RTCResult RTC_SetAlarmParamAsync(
            RTCAlarmChan		chan,
            const RTCAlarmParam*    param,
            RTCCallback             callback,
            void*                   arg );

Arguments

chan Uses RTCAlarmChan to specify the alarm channel.
param Pointer to RTCAlarmParam containing parameters to set.
callback Pointer to the callback function. This callback is called from within the interrupt handler.
arg Argument to pass to the callback function.

Return Values

If the request succeeds, it returns 0. If the request fails, it returns a numeric value other than 0.

Description

Asynchronously writes alarm interrupt parameter values to the real-time clock. This function sends alarm interrupt data to ARM7 and returns the process result without waiting for a response from the processor. To get the result from the processor, you must use the result argument. If this function fails, no operation is performed and no user callback function is called.

Note

Do not define parameter values of nonexistent days of the week or times. Values are set to the RTC as specified by the param argument asynchronously with respect to the function. Do not use this variable for anything else until a user callback function confirms the completion of this asynchronous operation. Unless the RTC alarm interrupt permission status is permit, it is not possible to write parameter values to the real-time clock, causing any attempted call of this function to fail.

See Also

RTC_SetAlarmParam, RTC_GetAlarmParam, RTC_GetAlarmParamAsync, RTCResult, RTCAlarmChan, RTCAlarmParam, RTCCallback

Revision History

2005/06/27 Added a statement about callbacks being invoked from the interrupt handler.
2005/03/08 Standardized use of the term "interrupt" in Japanese.
2004/05/18 Initial version.


CONFIDENTIAL