Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of USBDevice_STM32F103 by
Revision 71:9950749ae475, committed 2018-02-28
- Comitter:
- lorded
- Date:
- Wed Feb 28 22:05:36 2018 +0000
- Parent:
- 70:e410de636542
- Commit message:
- USB
Changed in this revision
USBDevice/USBHAL_STM32F1.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/USBDevice/USBHAL_STM32F1.cpp Fri Nov 25 18:31:08 2016 +0000 +++ b/USBDevice/USBHAL_STM32F1.cpp Wed Feb 28 22:05:36 2018 +0000 @@ -44,6 +44,9 @@ HAL_PCD_Init(&hpcd_USB_FS); HAL_PCD_Start(&hpcd_USB_FS); } +#define __USB_CLK_ENABLE() (RCC->APB1ENR |= (RCC_APB1ENR_USBEN)) + +#define __USB_CLK_ENABLE() (RCC->APB1ENR |= (RCC_APB1ENR_USBEN)) void HAL_PCD_MspInit(PCD_HandleTypeDef* hpcd) { __USB_CLK_ENABLE(); @@ -52,7 +55,7 @@ } void HAL_PCD_MspDeInit(PCD_HandleTypeDef* hpcd) { - __USB_CLK_DISABLE(); // Peripheral clock disable + //__USB_CLK_DISABLE(); // Peripheral clock disable HAL_NVIC_DisableIRQ(USB_LP_IRQn); // Peripheral interrupt Deinit }