MAX32665 Peripheral Driver API
Peripheral Driver API for the MAX32665
wdt.h
1 
6 /* ****************************************************************************
7  * Copyright (C) 2016 Maxim Integrated Products, Inc., All Rights Reserved.
8  *
9  * Permission is hereby granted, free of charge, to any person obtaining a
10  * copy of this software and associated documentation files (the "Software"),
11  * to deal in the Software without restriction, including without limitation
12  * the rights to use, copy, modify, merge, publish, distribute, sublicense,
13  * and/or sell copies of the Software, and to permit persons to whom the
14  * Software is furnished to do so, subject to the following conditions:
15  *
16  * The above copyright notice and this permission notice shall be included
17  * in all copies or substantial portions of the Software.
18  *
19  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
20  * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
21  * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
22  * IN NO EVENT SHALL MAXIM INTEGRATED BE LIABLE FOR ANY CLAIM, DAMAGES
23  * OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
24  * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
25  * OTHER DEALINGS IN THE SOFTWARE.
26  *
27  * Except as contained in this notice, the name of Maxim Integrated
28  * Products, Inc. shall not be used except as stated in the Maxim Integrated
29  * Products, Inc. Branding Policy.
30  *
31  * The mere transfer of this software does not imply any licenses
32  * of trade secrets, proprietary technology, copyrights, patents,
33  * trademarks, maskwork rights, or any other form of intellectual
34  * property whatsoever. Maxim Integrated Products, Inc. retains all
35  * ownership rights.
36  *
37  *************************************************************************** */
38 
39 /* Define to prevent redundant inclusion */
40 #ifndef _WDT_H_
41 #define _WDT_H_
42 
43 /* **** Includes **** */
44 #include <stdint.h>
45 #include "mxc_device.h"
46 #include "wdt_regs.h"
47 
48 #ifdef __cplusplus
49 extern "C" {
50 #endif
51 
58 /* **** Definitions **** */
59 
62 typedef enum {
80 
81 /* **** Function Prototypes **** */
82 
89 
96 
103 
110 
116 
122 
128 
134 
140 
146 
152 
159 
165 
172 
178 
181 #ifdef __cplusplus
182 }
183 #endif
184 
185 #endif /* _WDT_H_ */
MXC_WDT_PERIOD_2_18
@ MXC_WDT_PERIOD_2_18
Period 2^18.
Definition: wdt.h:76
MXC_WDT_Disable
void MXC_WDT_Disable(mxc_wdt_regs_t *wdt)
Disable the watchdog timer.
MXC_WDT_PERIOD_2_30
@ MXC_WDT_PERIOD_2_30
Period 2^30.
Definition: wdt.h:64
MXC_WDT_PERIOD_2_25
@ MXC_WDT_PERIOD_2_25
Period 2^25.
Definition: wdt.h:69
MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW22
#define MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW22
Definition: wdt_regs.h:131
MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW24
#define MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW24
Definition: wdt_regs.h:127
MXC_WDT_EnableReset
void MXC_WDT_EnableReset(mxc_wdt_regs_t *wdt)
Enable the watchdog reset.
mxc_wdt_period_t
mxc_wdt_period_t
Watchdog period enumeration. Used to configure the period of the watchdog interrupt.
Definition: wdt.h:62
MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW21
#define MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW21
Definition: wdt_regs.h:133
MXC_WDT_PERIOD_2_16
@ MXC_WDT_PERIOD_2_16
Period 2^16.
Definition: wdt.h:78
MXC_WDT_PERIOD_2_22
@ MXC_WDT_PERIOD_2_22
Period 2^22.
Definition: wdt.h:72
MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW23
#define MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW23
Definition: wdt_regs.h:129
MXC_WDT_ClearResetFlag
void MXC_WDT_ClearResetFlag(mxc_wdt_regs_t *wdt)
Clears the reset flag.
MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW31
#define MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW31
Definition: wdt_regs.h:113
MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW17
#define MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW17
Definition: wdt_regs.h:141
MXC_WDT_GetResetFlag
int MXC_WDT_GetResetFlag(mxc_wdt_regs_t *wdt)
Get the status of the reset flag.
MXC_WDT_SetResetPeriod
void MXC_WDT_SetResetPeriod(mxc_wdt_regs_t *wdt, mxc_wdt_period_t period)
Set the period of the watchdog reset.
MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW29
#define MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW29
Definition: wdt_regs.h:117
MXC_WDT_EnableInt
void MXC_WDT_EnableInt(mxc_wdt_regs_t *wdt)
Enable the watchdog interrupt.
MXC_WDT_Enable
void MXC_WDT_Enable(mxc_wdt_regs_t *wdt)
Enable the watchdog timer.
MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW27
#define MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW27
Definition: wdt_regs.h:121
MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW18
#define MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW18
Definition: wdt_regs.h:139
MXC_WDT_PERIOD_2_21
@ MXC_WDT_PERIOD_2_21
Period 2^21.
Definition: wdt.h:73
MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW28
#define MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW28
Definition: wdt_regs.h:119
MXC_WDT_PERIOD_2_31
@ MXC_WDT_PERIOD_2_31
Period 2^31.
Definition: wdt.h:63
MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW19
#define MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW19
Definition: wdt_regs.h:137
MXC_WDT_PERIOD_2_29
@ MXC_WDT_PERIOD_2_29
Period 2^29.
Definition: wdt.h:65
MXC_WDT_PERIOD_2_24
@ MXC_WDT_PERIOD_2_24
Period 2^24.
Definition: wdt.h:70
MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW25
#define MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW25
Definition: wdt_regs.h:125
MXC_WDT_Init
int MXC_WDT_Init(mxc_wdt_regs_t *wdt)
Initialize the Watchdog Timer.
MXC_WDT_PERIOD_2_28
@ MXC_WDT_PERIOD_2_28
Period 2^28.
Definition: wdt.h:66
mxc_wdt_regs_t
Definition: wdt_regs.h:88
MXC_WDT_PERIOD_2_20
@ MXC_WDT_PERIOD_2_20
Period 2^20.
Definition: wdt.h:74
MXC_WDT_PERIOD_2_17
@ MXC_WDT_PERIOD_2_17
Period 2^17.
Definition: wdt.h:77
MXC_WDT_ResetTimer
void MXC_WDT_ResetTimer(mxc_wdt_regs_t *wdt)
Reset the watchdog timer.
MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW26
#define MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW26
Definition: wdt_regs.h:123
MXC_WDT_Shutdown
int MXC_WDT_Shutdown(mxc_wdt_regs_t *wdt)
Shutdown the Watchdog Timer.
MXC_WDT_GetIntFlag
int MXC_WDT_GetIntFlag(mxc_wdt_regs_t *wdt)
Get the status of the interrupt flag.
MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW30
#define MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW30
Definition: wdt_regs.h:115
MXC_WDT_DisableInt
void MXC_WDT_DisableInt(mxc_wdt_regs_t *wdt)
Enable the watchdog interrupt.
MXC_WDT_PERIOD_2_27
@ MXC_WDT_PERIOD_2_27
Period 2^27.
Definition: wdt.h:67
MXC_WDT_PERIOD_2_19
@ MXC_WDT_PERIOD_2_19
Period 2^19.
Definition: wdt.h:75
MXC_WDT_SetIntPeriod
void MXC_WDT_SetIntPeriod(mxc_wdt_regs_t *wdt, mxc_wdt_period_t period)
Set the period of the watchdog interrupt.
MXC_WDT_PERIOD_2_26
@ MXC_WDT_PERIOD_2_26
Period 2^26.
Definition: wdt.h:68
MXC_WDT_PERIOD_2_23
@ MXC_WDT_PERIOD_2_23
Period 2^23.
Definition: wdt.h:71
MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW16
#define MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW16
Definition: wdt_regs.h:143
MXC_WDT_DisableReset
void MXC_WDT_DisableReset(mxc_wdt_regs_t *wdt)
Enable the watchdog reset.
MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW20
#define MXC_S_WDT_CTRL_INT_PERIOD_WDT2POW20
Definition: wdt_regs.h:135
MXC_WDT_ClearIntFlag
void MXC_WDT_ClearIntFlag(mxc_wdt_regs_t *wdt)
Clears the interrupt flag.