mirror of
https://github.com/hathach/tinyusb.git
synced 2025-03-21 07:21:00 +00:00
Merge pull request #2385 from kasjer/kasjer/nrf5x-fix-dcd_edpt_open-for-iso
dcd_nrf5x: Fix dcd_edpt_open for iso endpoint
This commit is contained in:
commit
804f6718ed
@ -340,6 +340,9 @@ bool dcd_edpt_open (uint8_t rhport, tusb_desc_endpoint_t const * desc_edpt)
|
||||
NRF_USBD->INTENSET = TU_BIT(USBD_INTEN_ENDEPIN0_Pos + epnum);
|
||||
NRF_USBD->EPINEN |= TU_BIT(epnum);
|
||||
}
|
||||
// clear stall and reset DataToggle
|
||||
NRF_USBD->EPSTALL = (USBD_EPSTALL_STALL_UnStall << USBD_EPSTALL_STALL_Pos) | ep_addr;
|
||||
NRF_USBD->DTOGGLE = (USBD_DTOGGLE_VALUE_Data0 << USBD_DTOGGLE_VALUE_Pos) | ep_addr;
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -375,10 +378,6 @@ bool dcd_edpt_open (uint8_t rhport, tusb_desc_endpoint_t const * desc_edpt)
|
||||
}
|
||||
}
|
||||
|
||||
// clear stall and reset DataToggle
|
||||
NRF_USBD->EPSTALL = (USBD_EPSTALL_STALL_UnStall << USBD_EPSTALL_STALL_Pos) | ep_addr;
|
||||
NRF_USBD->DTOGGLE = (USBD_DTOGGLE_VALUE_Data0 << USBD_DTOGGLE_VALUE_Pos) | ep_addr;
|
||||
|
||||
__ISB(); __DSB();
|
||||
|
||||
return true;
|
||||
|
Loading…
x
Reference in New Issue
Block a user