Page 1 of 1

HID keyboard - receiving data from PC

Posted: Wed Oct 21, 2009 2:51 pm
by Piotr Wilk
Hello.

I'm trying build device which will be PC keyboard with several buttons. This part is easy, there is
example I can customize. I need to have possibility to send data to this device to.
My questions:

1. Is there any way to send data to my device in 16B or 32B packets? Can I use :
uchar usbFunctionRead(uchar *data, uchar len) and uchar usbFunctionWrite(uchar *data, uchar len)
functions ?

2. I don't know how to build usbHidReportDescriptor for my case (if possible :)).

Thanks,
Peter.

Re: HID keyboard - receiving data from PC

Posted: Wed Oct 21, 2009 4:44 pm
by Bernd
Is the PC you connect the USB-Device the same as you will send the data?

Re: HID keyboard - receiving data from PC

Posted: Wed Oct 21, 2009 6:23 pm
by Piotr Wilk
Yes, it's the same.

Re: HID keyboard - receiving data from PC

Posted: Sun Oct 25, 2009 11:07 pm
by christian
You can either send custom requests on endpoint 0 if your device decodes them as such and if Windows allows you to open the device. Or you can send configuration descriptors through the HID mechanism.