USB Enable/Disable Interrupt problem

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

USB Enable/Disable Interrupt problem

737 Views
danielebruno
Contributor III

Hello,

I'm using the KL26 microcontroller in one of our boards with "SDK_2.4.1_MKL26Z256xxx4"

I have a question about disabling/enabling the USB interrupts in order to masking them in a function that must not be interrupted.

The functions DisableIRQ/EnableIRQ seem not to work properly.

I implement an HID keyboard: I am able to disable the interrupt but when I try to re-enable it, the interrupt works only if I haven't pressed any key while it was disabled, otherwise any other key will be not recognized.

I use these functions "normally" to mask interrupts coming from PortC and PortD.

Are there some special precautions in order to use them for the USB port ?

Thank you for all the attention.

Best Regards

Daniele

0 Kudos
1 Reply

665 Views
FelipeGarcia
NXP Employee
NXP Employee

Hello Daniele,

 

I recommend you to check the below application note document that explains a little further how you can implement resume and suspend USB feature.

 

https://www.nxp.com/docs/en/application-note/AN5385.pdf

 

I hope this helps!

 

Have a great day,
Felipe

-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

0 Kudos