MG32F157 Standard Peripherals Firmware Library
mg32f157_dbgmcu.h
Go to the documentation of this file.
1 
10 /* Define to prevent recursive inclusion -------------------------------------*/
11 #ifndef __MG32F157_DBGMCU_H
12 #define __MG32F157_DBGMCU_H
13 
14 #ifdef __cplusplus
15  extern "C" {
16 #endif
17 
18 /* Includes ------------------------------------------------------------------*/
19 #include "mg32f157.h"
20 
29 /* Exported types ------------------------------------------------------------*/
30 /* Exported constants --------------------------------------------------------*/
31 
36 #define DBGMCU_SLEEP ((uint32_t)0x00000001)
37 #define DBGMCU_STOP ((uint32_t)0x00000002)
38 #define DBGMCU_STANDBY ((uint32_t)0x00000004)
39 #define DBGMCU_IWDG_STOP ((uint32_t)0x00000100)
40 #define DBGMCU_WWDG_STOP ((uint32_t)0x00000200)
41 #define DBGMCU_TIM1_STOP ((uint32_t)0x00000400)
42 #define DBGMCU_TIM2_STOP ((uint32_t)0x00000800)
43 #define DBGMCU_TIM3_STOP ((uint32_t)0x00001000)
44 #define DBGMCU_TIM4_STOP ((uint32_t)0x00002000)
45 #define DBGMCU_CAN1_STOP ((uint32_t)0x00004000)
46 #define DBGMCU_I2C1_SMBUS_TIMEOUT ((uint32_t)0x00008000)
47 #define DBGMCU_I2C2_SMBUS_TIMEOUT ((uint32_t)0x00010000)
48 #define DBGMCU_TIM8_STOP ((uint32_t)0x00020000)
49 #define DBGMCU_TIM5_STOP ((uint32_t)0x00040000)
50 #define DBGMCU_TIM6_STOP ((uint32_t)0x00080000)
51 #define DBGMCU_TIM7_STOP ((uint32_t)0x00100000)
52 #define DBGMCU_CAN2_STOP ((uint32_t)0x00200000)
53 
54 #define IS_DBGMCU_PERIPH(PERIPH) ((((PERIPH) & 0x800000F8) == 0x00) && ((PERIPH) != 0x00))
55 
60 /* Exported macro ------------------------------------------------------------*/
61 /* Exported functions --------------------------------------------------------*/
62 
63 uint32_t DBGMCU_GetREVID(void);
64 uint32_t DBGMCU_GetDEVID(void);
65 void DBGMCU_Config(uint32_t DBGMCU_Periph, FunctionalState NewState);
66 
75 #ifdef __cplusplus
76 }
77 #endif
78 
79 #endif /* __MG32F157_DBGMCU_H */
uint32_t DBGMCU_GetDEVID(void)
Returns the device identifier.
Definition: mg32f157_dbgmcu.c:58
uint32_t DBGMCU_GetREVID(void)
Returns the device revision identifier.
Definition: mg32f157_dbgmcu.c:48
void DBGMCU_Config(uint32_t DBGMCU_Periph, FunctionalState NewState)
Configures the specified peripheral and low power mode behavior when the MCU under Debug mode.
Definition: mg32f157_dbgmcu.c:89