63 #ifndef BSP430_PERIPH_PMM_H
64 #define BSP430_PERIPH_PMM_H
74 #define BSP430_MODULE_PMM (defined(__MSP430_HAS_PMM__) \
75 || defined(__MSP430_HAS_PMM_FR5xx__) \
76 || defined(__MSP430_HAS_PMM_FRAM__))
87 #define BSP430_MODULE_PMM_FRAM (defined(__MSP430_HAS_PMM_FR5xx__) \
88 || defined(__MSP430_HAS_PMM_FRAM__))
97 #define BSP430_PMM_SUPPORTS_COREV ((BSP430_MODULE_PMM - 0) && ! (BSP430_MODULE_PMM_FRAM - 0))
106 #define BSP430_PMM_SUPPORTS_SVSM ((BSP430_MODULE_PMM - 0) && ! (BSP430_MODULE_PMM_FRAM - 0))
108 #if defined(BSP430_DOXYGEN) || (BSP430_MODULE_PMM - 0)
110 #if defined(BSP430_DOXYGEN) || defined(LOCKLPM5)
133 #define BSP430_PMM_ENTER_LPMXp5_NI() do { \
134 PMMCTL0_H = PMMPW_H; \
135 PMMCTL0 = PMMPW | PMMREGOFF; \
136 PMMCTL0_H = !PMMPW_H; \
163 #if defined(BSP430_DOXYGEN) || defined(LOCKLPM5)
164 #define BSP430_PMM_CLEAR_LOCKLPM5() do { \
165 PMMCTL0_H = PMMPW_H; \
166 PM5CTL0 &= ~LOCKLPM5; \
167 PMMCTL0_H = !PMMPW_H; \
170 #define BSP430_PMM_CLEAR_LOCKLPM5() do { } while (0)
173 #if defined(BSP430_DOXYGEN) || (BSP430_PMM_SUPPORTS_SVSM - 0)
220 #define BSP430_PMM_SET_SVSMCTL_NI(hctl_,lctl_) do { \
221 PMMCTL0_H = PMMPW_H; \
222 SVSMHCTL = (hctl_); \
223 SVSMLCTL = (lctl_); \
224 PMMCTL0_H = !PMMPW_H; \
233 PMMCTL0 = PMMPW | PMMSWBOR;
241 PMMCTL0 = PMMPW | PMMSWPOR;
244 #if defined(BSP430_DOXYGEN) || (BSP430_PMM_SUPPORTS_COREV - 0)
259 #if defined(BSP430_DOXYGEN)
260 #define BSP430_PMM_COREV_FOR_MCLK(mclk_) include <bsp430/platform.h>
int iBSP430pmmSetCoreVoltageLevel_ni(unsigned int target_level)
#define BSP430_CORE_INLINE
Definition: core.h:439
Generic peripheral support for MSP430 MCUs.
static BSP430_CORE_INLINE void vBSP430pmmInducePOR(void)
Definition: pmm.h:239
static BSP430_CORE_INLINE void vBSP430pmmInduceBOR(void)
Definition: pmm.h:231