summaryrefslogtreecommitdiff
path: root/ucoo/hal
diff options
context:
space:
mode:
authorNicolas Schodet2015-06-23 13:02:34 +0200
committerNicolas Schodet2019-10-07 00:44:50 +0200
commit4f3801868f0ebcf80325a48a5a03b3ca082c20c6 (patch)
treea68846feb7016f654feb4629ea0861a8b8809d4f /ucoo/hal
parent77a43c6de3d34abc6d4a3683a220e99c5908e7b2 (diff)
ucoo/hal/usb: fix VBUS usage
VBUS is not an alternate function, it is a additionnal function which do not need to be configured.
Diffstat (limited to 'ucoo/hal')
-rw-r--r--ucoo/hal/usb/usb.stm32.cc10
1 files changed, 4 insertions, 6 deletions
diff --git a/ucoo/hal/usb/usb.stm32.cc b/ucoo/hal/usb/usb.stm32.cc
index 93f1782..a45e121 100644
--- a/ucoo/hal/usb/usb.stm32.cc
+++ b/ucoo/hal/usb/usb.stm32.cc
@@ -85,15 +85,13 @@ UsbStreamControl::UsbStreamControl (const char *vendor, const char *product)
# if CONFIG_UCOO_HAL_USB_DRIVER_HS
rcc_periph_clock_enable (RCC_OTGHS);
rcc_periph_clock_enable (RCC_GPIOB);
- gpio_mode_setup (GPIOB, GPIO_MODE_AF, GPIO_PUPD_NONE,
- GPIO13 | GPIO14 | GPIO15);
- gpio_set_af (GPIOB, GPIO_AF12, GPIO13 | GPIO14 | GPIO15);
+ gpio_mode_setup (GPIOB, GPIO_MODE_AF, GPIO_PUPD_NONE, GPIO14 | GPIO15);
+ gpio_set_af (GPIOB, GPIO_AF12, GPIO14 | GPIO15);
# else
rcc_periph_clock_enable (RCC_OTGFS);
rcc_periph_clock_enable (RCC_GPIOA);
- gpio_mode_setup (GPIOA, GPIO_MODE_AF, GPIO_PUPD_NONE,
- GPIO9 | GPIO11 | GPIO12);
- gpio_set_af (GPIOA, GPIO_AF10, GPIO9 | GPIO11 | GPIO12);
+ gpio_mode_setup (GPIOA, GPIO_MODE_AF, GPIO_PUPD_NONE, GPIO11 | GPIO12);
+ gpio_set_af (GPIOA, GPIO_AF10, GPIO11 | GPIO12);
# endif
#elif defined (TARGET_stm32f1)
rcc_periph_clock_enable (RCC_OTGFS);