UVC + HID. How ?

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
VlKh_2251656
Level 5
Level 5
10 likes given 5 likes given First like received

Hello!

I have a Denebola board (uvc inteface).

I connected the button to it via the gipio connectors.

Tell me, what actions are required to be performed with the code (how to modify the program code) so that clicking this button would be equivalent to pressing the mouse button?

Ideally, I want to add a real hid device.

Tell me, please, how is this done?

0 Likes
1 Solution

Hello Vladimir,

To implement the device as HID class compliant with the button events, HID class request handlers have to be added. Please refer to the project attached in FX3 Composite Device with HID Keyboard and UVC for details on how to handle the class specific requests.

Best regards,

Srinath S

View solution in original post

9 Replies
SrinathS_16
Moderator
Moderator
Moderator
1000 replies posted 750 replies posted 500 replies posted

Hello Vladimir,

Please refer to FX3 Composite Device with HID Keyboard and UVC

Best regards,

Srinath S

0 Likes

Many stanks, but I have a denebola.

I see example

https://community.cypress.com/thread/31593?q=UVC%20+%20HID

but it defined as usb2 device eveb usb3 port

It's a problem...

0 Likes

Hello Vladimir,

Please check the CyU3PConnectState() API in the firmware source code. It has got a parameter to enable/disable the USB3.0 functionality. Kindly, check if it is enabled.

Best regards,
Srinath S

Many stank!

I will check it.

0 Likes

many thanks!

0 Likes

Аnd tell me, please, the descriptors in the case of USB2.0 for the HID device differ from the descriptors for HID in the case for USB3.0?

0 Likes

I added descriptors for the HID interface in USB2.

it is defined AS COMBO DEVICE (UVC + HID), but it does not send push button events.

as I understood, we also need to write handlers for USB2 case..

0 Likes

Hello Vladimir,

To implement the device as HID class compliant with the button events, HID class request handlers have to be added. Please refer to the project attached in FX3 Composite Device with HID Keyboard and UVC for details on how to handle the class specific requests.

Best regards,

Srinath S

many thanks!

0 Likes