![]() |
CC3200 Peripheral Driver Library User's Guide
1.2.0
|
Functions | |
tBoolean | WatchdogRunning (unsigned long ulBase) |
void | WatchdogEnable (unsigned long ulBase) |
void | WatchdogLock (unsigned long ulBase) |
void | WatchdogUnlock (unsigned long ulBase) |
tBoolean | WatchdogLockState (unsigned long ulBase) |
void | WatchdogReloadSet (unsigned long ulBase, unsigned long ulLoadVal) |
unsigned long | WatchdogReloadGet (unsigned long ulBase) |
unsigned long | WatchdogValueGet (unsigned long ulBase) |
void | WatchdogIntRegister (unsigned long ulBase, void(*pfnHandler)(void)) |
void | WatchdogIntUnregister (unsigned long ulBase) |
unsigned long | WatchdogIntStatus (unsigned long ulBase, tBoolean bMasked) |
void | WatchdogIntClear (unsigned long ulBase) |
void | WatchdogStallEnable (unsigned long ulBase) |
void | WatchdogStallDisable (unsigned long ulBase) |
Detailed Description
Function Documentation
void WatchdogEnable | ( | unsigned long | ulBase | ) |
Enables the watchdog timer.
- Parameters
-
ulBase is the base address of the watchdog timer module.
This will enable the watchdog timer counter and interrupt.
- Note
- This function will have no effect if the watchdog timer has been locked.
- See also
- WatchdogLock(), WatchdogUnlock()
- Returns
- None.
void WatchdogIntClear | ( | unsigned long | ulBase | ) |
Clears the watchdog timer interrupt.
- Parameters
-
ulBase is the base address of the watchdog timer module.
The watchdog timer interrupt source is cleared, so that it no longer asserts.
- Note
- Because there is a write buffer in the Cortex-M3 processor, it may take several clock cycles before the interrupt source is actually cleared. Therefore, it is recommended that the interrupt source be cleared early in the interrupt handler (as opposed to the very last action) to avoid returning from the interrupt handler before the interrupt source is actually cleared. Failure to do so may result in the interrupt handler being immediately reentered (because the interrupt controller still sees the interrupt source asserted).
- Returns
- None.
void WatchdogIntRegister | ( | unsigned long | ulBase, |
void(*)(void) | pfnHandler | ||
) |
Registers an interrupt handler for watchdog timer interrupt.
- Parameters
-
ulBase is the base address of the watchdog timer module. pfnHandler is a pointer to the function to be called when the watchdog timer interrupt occurs.
This function does the actual registering of the interrupt handler. This will enable the global interrupt in the interrupt controller; the watchdog timer interrupt must be enabled via WatchdogEnable(). It is the interrupt handler's responsibility to clear the interrupt source via WatchdogIntClear().
- See also
- IntRegister() for important information about registering interrupt handlers.
- Note
- This function will only register the standard watchdog interrupt handler. To register the NMI watchdog handler, use IntRegister() to register the handler for the FAULT_NMI interrupt.
- Returns
- None.
unsigned long WatchdogIntStatus | ( | unsigned long | ulBase, |
tBoolean | bMasked | ||
) |
Gets the current watchdog timer interrupt status.
- Parameters
-
ulBase is the base address of the watchdog timer module. bMasked is false if the raw interrupt status is required and true if the masked interrupt status is required.
This returns the interrupt status for the watchdog timer module. Either the raw interrupt status or the status of interrupt that is allowed to reflect to the processor can be returned.
- Returns
- Returns the current interrupt status, where a 1 indicates that the watchdog interrupt is active, and a 0 indicates that it is not active.
void WatchdogIntUnregister | ( | unsigned long | ulBase | ) |
Unregisters an interrupt handler for the watchdog timer interrupt.
- Parameters
-
ulBase is the base address of the watchdog timer module.
This function does the actual unregistering of the interrupt handler. This function will clear the handler to be called when a watchdog timer interrupt occurs. This will also mask off the interrupt in the interrupt controller so that the interrupt handler no longer is called.
- See also
- IntRegister() for important information about registering interrupt handlers.
- Note
- This function will only unregister the standard watchdog interrupt handler. To unregister the NMI watchdog handler, use IntUnregister() to unregister the handler for the FAULT_NMI interrupt.
- Returns
- None.
void WatchdogLock | ( | unsigned long | ulBase | ) |
Enables the watchdog timer lock mechanism.
- Parameters
-
ulBase is the base address of the watchdog timer module.
Locks out write access to the watchdog timer configuration registers.
- Returns
- None.
tBoolean WatchdogLockState | ( | unsigned long | ulBase | ) |
Gets the state of the watchdog timer lock mechanism.
- Parameters
-
ulBase is the base address of the watchdog timer module.
Returns the lock state of the watchdog timer registers.
- Returns
- Returns true if the watchdog timer registers are locked, and false if they are not locked.
unsigned long WatchdogReloadGet | ( | unsigned long | ulBase | ) |
Gets the watchdog timer reload value.
- Parameters
-
ulBase is the base address of the watchdog timer module.
This function gets the value that is loaded into the watchdog timer when the count reaches zero for the first time.
- See also
- WatchdogReloadSet()
- Returns
- None.
void WatchdogReloadSet | ( | unsigned long | ulBase, |
unsigned long | ulLoadVal | ||
) |
Sets the watchdog timer reload value.
- Parameters
-
ulBase is the base address of the watchdog timer module. ulLoadVal is the load value for the watchdog timer.
This function sets the value to load into the watchdog timer when the count reaches zero for the first time; if the watchdog timer is running when this function is called, then the value will be immediately loaded into the watchdog timer counter. If the ulLoadVal parameter is 0, then an interrupt is immediately generated.
- Note
- This function will have no effect if the watchdog timer has been locked.
- Returns
- None.
tBoolean WatchdogRunning | ( | unsigned long | ulBase | ) |
Determines if the watchdog timer is enabled.
- Parameters
-
ulBase is the base address of the watchdog timer module.
This will check to see if the watchdog timer is enabled.
- Returns
- Returns true if the watchdog timer is enabled, and false if it is not.
void WatchdogStallDisable | ( | unsigned long | ulBase | ) |
Disables stalling of the watchdog timer during debug events.
- Parameters
-
ulBase is the base address of the watchdog timer module.
This function disables the debug mode stall of the watchdog timer. By doing so, the watchdog timer continues to count regardless of the processor debug state.
- Returns
- None.
void WatchdogStallEnable | ( | unsigned long | ulBase | ) |
Enables stalling of the watchdog timer during debug events.
- Parameters
-
ulBase is the base address of the watchdog timer module.
This function allows the watchdog timer to stop counting when the processor is stopped by the debugger. By doing so, the watchdog is prevented from expiring (typically almost immediately from a human time perspective) and resetting the system (if reset is enabled). The watchdog will instead expired after the appropriate number of processor cycles have been executed while debugging (or at the appropriate time after the processor has been restarted).
- Returns
- None.
void WatchdogUnlock | ( | unsigned long | ulBase | ) |
Disables the watchdog timer lock mechanism.
- Parameters
-
ulBase is the base address of the watchdog timer module.
Enables write access to the watchdog timer configuration registers.
- Returns
- None.
unsigned long WatchdogValueGet | ( | unsigned long | ulBase | ) |
Gets the current watchdog timer value.
- Parameters
-
ulBase is the base address of the watchdog timer module.
This function reads the current value of the watchdog timer.
- Returns
- Returns the current value of the watchdog timer.
Generated on Thu Feb 18 2016 13:22:02 for CC3200 Peripheral Driver Library User's Guide by
![doxygen](doxygen.png)