The official Mbed 2 C/C++ SDK provides the software platform and libraries to build your applications.
Dependents: hello SerialTestv11 SerialTestv12 Sierpinski ... more
mbed 2
This is the mbed 2 library. If you'd like to learn about Mbed OS please see the mbed-os docs.
Diff: TARGET_NUCLEO_L432KC/TARGET_STM/TARGET_STM32L4/device/stm32l4xx_ll_pwr.h
- Revision:
- 145:64910690c574
- Parent:
- 128:9bcdf88f62b0
--- a/TARGET_NUCLEO_L432KC/TARGET_STM/TARGET_STM32L4/device/stm32l4xx_ll_pwr.h Thu Jun 08 14:53:05 2017 +0100 +++ b/TARGET_NUCLEO_L432KC/TARGET_STM/TARGET_STM32L4/device/stm32l4xx_ll_pwr.h Wed Jun 21 17:31:38 2017 +0100 @@ -2,13 +2,13 @@ ****************************************************************************** * @file stm32l4xx_ll_pwr.h * @author MCD Application Team - * @version V1.5.1 - * @date 31-May-2016 + * @version V1.7.1 + * @date 21-April-2017 * @brief Header file of PWR LL module. ****************************************************************************** * @attention * - * <h2><center>© COPYRIGHT(c) 2016 STMicroelectronics</center></h2> + * <h2><center>© COPYRIGHT(c) 2017 STMicroelectronics</center></h2> * * Redistribution and use in source and binary forms, with or without modification, * are permitted provided that the following conditions are met: @@ -95,12 +95,18 @@ #define LL_PWR_SR1_WUF3 PWR_SR1_WUF3 #define LL_PWR_SR1_WUF2 PWR_SR1_WUF2 #define LL_PWR_SR1_WUF1 PWR_SR1_WUF1 +#if defined(PWR_SR2_PVMO4) #define LL_PWR_SR2_PVMO4 PWR_SR2_PVMO4 +#endif /* PWR_SR2_PVMO4 */ +#if defined(PWR_SR2_PVMO3) #define LL_PWR_SR2_PVMO3 PWR_SR2_PVMO3 +#endif /* PWR_SR2_PVMO3 */ #if defined(PWR_SR2_PVMO2) #define LL_PWR_SR2_PVMO2 PWR_SR2_PVMO2 #endif /* PWR_SR2_PVMO2 */ +#if defined(PWR_SR2_PVMO1) #define LL_PWR_SR2_PVMO1 PWR_SR2_PVMO1 +#endif /* PWR_SR2_PVMO1 */ #define LL_PWR_SR2_PVDO PWR_SR2_PVDO #define LL_PWR_SR2_VOSF PWR_SR2_VOSF #define LL_PWR_SR2_REGLPF PWR_SR2_REGLPF @@ -130,21 +136,25 @@ * @} */ -/** @defgroup PWR_LL_EC_PVM_VDDUSB_1 PVM VDDUSB 1 +/** @defgroup PWR_LL_EC_PVM_VDDUSB_1 Peripheral voltage monitoring * @{ */ -#if defined(USB_OTG_FS) +#if defined(PWR_CR2_PVME1) #define LL_PWR_PVM_VDDUSB_1_2V (PWR_CR2_PVME1) /* Monitoring VDDUSB vs. 1.2V */ -#endif /* USB_OTG_FS */ +#endif #if defined(PWR_CR2_PVME2) #define LL_PWR_PVM_VDDIO2_0_9V (PWR_CR2_PVME2) /* Monitoring VDDIO2 vs. 0.9V */ -#endif /* PWR_CR2_PVME2 */ +#endif +#if defined(PWR_CR2_PVME3) #define LL_PWR_PVM_VDDA_1_62V (PWR_CR2_PVME3) /* Monitoring VDDA vs. 1.62V */ +#endif +#if defined(PWR_CR2_PVME4) #define LL_PWR_PVM_VDDA_2_2V (PWR_CR2_PVME4) /* Monitoring VDDA vs. 2.2V */ +#endif /** * @} */ - + /** @defgroup PWR_LL_EC_PVDLEVEL PVDLEVEL * @{ */ @@ -191,11 +201,16 @@ #define LL_PWR_GPIO_E ((uint32_t)(&(PWR->PUCRE))) #if defined(GPIOF) #define LL_PWR_GPIO_F ((uint32_t)(&(PWR->PUCRF))) -#endif /* GPIOF */ +#endif #if defined(GPIOG) #define LL_PWR_GPIO_G ((uint32_t)(&(PWR->PUCRG))) -#endif /* GPIOG */ +#endif +#if defined(GPIOH) #define LL_PWR_GPIO_H ((uint32_t)(&(PWR->PUCRH))) +#endif +#if defined(GPIOI) +#define LL_PWR_GPIO_I ((uint32_t)(&(PWR->PUCRI))) +#endif /** * @} */ @@ -404,7 +419,7 @@ return (uint32_t)(READ_BIT(PWR->CR1, PWR_CR1_LPMS)); } -#if defined(USB_OTG_FS) +#if defined(PWR_CR2_PVME1) /** * @brief Enable VDDUSB supply * @rmtoll CR2 USV LL_PWR_EnableVddUSB @@ -414,9 +429,7 @@ { SET_BIT(PWR->CR2, PWR_CR2_USV); } -#endif /* USB_OTG_FS */ -#if defined(USB_OTG_FS) /** * @brief Disable VDDUSB supply * @rmtoll CR2 USV LL_PWR_DisableVddUSB @@ -426,9 +439,7 @@ { CLEAR_BIT(PWR->CR2, PWR_CR2_USV); } -#endif /* USB_OTG_FS */ -#if defined(USB_OTG_FS) /** * @brief Check if VDDUSB supply is enabled * @rmtoll CR2 USV LL_PWR_IsEnabledVddUSB @@ -438,7 +449,7 @@ { return (READ_BIT(PWR->CR2, PWR_CR2_USV) == (PWR_CR2_USV)); } -#endif /* USB_OTG_FS */ +#endif #if defined(PWR_CR2_IOSV) /** @@ -470,7 +481,7 @@ { return (READ_BIT(PWR->CR2, PWR_CR2_IOSV) == (PWR_CR2_IOSV)); } -#endif /* PWR_CR2_IOSV */ +#endif /** * @brief Enable the Power Voltage Monitoring on a peripheral @@ -513,7 +524,7 @@ } /** - * @brief Check if Power Voltage Monitoring is enabled on a peripheral + * @brief Check if Power Voltage Monitoring is enabled on a peripheral * @rmtoll CR2 PVME1 LL_PWR_IsEnabledPVM\n * CR2 PVME2 LL_PWR_IsEnabledPVM\n * CR2 PVME3 LL_PWR_IsEnabledPVM\n @@ -695,7 +706,7 @@ * CR3 EWUP2 LL_PWR_EnableWakeUpPin\n * CR3 EWUP3 LL_PWR_EnableWakeUpPin\n * CR3 EWUP4 LL_PWR_EnableWakeUpPin\n - * CR3 EWUP5 LL_PWR_EnableWakeUpPin + * CR3 EWUP5 LL_PWR_EnableWakeUpPin\n * @param WakeUpPin This parameter can be one of the following values: * @arg @ref LL_PWR_WAKEUP_PIN1 * @arg @ref LL_PWR_WAKEUP_PIN2 @@ -715,7 +726,7 @@ * CR3 EWUP2 LL_PWR_DisableWakeUpPin\n * CR3 EWUP3 LL_PWR_DisableWakeUpPin\n * CR3 EWUP4 LL_PWR_DisableWakeUpPin\n - * CR3 EWUP5 LL_PWR_DisableWakeUpPin + * CR3 EWUP5 LL_PWR_DisableWakeUpPin\n * @param WakeUpPin This parameter can be one of the following values: * @arg @ref LL_PWR_WAKEUP_PIN1 * @arg @ref LL_PWR_WAKEUP_PIN2 @@ -735,7 +746,7 @@ * CR3 EWUP2 LL_PWR_IsEnabledWakeUpPin\n * CR3 EWUP3 LL_PWR_IsEnabledWakeUpPin\n * CR3 EWUP4 LL_PWR_IsEnabledWakeUpPin\n - * CR3 EWUP5 LL_PWR_IsEnabledWakeUpPin + * CR3 EWUP5 LL_PWR_IsEnabledWakeUpPin\n * @param WakeUpPin This parameter can be one of the following values: * @arg @ref LL_PWR_WAKEUP_PIN1 * @arg @ref LL_PWR_WAKEUP_PIN2 @@ -873,7 +884,8 @@ * PUCRE PU0-15 LL_PWR_EnableGPIOPullUp\n * PUCRF PU0-15 LL_PWR_EnableGPIOPullUp\n * PUCRG PU0-15 LL_PWR_EnableGPIOPullUp\n - * PUCRH PU0-1 LL_PWR_EnableGPIOPullUp + * PUCRH PU0-15 LL_PWR_EnableGPIOPullUp\n + * PUCRI PU0-11 LL_PWR_EnableGPIOPullUp * @param GPIO This parameter can be one of the following values: * @arg @ref LL_PWR_GPIO_A * @arg @ref LL_PWR_GPIO_B @@ -883,6 +895,7 @@ * @arg @ref LL_PWR_GPIO_F (*) * @arg @ref LL_PWR_GPIO_G (*) * @arg @ref LL_PWR_GPIO_H + * @arg @ref LL_PWR_GPIO_I (*) * * (*) value not defined in all devices * @param GPIONumber This parameter can be one of the following values: @@ -918,7 +931,8 @@ * PUCRE PU0-15 LL_PWR_DisableGPIOPullUp\n * PUCRF PU0-15 LL_PWR_DisableGPIOPullUp\n * PUCRG PU0-15 LL_PWR_DisableGPIOPullUp\n - * PUCRH PU0-1 LL_PWR_DisableGPIOPullUp + * PUCRH PU0-15 LL_PWR_DisableGPIOPullUp\n + * PUCRI PU0-11 LL_PWR_DisableGPIOPullUp * @param GPIO This parameter can be one of the following values: * @arg @ref LL_PWR_GPIO_A * @arg @ref LL_PWR_GPIO_B @@ -928,6 +942,7 @@ * @arg @ref LL_PWR_GPIO_F (*) * @arg @ref LL_PWR_GPIO_G (*) * @arg @ref LL_PWR_GPIO_H + * @arg @ref LL_PWR_GPIO_I (*) * * (*) value not defined in all devices * @param GPIONumber This parameter can be one of the following values: @@ -963,7 +978,8 @@ * PUCRE PU0-15 LL_PWR_IsEnabledGPIOPullUp\n * PUCRF PU0-15 LL_PWR_IsEnabledGPIOPullUp\n * PUCRG PU0-15 LL_PWR_IsEnabledGPIOPullUp\n - * PUCRH PU0-1 LL_PWR_IsEnabledGPIOPullUp + * PUCRH PU0-15 LL_PWR_IsEnabledGPIOPullUp\n + * PUCRI PU0-11 LL_PWR_IsEnabledGPIOPullUp * @param GPIO This parameter can be one of the following values: * @arg @ref LL_PWR_GPIO_A * @arg @ref LL_PWR_GPIO_B @@ -973,6 +989,7 @@ * @arg @ref LL_PWR_GPIO_F (*) * @arg @ref LL_PWR_GPIO_G (*) * @arg @ref LL_PWR_GPIO_H + * @arg @ref LL_PWR_GPIO_I (*) * * (*) value not defined in all devices * @param GPIONumber This parameter can be one of the following values: @@ -1008,7 +1025,8 @@ * PDCRE PD0-15 LL_PWR_EnableGPIOPullDown\n * PDCRF PD0-15 LL_PWR_EnableGPIOPullDown\n * PDCRG PD0-15 LL_PWR_EnableGPIOPullDown\n - * PDCRH PD0-1 LL_PWR_EnableGPIOPullDown + * PDCRH PD0-15 LL_PWR_EnableGPIOPullDown\n + * PDCRI PD0-11 LL_PWR_EnableGPIOPullDown * @param GPIO This parameter can be one of the following values: * @arg @ref LL_PWR_GPIO_A * @arg @ref LL_PWR_GPIO_B @@ -1018,6 +1036,7 @@ * @arg @ref LL_PWR_GPIO_F (*) * @arg @ref LL_PWR_GPIO_G (*) * @arg @ref LL_PWR_GPIO_H + * @arg @ref LL_PWR_GPIO_I (*) * * (*) value not defined in all devices * @param GPIONumber This parameter can be one of the following values: @@ -1054,7 +1073,8 @@ * PDCRE PD0-15 LL_PWR_DisableGPIOPullDown\n * PDCRF PD0-15 LL_PWR_DisableGPIOPullDown\n * PDCRG PD0-15 LL_PWR_DisableGPIOPullDown\n - * PDCRH PD0-1 LL_PWR_DisableGPIOPullDown + * PDCRH PD0-15 LL_PWR_DisableGPIOPullDown\n + * PDCRI PD0-11 LL_PWR_DisableGPIOPullDown * @param GPIO This parameter can be one of the following values: * @arg @ref LL_PWR_GPIO_A * @arg @ref LL_PWR_GPIO_B @@ -1064,6 +1084,7 @@ * @arg @ref LL_PWR_GPIO_F (*) * @arg @ref LL_PWR_GPIO_G (*) * @arg @ref LL_PWR_GPIO_H + * @arg @ref LL_PWR_GPIO_I (*) * * (*) value not defined in all devices * @param GPIONumber This parameter can be one of the following values: @@ -1100,7 +1121,8 @@ * PDCRE PD0-15 LL_PWR_IsEnabledGPIOPullDown\n * PDCRF PD0-15 LL_PWR_IsEnabledGPIOPullDown\n * PDCRG PD0-15 LL_PWR_IsEnabledGPIOPullDown\n - * PDCRH PD0-1 LL_PWR_IsEnabledGPIOPullDown + * PDCRH PD0-15 LL_PWR_IsEnabledGPIOPullDown\n + * PDCRI PD0-11 LL_PWR_IsEnabledGPIOPullDown * @param GPIO This parameter can be one of the following values: * @arg @ref LL_PWR_GPIO_A * @arg @ref LL_PWR_GPIO_B @@ -1110,6 +1132,7 @@ * @arg @ref LL_PWR_GPIO_F (*) * @arg @ref LL_PWR_GPIO_G (*) * @arg @ref LL_PWR_GPIO_H + * @arg @ref LL_PWR_GPIO_I (*) * * (*) value not defined in all devices * @param GPIONumber This parameter can be one of the following values: @@ -1317,7 +1340,7 @@ } #endif /* PWR_SR2_PVMO2 */ -#if defined(USB_OTG_FS) +#if defined(PWR_SR2_PVMO1) /** * @brief Indicate whether VDDUSB voltage is below or above PVM1 threshold * @rmtoll SR2 PVMO1 LL_PWR_IsActiveFlag_PVMO1 @@ -1327,7 +1350,7 @@ { return (READ_BIT(PWR->SR2, PWR_SR2_PVMO1) == (PWR_SR2_PVMO1)); } -#endif /* USB_OTG_FS */ +#endif /* PWR_SR2_PVMO1 */ /** * @brief Indicate whether VDD voltage is below or above the selected PVD threshold @@ -1341,10 +1364,10 @@ /** * @brief Indicate whether the regulator is ready in the selected voltage range or if its output voltage is still changing to the required voltage level - * @rmtoll SR2 VOSF LL_PWR_IsActiveFlag_VOSF + * @rmtoll SR2 VOSF LL_PWR_IsActiveFlag_VOS * @retval State of bit (1 or 0). */ -__STATIC_INLINE uint32_t LL_PWR_IsActiveFlag_VOSF(void) +__STATIC_INLINE uint32_t LL_PWR_IsActiveFlag_VOS(void) { return (READ_BIT(PWR->SR2, PWR_SR2_VOSF) == (PWR_SR2_VOSF)); } @@ -1370,6 +1393,10 @@ return (READ_BIT(PWR->SR2, PWR_SR2_REGLPS) == (PWR_SR2_REGLPS)); } +/** + * @} + */ + #if defined(USE_FULL_LL_DRIVER) /** @defgroup PWR_LL_EF_Init De-initialization function * @{ @@ -1380,11 +1407,16 @@ */ #endif /* USE_FULL_LL_DRIVER */ +/** Legacy definitions for compatibility purpose +@cond 0 +*/ +/* Old functions name kept for legacy purpose, to be replaced by the */ +/* current functions name. */ +#define LL_PWR_IsActiveFlag_VOSF LL_PWR_IsActiveFlag_VOS /** - * @} +@endcond */ - /** * @} */