Application Note
20 of 33
002-33887 Rev. *A
2022-05-25
Using the Watchdog Timer in XMC7000 family MCUs
Multi-counter WDT
Code preview:
This code is auto-generated after the configuration in the Device Configurator.
shows an example program of the MCWDT configuration part. For details of the interrupt and
initial
fault setting procedure, see the “Interrupt and Fault Report Structure” section in AN234226
listed in
Code Listing 2
Example program to configure MCWDT
cy_stc_sysint_t
mcwdt_irq_cfg =
{
.intrSrc = ((
NvicMux3_IRQn
<< 16) |
srss_interrupt_mcwdt_0_IRQn
),
.intrPriority = 2UL
};
int
main
(
void
)
{
cy_rslt_t
result;
cy_en_mcwdt_status_t
mcwdt_init_status =
CY_MCWDT_SUCCESS
;
/* Initialize the device and board peripherals */
result = cybsp_init() ;
/* BSP initialization failed. Stop program execution */
if
(result != CY_RSLT_SUCCESS)
{
CY_ASSERT(0);
}