Hello,
as I am having some trouble by (probably) not calling usbPoll often enough (50ms max) I arrived at the following question:
Why is it not possible to call "usbPoll" from within a timer interrupt?
As christian said elsewhere:
"You can't call usbPoll() from a timer interrupt. You must call it from the main code."
Is this because they share some data they both use or are there other reasons?
Thanks!
timer polling
Re: timer polling
I think v-usb just uses the interrupts for timing and the poll depends strictly on the function usbInterruptIsReady.
Code: Select all
while ( !usbInterruptIsReady() ) //when not ready you must poll
{
usbPoll();
}
//pulling has stopped tiuem to send
usbSetInterrupt( reportBuffer, 8);