i.MX 1050 stuck on USB interrupt and other USB issues

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

i.MX 1050 stuck on USB interrupt and other USB issues

1,106 Views
benolayinka
Contributor III

My FreeRTOS project is hanging on a couple of USB host issues.

1) The USB host controller seems to be issuing interrupts even though none of the interrupts it is issuing are enabled. I guess the phantom interrupt is then not cleared, because I get stuck in an infinite interrupt loop. Here are the USBINT and USBSTS registers - you can see that none of the STS bits are enabled in the INT register, so I don't know why an interrupt is being triggered? I'm reading these registers from within the interrupt routine, btw.

Screen Shot 2019-08-14 at 12.11.35.png

As a temporary fix, I'm enabling USBINT bits 4 and 7 so that the ISR will see them and clear them. This is still a very strange bug, though, and I don't want to have to enable all interrupts just in case they somehow fire when they are disabled and lock up the processor.

2) If I pause the debugger and data comes in on a USB host port, I don't receive any more USB data. Transaction interrupts never fire, only timer interrupts. Removing and reconnecting the device fixes this. I noticed that the same thing would happen if a printf or something slow prevented an interrupt from being serviced by the USBHostTask. This is a hard problem for me to debug, since I can only reproduce it by pausing the debugger, and then I never get the interrupt I need in order to see what's going wrong.

0 Kudos
Reply
2 Replies

984 Views
tim_wang
NXP Employee
NXP Employee

Hi Benjamin,

Did you use any demo of the SDK as a reference for your project? If you used it, please indicate it and i will do some tests.

0 Kudos
Reply

984 Views
jay_heng
NXP Employee
NXP Employee

@Tim Wang, Can you help check this issue?

0 Kudos
Reply