Fixed some comments

pull/10689/head
George Beckstein 2019-03-14 22:08:29 -04:00 committed by aglass0fmilk
parent 0fd7dcaa4e
commit 911c799de0
2 changed files with 8 additions and 1 deletions

View File

@ -94,7 +94,7 @@ private:
// Nordic transfer structures for each in/out endpoint
nrf_drv_usbd_transfer_t transfer_buf[18];
// Returns the appropraite transfer structure buffer for the given endpoint
// Returns the appropriate transfer structure buffer for the given endpoint
nrf_drv_usbd_transfer_t* get_transfer_buffer(usb_ep_t endpoint);
// Returns the corresponding enumeration given an mbed endpoint number

View File

@ -357,6 +357,13 @@ void USBPhyHw::endpoint_stall(usb_ep_t endpoint) {
void USBPhyHw::endpoint_unstall(usb_ep_t endpoint) {
nrf_drv_usbd_ep_t ep = get_nordic_endpoint(endpoint);
nrf_drv_usbd_ep_stall_clear(ep);
/*
* This is a somewhat hacky fix to fully "unload"
* an IN endpoint after a buffer has been
* transferred via EasyDMA...
*/
nrf_drv_usbd_ep_disable(ep);
nrf_drv_usbd_ep_enable(ep);
}