move VBUS sense out of dcd_synosys to bsp
This commit is contained in:
@@ -207,12 +207,8 @@ void dcd_init (uint8_t rhport)
|
||||
USB_OTG_GINTMSK_SOFM | USB_OTG_GINTMSK_RXFLVLM /* SB_OTG_GINTMSK_ESUSPM | \
|
||||
USB_OTG_GINTMSK_USBSUSPM */;
|
||||
|
||||
// Enable VBUS hardware sensing, enable pullup, enable peripheral.
|
||||
#ifdef USB_OTG_GCCFG_VBDEN
|
||||
USB_OTG_FS->GCCFG |= USB_OTG_GCCFG_VBDEN | USB_OTG_GCCFG_PWRDWN;
|
||||
#else
|
||||
USB_OTG_FS->GCCFG |= USB_OTG_GCCFG_VBUSBSEN | USB_OTG_GCCFG_PWRDWN;
|
||||
#endif
|
||||
// Enable USB transceiver.
|
||||
USB_OTG_FS->GCCFG |= USB_OTG_GCCFG_PWRDWN;
|
||||
|
||||
// Soft Connect -> Enable pullup on D+/D-.
|
||||
// This step does not appear to be specified in the programmer's model.
|
||||
|
||||
Reference in New Issue
Block a user