Creating a HID device - Apalis

I am using the Apalis iMX6Q evaluation board.

In the USB Device Mode (Linux) article there is mention of creating a USB HID device.

Unfortunately I have not managed to get this to work. Research indicates that the HID configfs interface is provided by the usb_f_hid.ko module.

This module is not available for Linux 3.14 (using the Apalis IMX6 Linux image V2.6b1). I understand that this module is introduced in kernel 3.19.

Do I need to compile a newer kernel or is there a simpler way forward?

Thank you.


You’re right that there is no USB HID Gadget driver controlable through the configfs in the 3.14 kernel.

However a USB HID Gadget driver can be enabled which is configured with platform data. CONFIG_USB_G_HID

Compare with gadget_hid.txt.


Hi Max,

Thank you for this answer. I have managed to the the g_hid.ko to work.

The issue is that I need a composite device and g_hid does not support this.

What is the state of linux toradex_imx_4.1.15_1.0.0_ga-next?
Does it have hardware acceleration support for IMX6?

Another option may be FunctionFS?

Thank you,

Hi Shaun

The toradex_imx_4.1.15_1.0.0_ga-next branch is currently only used with a Colibri iMX7. While we will port the i.MX6 based modules to that branch no work on that has started yet.

Does it have hardware acceleration support for IMX6?
I’d expect this, however as work has not even started yet I don’t know.