![]() |
[How to do instruction] Using a wireless USB Keypad as remote control - Printable Version +- Moode Forum (https://moodeaudio.org/forum) +-- Forum: moOde audio player (https://moodeaudio.org/forum/forumdisplay.php?fid=3) +--- Forum: FAQ and Guides (https://moodeaudio.org/forum/forumdisplay.php?fid=9) +--- Thread: [How to do instruction] Using a wireless USB Keypad as remote control (/showthread.php?tid=5836) Pages:
1
2
|
RE: Using a wireless USB Keypad as remote control - krimikael - 01-14-2024 (01-14-2024, 09:00 PM)Nutul Wrote:(01-14-2024, 08:08 PM)krimikael Wrote: Ok, i think i found the cause, mini keyboard is not recognized by the pi-zero. Ofcourse i would rather have this working with the small keyboard. Anyway i connect everything again, rebooted and stangely everything works now with the small keyboard now aswell ![]() mk@FLY32:~ $ lsusb Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub mk@FLY32:~ $ lsusb Bus 001 Device 003: ID 1189:8890 Acer Communications & Multimedia Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Hope it will stay this way now ![]() RE: Using a wireless USB Keypad as remote control - Nutul - 01-14-2024 (01-14-2024, 10:08 PM)krimikael Wrote:(01-14-2024, 09:00 PM)Nutul Wrote:(01-14-2024, 08:08 PM)krimikael Wrote: Ok, i think i found the cause, mini keyboard is not recognized by the pi-zero. I don't know if this is normal (whether always, or just for the 'zero'), IMO it isn't; but looks like the keyboard insertion does not trigger the creation of the input device... Anyway, never disconnect it and reboot, as just re-plugging it in won't, again, work. ;-) RE: Using a wireless USB Keypad as remote control - muddiver - 01-15-2024 Hi folks! I am not a Linux-Crack, it's just copying Code that i almost understand ;-) I discovered the event-number with the command: cat /proc/bus/input/devices The output is a bit difficult to read, it should look like this.. I: Bus=0003 Vendor=0513 Product=0318 Version=0110 N: Name="HID 0513:0318" P: Phys=usb-0000:01:00.0-1.3/input0 S: Sysfs=/devices/platform/scb/fd500000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/usb1/1-1/1-1.3/1-1.3:1.0/0003:0513:0318.0001/input/input0 U: Uniq= H: Handlers=sysrq kbd leds event0 B: PROP=0 B: EV=120013 B: KEY=1000000000007 ff800000000007ff febeffdff3cfffff fffffffffffffffe B: MSC=10 B: LED=7 I: Bus=0003 Vendor=0513 Product=0318 Version=0110 N: Name="HID 0513:0318 Mouse" P: Phys=usb-0000:01:00.0-1.3/input1 S: Sysfs=/devices/platform/scb/fd500000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/usb1/1-1/1-1.3/1-1.3:1.1/0003:0513:0318.0002/input/input1 U: Uniq= H: Handlers=mouse0 event1 B: PROP=0 B: EV=17 B: KEY=1f0000 0 0 0 0 B: REL=1943 B: MSC=10 The upper one is my keyboard, it is "event0", which can be seen in the line beginning with H: You should search for "HID" HumanInterfaceDevice oder keyboard, or something with USB:... Now, we know which device should be used, and we can change the "event" in the command sudo thd --dump /dev/input/event0 to the device we need. Then the command should work.. Greets, Thomas RE: Using a wireless USB Keypad as remote control - TheOldPresbyope - 01-16-2024 Looking back at the Guide I created three years ago, Using FLIRC and other input devices for remote control, I see that i used a wildcard to scan all the input events. Specifically, to see and save the keyscan codes as I pressed keys, I did Code: thd --dump /dev/input/event* | tee keycodes.cap I'm curious to know if this works for your case as well, rather than having to laboriously dig through the Linux arcana. Seems to me it should as long as you press only keys and don't move the mouse. It seems the older I get, the more quickly I forget the stuff I have done before. Used to take me over decade to forget; now it takes about 18 months. The trend isn't reassuring. Regards, Kent RE: Using a wireless USB Keypad as remote control - muddiver - 01-16-2024 Hi Kent, Thank you for your help, i will add that command to my "favorite copied commands" selection ;-) Greets, Thomas RE: Using a wireless USB Keypad as remote control - TheOldPresbyope - 01-16-2024 PS - even if there are multiple input devices attached and more than one is accidentally pressed/released/moved/etc., it should be pretty easy to tell which events are associated with which device, and then filter accordingly. |