HID keyboard - receiving data from PC

General discussions about V-USB, our firmware-only implementation of a low speed USB device on Atmel's AVR microcontrollers
Post Reply
Piotr Wilk
Posts: 2
Joined: Wed Oct 21, 2009 2:18 pm

HID keyboard - receiving data from PC

Post by Piotr Wilk » Wed Oct 21, 2009 2:51 pm

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.

Bernd

Re: HID keyboard - receiving data from PC

Post by Bernd » Wed Oct 21, 2009 4:44 pm

Is the PC you connect the USB-Device the same as you will send the data?

Piotr Wilk
Posts: 2
Joined: Wed Oct 21, 2009 2:18 pm

Re: HID keyboard - receiving data from PC

Post by Piotr Wilk » Wed Oct 21, 2009 6:23 pm

Yes, it's the same.

christian
Objective Development
Objective Development
Posts: 1443
Joined: Thu Nov 09, 2006 11:46 am

Re: HID keyboard - receiving data from PC

Post by christian » Sun Oct 25, 2009 11:07 pm

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.

Post Reply