fix LPC812 PWM
Fork of mbed-dev by
Diff: targets/cmsis/TARGET_STM/TARGET_STM32F4/stm32f4xx_hal_pcd.c
- Revision:
- 19:112740acecfa
- Parent:
- 0:9b334a45a8ff
diff -r da299f395b9e -r 112740acecfa targets/cmsis/TARGET_STM/TARGET_STM32F4/stm32f4xx_hal_pcd.c --- a/targets/cmsis/TARGET_STM/TARGET_STM32F4/stm32f4xx_hal_pcd.c Mon Nov 09 13:30:11 2015 +0000 +++ b/targets/cmsis/TARGET_STM/TARGET_STM32F4/stm32f4xx_hal_pcd.c Tue Nov 10 09:30:11 2015 +0000 @@ -2,8 +2,8 @@ ****************************************************************************** * @file stm32f4xx_hal_pcd.c * @author MCD Application Team - * @version V1.3.2 - * @date 26-June-2015 + * @version V1.4.1 + * @date 09-October-2015 * @brief PCD HAL module driver. * This file provides firmware functions to manage the following * functionalities of the USB Peripheral Controller: @@ -85,7 +85,10 @@ */ #ifdef HAL_PCD_MODULE_ENABLED - +#if defined(STM32F405xx) || defined(STM32F415xx) || defined(STM32F407xx) || defined(STM32F417xx) || \ + defined(STM32F427xx) || defined(STM32F437xx) || defined(STM32F429xx) || defined(STM32F439xx) || \ + defined(STM32F401xC) || defined(STM32F401xE) || defined(STM32F411xE) || defined(STM32F446xx) || \ + defined(STM32F469xx) || defined(STM32F479xx) /* Private types -------------------------------------------------------------*/ /* Private variables ---------------------------------------------------------*/ /* Private constants ---------------------------------------------------------*/ @@ -200,6 +203,14 @@ } #endif /* USB_OTG_GLPMCFG_LPMEN */ +#ifdef USB_OTG_GCCFG_BCDEN + /* Activate Battery charging */ + if (hpcd->Init.battery_charging_enable ==1) + { + HAL_PCDEx_ActivateBCD(hpcd); + } +#endif /* USB_OTG_GCCFG_BCDEN */ + USB_DevDisconnect (hpcd->Instance); return HAL_OK; } @@ -1195,7 +1206,8 @@ /** * @} */ - +#endif /* STM32F405xx || STM32F415xx || STM32F407xx || STM32F417xx || STM32F427xx || STM32F437xx || STM32F429xx || STM32F439xx || + STM32F401xC || STM32F401xE || STM32F411xE || STM32F446xx || STM32F469xx || STM32F479xx */ #endif /* HAL_PCD_MODULE_ENABLED */ /** * @}