1.2.11.4.19 SYS_TIME_TimerDestroy Function
1.2.11.4.19 C
SYS_TIME_RESULT SYS_TIME_TimerDestroy ( SYS_TIME_HANDLE handle)
1.2.11.4.19 Summary
Destroys/deallocates a software timer instance.
1.2.11.4.19 Description
This function deletes and deallocates a software timer instance, stopping its counter and releasing the associated resources.
1.2.11.4.19 Precondition
The SYS_TIME_Initialize and a valid handle to the software timer to be destroyed must be available.
1.2.11.4.19 Parameters
| Parameters | Description |
|---|---|
| handle | Handle to a software timer instance |
1.2.11.4.19 Returns
SYS_TIME_SUCCESS - If the given software was successfully destroyed.
SYS_TIME_ERROR - If an error occurred or the given handle was invalid.
1.2.11.4.19 Example
// "timer" is the handle to the software timer to be destroyed.
if (SYS_TIME_TimerDestroy(timer) != SYS_TIME_SUCCESS)
{
// Handle Error
}
1.2.11.4.19 Remarks
Released timer resources can be reused by other clients. Single shot timers are auto destroyed on expiry. Calling SYS_TIME_DelayIsComplete auto destroys the delay timer if it has expired.
