Hi there, I have a HID keyboard I would like to use with the Vero V. However, while it is recognized as an USB device key presses do not have any effect. It seems the kernel driver hid-ortek.ko is missing in OSMC on Vero V.
How can I possibly install it?
Any help is appreciated.
Does the manufacture of this device that you didn’t state the make and model of claim it has Linux support? Did you look on their website to see if they had installation instructions?
Well assuming that he refers to
I would assume it is an Ortek Keyboard
@xoocoon as this is quite a specific keyboard driver I doubt that @sam_nazarko would add it to the default image. So your only option is to compile it yourself. For hints search “compile kernel driver” in here
https://discourse.osmc.tv/search?q=compile%20kernel%20driver%20order%3Alatest
Thanks for your support. It worked out of the box on OSMC@raspi-4b. It seems OSMC for raspi ships with more standard modules.
And yes, the chipset is an Ortek one, lsusb says:
05a4:8003 Ortek Technology, Inc. USB Keypad
As I modified the case and built a tiny USB 2.0 hub into along with another small USB board, I cannot easily swap it physically. That’s why I would go for building the kernel.
I think that I only need to get as far as building hid-ortek.ko, as I could then integrate it into the /lib/modules directory of OSMC on the Vero V, then add it to the dependencies and refresh them via depmod.
I managed to build the module using the aarch toolchain. However, insmod yields:
could not insert module kernel/drivers/hid/hid-ortek.ko: Required key not available
Do I have to sign the module in some way? What else could help?
Fyi, modinfo yields:
filename: /usr/lib/modules/4.9.269-50-osmc/kernel/drivers/hid/hid-ortek.ko
license: GPL
alias: hid:b0003g*v00001223p00003F07
alias: hid:b0003g*v000005A4p00002000
alias: hid:b0003g*v000005A4p00001700
depends:
vermagic: 4.9.269-50-osmc SMP preempt mod_unload modversions aarch64
I can add the module to the kernel later today. This will save you having to rebuild it every update
Oh wow. Thanks a lot!
Sorry, took a day longer than expected as it’s busy here.
Should be solved with:
To test this update:
- Login via the command line
- Run the following command to add the staging repository:
echo 'deb http://apt.osmc.tv bullseye-devel main' | sudo tee /etc/apt/sources.list.d/osmc-devel.list
- Run the following commands to update:
sudo apt-get update && sudo apt-get dist-upgrade && reboot
- Your system should have have received the update.
Please see if the issue is resolved.
I also recommend you remove /etc/apt/sources.list.d/osmc-devel.list
after updating.
This will deactivate the staging repository. You can do so with the following command:
sudo rm /etc/apt/sources.list.d/osmc-devel.list
.
Please note that we will automatically disable this update channel after 14 days on your device in case you forget to do so to ensure that your system reverts to the stable update channel.
Thanks a lot, @sam_nazarko.
The module gets loaded, but to no avail. As it turns out, my device is only listed in the newer hid-ortek.c (i.e. in the most current kernel source, but not in the 4.9.x kernel source).
I am referring to this line in https://github.com/torvalds/linux/blob/master/drivers/hid/hid-ids.h:
#define USB_DEVICE_ID_ORTEK_IHOME_IMAC_A210S 0x8003
… referenced by this line in https://github.com/torvalds/linux/blob/master/drivers/hid/hid-ortek.c:
{ HID_USB_DEVICE(USB_VENDOR_ID_ORTEK, USB_DEVICE_ID_ORTEK_IHOME_IMAC_A210S) },
So I guess I will have to patch the files for the kernel 4.9.x and compile the module on my own.
Nevertheless thanks for your effort, @sam_nazarko
Is it just this backport that’s needed and no changes to the driver? If so, this can be included.
You could test by forcing a match on the module.
Everything points in that direction but I have yet to test it.
Will let you know as sonn as I get to it. Thanks.
I compiled the module for testing purposes with the 4.9.x OSMC kernel sources, but loading the module still fails with:
could not insert module kernel/drivers/hid/hid-ortek.ko: Required key not available
Google says that this is related to an unsigned kernel module when Secure Boot is enabled. However the Vero V does not have UEFI / Secure Boot as far as I know.
The corresponding module from your build, @sam_nazarko, indeed has a signature, as modinfo shows:
sig_id: PKCS#7
signer: Build time autogenerated kernel key
sig_key: 4E:9E:C5:13:81:05:85:C3:9E:D0:45:0A:54:19:5D:AC:C2:79:BD:42
sig_hashalgo: sha256
As it says “Build time autogenerated kernel key” I probably will have to build an entire OSMC kernel on my own to get the patched module loaded…
@sam_nazarko: Would you be willing to provide another test kernel if I provided a .patch file with the lines mentioned above?
You can’t. Maybe you could PR your patch to github.
Certainly.
Thanks. Here we go.
In addition to commit be47cf2 that adds the build config for the Ortek module, I submitted a PR based on vero564-source-4.9.269-53-osmc: [package] [kernel-osmc] Vero 4K/4K+/V: Support Ortek keyboard 05a4:8003 (iHome IMAC-A210S) by xoocoon · Pull Request #763 · osmc/osmc · GitHub
I can merge it upstream properly later
I’ve updated the kernel and this should now be solved. I would appreciate it if you could confirm this. You can follow the previous instructions.
Yes! It works. Thanks again.
As a side note, although the keyboard pulls in the hid-ortek driver automatically, the system does not automatically bind the driver to the corresponding hidraw device. But that’s the easy part - it can easily be solved in userland.