diff options
| author | William D. Jones <[email protected]> | 2019-01-13 17:34:09 -0500 |
|---|---|---|
| committer | William D. Jones <[email protected]> | 2019-01-13 18:36:18 -0500 |
| commit | 657d3e2983558831cd5525b2c5aa3bef27f9468b (patch) | |
| tree | 7cb083a83482747dd2b9e5e4ed22bd73626fb6b0 /src | |
| parent | 03cbd406cb16ff2da5b11775e0d34d7d53f5ea45 (diff) | |
stm32f4: Enable USB peripheral, fix typos in register writes.
Diffstat (limited to 'src')
| -rw-r--r-- | src/portable/stm/stm32f4/dcd_stm32f4.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/portable/stm/stm32f4/dcd_stm32f4.c b/src/portable/stm/stm32f4/dcd_stm32f4.c index b87ff6597..e6849085f 100644 --- a/src/portable/stm/stm32f4/dcd_stm32f4.c +++ b/src/portable/stm/stm32f4/dcd_stm32f4.c @@ -78,7 +78,9 @@ bool dcd_init (uint8_t rhport) USB_OTG_FS->GINTMSK |= USB_OTG_GINTMSK_USBRST | USB_OTG_GINTMSK_ENUMDNEM | \ USB_OTG_GINTMSK_ESUSPM | USB_OTG_GINTMSK_USBSUSPM | \ USB_OTG_GINTMSK_SOFM; - USB_OTG_FS->GCCFG |= USB_OTG_GCCFG_VBUSBSEN; // Enable pullup. + + // Enable pullup, enable peripheral. + USB_OTG_FS->GCCFG |= USB_OTG_GCCFG_VBUSBSEN | USB_OTG_GCCFG_PWRDWN; return true; } |
