Is there any example project using endpoint 1 & 3 both?
Posted: Fri Sep 04, 2009 11:43 am
Hi,
I am trying to use two interface with two Interrupt In Endpoints, but some how, the device becomes slow and some times hangs.
I have configured the following things to use endpoint 3:
and my Reports are sent this way:
The Device,Configuration and Report descriptors are according to the setup, and I think there is no problem as the device enumerates very nicely. But the problem occurs when I send report repetitively (pressing the keyboard or mouse displacement button very quickly).
Can any one help me with a project using these two IN Interrupts?
I am trying to use two interface with two Interrupt In Endpoints, but some how, the device becomes slow and some times hangs.
I have configured the following things to use endpoint 3:
Code: Select all
#define USB_CFG_HAVE_INTRIN_ENDPOINT 1
/* Define this to 1 if you want to compile a version with two endpoints: The
* default control endpoint 0 and an interrupt-in endpoint (any other endpoint
* number).
*/
#define USB_CFG_HAVE_INTRIN_ENDPOINT3 1
/* Define this to 1 if you want to compile a version with three endpoints: The
* default control endpoint 0, an interrupt-in endpoint 3 (or the number
* configured below) and a catch-all default interrupt-in endpoint as above.
* You must also define USB_CFG_HAVE_INTRIN_ENDPOINT to 1 for this feature.
*/
#define USB_CFG_EP3_NUMBER 3
/* If the so-called endpoint 3 is used, it can now be configured to any other
* endpoint number (except 0) with this macro. Default if undefined is 3.
*/
and my Reports are sent this way:
Code: Select all
case 1:
if(usbInterruptIsReady())
usbSetInterrupt(KbdBuffer, sizeof(KbdBuffer));
break;
case 2:
if(usbInterruptIsReady3())
usbSetInterrupt3(MouseBuffer, sizeof(MouseBuffer));
break;
The Device,Configuration and Report descriptors are according to the setup, and I think there is no problem as the device enumerates very nicely. But the problem occurs when I send report repetitively (pressing the keyboard or mouse displacement button very quickly).
Can any one help me with a project using these two IN Interrupts?