File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -456,7 +456,8 @@ void USBHALHost::UsbIrqhandler()
456
456
USBx_HC (ch_num)->HCINTMSK |= USB_OTG_HCINT_NAK;
457
457
458
458
// workaround the interrupts flood issue: re-enable CHH interrupt
459
- USBx_HC (ch_num)->HCINTMSK |= USB_OTG_HCINT_CHH;
459
+ if (hhcd->hc [ch_num].ep_type == EP_TYPE_CTRL)
460
+ USBx_HC (ch_num)->HCINTMSK |= USB_OTG_HCINT_CHH;
460
461
}
461
462
}
462
463
@@ -467,6 +468,7 @@ void USBHALHost::UsbIrqhandler()
467
468
{
468
469
for (ch_num = 0 ; ch_num < hhcd->Init .Host_channels ; ch_num++)
469
470
{
471
+ LogicUint7 (USBx_HC (ch_num)->HCINT );
470
472
if ((hhcd->hc [ch_num].ep_type == EP_TYPE_CTRL) || (hhcd->hc [ch_num].ep_type == EP_TYPE_BULK))
471
473
{
472
474
if (USBx_HC (ch_num)->HCINT & USB_OTG_HCINT_NAK)
@@ -475,7 +477,7 @@ void USBHALHost::UsbIrqhandler()
475
477
USBx_HC (ch_num)->HCINTMSK &= ~USB_OTG_HCINT_NAK;
476
478
}
477
479
478
- if (USBx_HC (ch_num)->HCINT & USB_OTG_HCINT_CHH)
480
+ if (( USBx_HC (ch_num)->HCINT & USB_OTG_HCINT_CHH) && (hhcd-> hc [ch_num]. ep_type == EP_TYPE_CTRL) )
479
481
{
480
482
// workaround the interrupts flood issue: disable CHH interrupt
481
483
USBx_HC (ch_num)->HCINTMSK &= ~USB_OTG_HCINT_CHH;
You can’t perform that action at this time.
0 commit comments