LPC546xx: USB interrupt pipe polling notification

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

LPC546xx: USB interrupt pipe polling notification

Jump to solution
783 Views
rex_lam
Contributor IV

Is there a way to be notified when the host polls the USB interrupt IN pipe? I looked at the USB example projects and it seems that USB0_IRQHandler is not triggered when the device has nothing to report, i.e. responds to the interrupt poll with NAK. I would like my code to be notified when it receives the interrupt IN poll from the host.

Labels (2)
1 Solution
572 Views
carstengroen
Senior Contributor II

Rex,

have a look at my post here: Custom USB class using USBROM (for LPC54608 and alike), code to grab  

(at the end of the page)

Basically I use

// Allow both acknowledged and NAK'ed  packets to generate interrupts (otherwise it is only acknowledged packets that generate interrupts)
LPC_USB0->DEVCMDSTAT |= (1<<12) | (1<<13);

View solution in original post

2 Replies
573 Views
carstengroen
Senior Contributor II

Rex,

have a look at my post here: Custom USB class using USBROM (for LPC54608 and alike), code to grab  

(at the end of the page)

Basically I use

// Allow both acknowledged and NAK'ed  packets to generate interrupts (otherwise it is only acknowledged packets that generate interrupts)
LPC_USB0->DEVCMDSTAT |= (1<<12) | (1<<13);
572 Views
rex_lam
Contributor IV

Thank you Carsten.