I use usb controller in Lpc2148. I get example code from keil website in HID class. I need adapt InReport up to 64 byte( InReport[0],InReport[1]....,InReport[64]) for send more data but I donn't good enough in C programming. How can I do? pleas give code. How can I develop application software in the host side. I need Visual Basic 6 thanks you
I recommend you this simplified report descriptor (same as the report desc in my above (21-Nov-2007 17:02) post))
const BYTE HID_ReportDescriptor[] = { HID_UsagePageVendor( 0x00 ), HID_Usage( 0x01 ), HID_Collection( HID_Application ), HID_LogicalMin( 0 ), HID_LogicalMaxS( 0xFF ), HID_ReportSize( 8 ), // bits HID_ReportCount( INREPORT_SIZE ), // bytes HID_Usage( 0x01 ), HID_Input( HID_Data | HID_Variable | HID_Absolute ), HID_ReportCount( OUTREPORT_SIZE ), // bytes HID_Usage( 0x01 ), HID_Output( HID_Data | HID_Variable | HID_Absolute ), HID_EndCollection, };
You'll find the detailed (maybe too detailed :-) ) definition of the report descriptor here. "Device Class Definition for HID 1.11" - HID spec www.usb.org/.../HID1_11.pdf 6.2.2 Report Descriptor (HID1_11.pdf ver1.11 p23)
You can confirm your report descriptor using this tool. "HID Descriptor Tool" on USB.org www.usb.org/.../dt2_4.zip
If you aren't implementing a specific HID device like mouse and keyboard, however, above simplified report descriptor is enough.
Ummm.. In above posts, I didn't write about USB_Configure_Event() (usbuser.c) as the initialization of USB routines. But I won't write elaborate long post in this forum any more, because of the weird SPAM filter. You'll find me in these fora. See you in these fora again. Bye!!
LPC2000 tech.groups.yahoo.com/.../
USB-IF Developers " href= "http://www.cygnal.org/scripts/Ultimate.cgi?action=intro">www.cygnal.org/.../Ultimate.cgi
8052.com " http://www.keil.com/forum/docs/thread11241.asp
Tsuneo