M480 BSP V3.05.006
The Board Support Package for M480 Series
wwdt.c
Go to the documentation of this file.
1/**************************************************************************/
9#include "NuMicro.h"
10
11
52void WWDT_Open(uint32_t u32PreScale,
53 uint32_t u32CmpValue,
54 uint32_t u32EnableInt)
55{
56 WWDT->CTL = u32PreScale |
57 (u32CmpValue << WWDT_CTL_CMPDAT_Pos) |
58 ((u32EnableInt == TRUE) ? WWDT_CTL_INTEN_Msk : 0U) |
60 return;
61}
62 /* end of group WWDT_EXPORTED_FUNCTIONS */
64 /* end of group WWDT_Driver */
66 /* end of group Standard_Driver */
68
69/*** (C) COPYRIGHT 2016 Nuvoton Technology Corp. ***/
NuMicro peripheral access layer header file.
#define TRUE
Boolean true, define to use in API parameters or return value.
Definition: M480.h:608
#define WWDT
Definition: M480.h:399
#define WWDT_CTL_WWDTEN_Msk
Definition: wwdt_reg.h:210
#define WWDT_CTL_CMPDAT_Pos
Definition: wwdt_reg.h:218
#define WWDT_CTL_INTEN_Msk
Definition: wwdt_reg.h:213
void WWDT_Open(uint32_t u32PreScale, uint32_t u32CmpValue, uint32_t u32EnableInt)
Open WWDT and start counting.
Definition: wwdt.c:52