"Get the HID mouse class handle" in non-mouse related USB HID demo

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

"Get the HID mouse class handle" in non-mouse related USB HID demo

756 Views
crabbo_babbo
Contributor II

I imported a USB dev_hid_generic demo and saw this comment, after echoing "USB device HID generic demo".

 

 

        usb_echo("USB device HID generic demo\r\n");
        /* Get the HID mouse class handle */
        g_UsbDeviceHidGeneric.hidHandle = g_UsbDeviceHidConfigList.config->classHandle;

 

 

I wonder why is it there, since this demo clearly has nothing to do specifically with a mouse-related device - there are other demos for that.

This is what the demo description declares:

The USB HID generic application is a simple demonstration program based on the MCUXpresso SDK. It is enumerated as a HID-compliant device. A PC application can be used to exchange data with the device.

If I am using this demo for sending/receiving data from a device which is not a mouse, why would it "get the HID mouse class handle"?

Labels (2)
0 Kudos
3 Replies

736 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

HI crabbo_babbo

What's your chip part number? 

Please let me know, thus I will check.

Thanks,

Jun Zhang

0 Kudos

729 Views
crabbo_babbo
Contributor II

Hello, this is a LPC55S69-EVK

 

Have a good day

0 Kudos

723 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

Hi

Get HID handler (g_UsbDeviceHidGeneric.hidHandle ) is important here. 

But I agree with you that the comment may confuse people.

I will suggest it to SDK team.

 

Thanks,

Jun Zhang

 

0 Kudos