mirror of
https://github.com/hathach/tinyusb.git
synced 2025-02-15 03:40:19 +00:00
stm32f4: Ensure endpoints enabled properly, using correct FIFOs.
This commit is contained in:
parent
f5d9e7e560
commit
747815f03b
@ -224,13 +224,15 @@ bool dcd_edpt_open (uint8_t rhport, tusb_desc_endpoint_t const * desc_edpt)
|
||||
|
||||
if(dir == TUSB_DIR_OUT) {
|
||||
out_ep[epnum].DOEPCTL |= USB_OTG_DOEPCTL_EPENA | \
|
||||
(1 << USB_OTG_DOEPCTL_USBAEP_Pos) | \
|
||||
(bulk_or_int ? USB_OTG_DOEPCTL_SD0PID_SEVNFRM : 0uL) | \
|
||||
desc_edpt->bmAttributes.xfer << USB_OTG_DOEPCTL_EPTYP_Pos | \
|
||||
desc_edpt->wMaxPacketSize.size << USB_OTG_DOEPCTL_MPSIZ_Pos;
|
||||
} else {
|
||||
in_ep[epnum].DIEPCTL |= USB_OTG_DIEPCTL_EPENA | \
|
||||
(1 << USB_OTG_DIEPCTL_USBAEP_Pos) | \
|
||||
(bulk_or_int ? USB_OTG_DIEPCTL_SD0PID_SEVNFRM : 0uL) | \
|
||||
epnum << USB_OTG_DIEPCTL_TXFNUM_Pos | \
|
||||
(epnum - 1) << USB_OTG_DIEPCTL_TXFNUM_Pos | \
|
||||
desc_edpt->bmAttributes.xfer << USB_OTG_DIEPCTL_EPTYP_Pos | \
|
||||
desc_edpt->wMaxPacketSize.size << USB_OTG_DIEPCTL_MPSIZ_Pos;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user