XMBC Simulated Keys via external hardware (arduino) device

x64 Replacement/Alternative to Microsoft's IntelliMouse application.
Forum rules
Please read the forum rules before posting for the first time.
The more information you can provide, the quicker and more accurately someone can help.
NOTE: To reduce spam, new users can not post links, files or images until they have at least 4 posts.
Post Reply
User avatar
phil
Site Admin
Posts: 7602
Joined: Sun Apr 06, 2003 11:12 pm

XMBC Simulated Keys via external hardware (arduino) device

Post by phil »

So, after a few discussions with people on the discord channel, I have been playing with using an Arduino to send simulated keystrokes instead of the MS SendInput APIs.

The Arduino is a tiny, cheap USB device that runs custom firmware. It is able to act as a USB HID device, and thus its just like a physical keyboard, but programmable. Ive written a simple firmware that XMBC can communicates with, and send keys that way. This means that the keys come from what appears to Windows as a standard, physical keyboard, which in turn means that the keys should work in any application, even if they don't accept simulated input (SendInput).

Curious to see if anyone is interested in testing it? If you are you will needs an Arduino based Pro Micro (may work with clones that use the ATmega32U4 CPU and support HID and serial communication at the same time - maybe all, I don't know) And it may need some further tweaks/config in XMBC for devices other than the Pro Micro (that I got amazon UK for about £12).

It's obviously a bit advanced, and still in its early stages, but it seems to be working for me. Its a bit slower than using SendInput, because each key down and up is sent to the device over its virtual serial COM port and waits until the device acknowledges it, but it can repeat keys at about 50-60ms. This can probably be improved but will require a lot more coding on the Arduino - and Im only just learning that :lol:.
--[ Phil ]--
--[ Administrator & XMBC Author ]--
Logitech G9/G604/M720/MX518, Microsoft Intellimouse, Trust 16341 BT Mouse
Windows 10 x64, AMD Ryzen 5900x, MSI x570 Tomahawk, 32GB DDR4,
nVidia RTX 2070s, Evo 970 1Tb NVME, 2x2TB WD Black (RAID1)
Post Reply