Configuring the XpPen ACK05 Remote with only FLOSS on GNU/Linux: my investigation and workarounds.
Here is my research on how to use and configure the XPPen ACK05 Remote using only Free Libre and Open Source drivers and software under GNU/Linux. As you'll see, it's quite limited and some features just don't work. This guide will be updated as soon as I have new information on how to improve it, or as soon as new development improves support for this device.
Terminology:
- ACK05 → The XPPen ACK05 Remote Controler device.
- FLOSS → Free/Libre and Open-Source Software.
Update:
- 2024-10-07: At the request of @whot, I released the full hid-recorder, on the udev-hid-bpf project.
- 2024-10-06: Added the Input-Remapper method thanks to a comment by Raghukamath.
Device presentation
The ACK05, looks like a numeric keypad with a dial ring and nothing written on the keys. It comes with the "Pro (gen2)" tablet models of the XpPen brand: the Artist Pro (gen2) 14, 16 and 19 but also the Deco Pro (gen2) XLW, LW and MW. Well, it sounds like XPPen just decided to make the ACK05 the default remote for all their future tablets.
I got mine with my XpPen Artist 16 Pro (Gen2), which I reviewed last year.
But you can also buy one alone on the XpPen store for about $50. In fact, you don't need to pair the ACK05 with a tablet to use it properly; it's a standalone device. For artists, this small keyboard gives them closer access to a number of common keyboard shortcuts.
Photo of the XPpen ACK05 in usage situation for me, a right handed user of the Artist 16 Pro
Disassembling the ACK05
The ACK05 is also a tiny programmable keyboard in disguise, the Official User Manual (PDF) mention the device has a small memory to store the configuration. It also has its own microcontroller unit (MCU), an ID M52833 QIAAA0 2310AI code on it, a Nordic nRF52* family. It's a multi-protocol system-on-chip with lots of information and specifications (PDF) on the manufacturer's website.
Photo: tearing down the ACK05 device
What works, what doesn't
USB-C cable connection → it works out-of-the-box. For some reason, it's the only way to connect the device on GNU/Linux right now.
Bluetooth direct → it doesn't work. I tested it on three Bluetooth-enabled GNU/Linux computers I had at home and different distros. You can turn on the device and press the middle-of-the-dial button for 6 seconds until the LED flashes quickly, but none of them will see or pair with the device.
The USB dongle → it doesn't work. This is strange because I have never seen a mouse or keyboard with its own USB dongle have this kind of problem.
The Default Keyboard Shortcuts → it works out-of-the-box with a rather questionable layout. On the plus side, you have the three keys Shift, Ctrl and Alt clearly side by side in the middle of the device, and underneath a space bar that is easy to reach with the thumb. Undo and redo are surprisingly FLOSS standard: Ctrl+Z for undo, and Ctrl+Shift+Z for redo. On the bad side, the ACK05 key layout under GNU/Linux will automatically load the same layout as your main keyboard layout: in my case an Azerty French keyboard. This means that the default Ctrl+Z of the ACK05 will return a Ctrl+W by default, which is dangerous because it closes the document in many applications. In addition, while shortcuts like Ctrl+O for opening files and Ctrl+N for creating new ones are standard, their non-frequent use in workflows raises questions about their necessity, since these actions are typically performed only once per artwork.
The Dial → it kinda works out-of-the-box. The dial returns a Ctrl+ and Ctrl- action. It zooms in and out in Krita, and that's fine. However, the middle button of the dial has no effect and feels like it is disabled.
Customisation of keys → you can improve it, slightly. And that's my transition to the next part of this article!
Customising the keys
The input-remapper method
Input remapper is a software that can change the behavior of almost any input device. It supports X11, Wayland, combinations, programmable macros, joysticks, wheels, triggers, buttons, mouse movements and more. In short, it maps any input to any other input.
If you haven't read the User Guide, it might take you a while to understand the GUI and how to set up your first key association with a new device. But once you get started, you'll notice it can also map macros and also mouse clicks if you ever want a key to trigger Krita's pop-up palette. A list of examples will help you understand the endless possibilities, like setting new shortcuts when you double-tap a key, or assigning multimedia keys.
Also, amazingly, the input remapper is able to catch the event for the middle key of the dial. It catches it for a "Ctrl+$" input, no surprise this key didn't do anything on my computer. but setting the dial with it is still very difficult: it looks like it's not capable of catching the events correctly. When tested: the keys of the dial remains not really functional.
Finally, the input remapper developers made it easy to move the configuration from one machine to another by storing the preferences in JSON files that are simply stored in $HOME/.config/input-remapper-2
.
So the main drawbacks: the dial doesn't work with it and I couldn't find a macro code to switch to the next preset. So it looks like it is not possible to use multiple layout this way.
The Input-remapper interface while configuring the first top row of buttons of the ACK05
The udev/hwdb.d method
If you can't install or run input-remapper, your only other option is to manipulate the keystrokes of the default built-in layout directly with a udev/hwdb.d ruleset. This is far from ideal and has many limitations, but at least it succeed at customizing a part of the dial inputs. I have already published a full tutorial on this for USB numeric keypads.
the MSC Scan code on the default layout.
The limitations: You cannot change, for example, the 'Ctrl+O' (double-key) shortcut to 'M' (single-key). You can only replace one of the keys in the shortcut. For example, you can change the 'O' to a 'T', and the shortcut will become 'Ctrl+T' (transform tool in Krita). Also keep in mind that changing 'Ctrl' will affect all other shortcuts that use 'Ctrl', so it's generally not advisable to do this.
With this limitation, all I can do is find a better use for the top three shortcuts. I'm going to replace them with a quick action combo in Krita to deform/scale/rotate an area: Ctrl+r (rectangular selection), Ctrl+t (transform), Enter (apply/confirm/validate). I'll also fix the bug with the French Azerty layout that prevents me from using Undo and Redo.
The MSC Scan change proposal, in green.
Follow the my previous tutorial for detailed steps, but in short, I create a new udev/hwdb.d rule:
sudo $EDITOR /etc/udev/hwdb.d/99-xppen-ack05-remote.hwdb
And I paste this custom code for the keys (and also my fix for the Azerty keyboard on the last line).
evdev:input:b0003v28BDp0202*
KEYBOARD_KEY_70012=0x13 # [o] => [r]
KEYBOARD_KEY_70011=0x14 # [n] => [t]
KEYBOARD_KEY_7003e=0x1c # [F5] => [enter]
KEYBOARD_KEY_7001d=0x11 # /! azerty french keyboard fix [z] => [w]
then I save and refresh systemd-hwdb and udevadm.
sudo systemd-hwdb update && sleep 2 && sudo udevadm trigger
done!
Programing the hardware
It's probably impossible to program the ACK05 with FLOSS. And by that I mean storing a firmware directly in the flash memory of the micro controller and reprogram the default shortcut keys at root.
I spent more than a day trying and every method I tried was a dead end. Even for specialized FLOSS software in programmable keyboards like QMK Firmware it is impossible. FLOSS projects tend to flee the Nordic nRF52* family of micro controllers because all the tools available so far are proprietary.
(Note: I'm not even 100% convinced that this is a feature of the product, but there is a "Save" and "Import" feature on the Windows driver, according to the documentation. It could simply be a way to save the setting that the driver will load later).
Conclusion
No wireless and a dial that does not really work (especially the middle button). Yes, it's far from what this device is capable of: being wireless and having multiple layouts.
But the fact that it somehow works for its core functionality "out-of-the-box" and without anyone working on a specific driver is a kind of small miracle of ingenuity; both from XpPen and from the input-remapping team and input Linux developers. So bravo!
An idea for XpPen engineers; if you want to make the next iteration better, just look at how an open source project like the Duckypad handles drivers and customization.
In any case, a simple $15 USB numeric keypad will be of more value to your workflow under GNU/Linux such as the one I build in my tutorial. There are many variations on this: my favorite shortcut device at the moment is a little yellow "8Bit do Zero 2" gamepad. It connects via bluetooth and has a built-in mode that turns all buttons into keyboard input (with only one key press, for video games). With a udev/hwdb.d rule it became a perfect keyboard shortcut tool while painting. Especially because I can hold it in my left hand and it follows all my positions.
Sources
- The ACK05 Official User Manual (PDF).
- The ACK05 on XpPen store (not affiliated
- Screenshot on Reddit of firmware uploading on MsWin (in comments).
- QMK Firmware, a FLOSS CLI app for keyboard firmware.
- QMK "Compatible Microcontrollers" documentation.
- QMK issues mentioning nRF52 on Github
- nRF52 MCU informations, specifications (PDFs).
- Adafruit_nRF51822_Flasher.
- Nordic proprietary CLI tool for nRF52
- Arch Linux documentation about Scancode using Udev
- Review of the XpPen windows proprietary driver on Parkablog
- ACK05 hid-recorder dials and all keys: issue on the udev-hid-bpf project
61 comments
Konqi@mastodon.social
Hello David! I did not realize that you are not using Wacom tablets anymore.
davidrevoy
@Konqi Hey, yes. My last one was a Intuos Pro Large, a gift from Wacom (src: https://www.davidrevoy.com/article921/ ), but I managed to "scratch it to death" and make the stylus wobble so much in 9 months of intensive usage that this model wasn't usable anymore... Their quality really went downhill while still getting a high price tag.
9 ★On another hand, for the same period of usage my Artist 16 Pro gen2 of XpPen is still on my desk, and functional as in day 1. I'll soon try their 19 Artist Pro. 😊
Konqi@mastodon.social
David, how good is Linux support using XP Pen vs Wacom, just for curiosity.
davidrevoy
@Konqi On Wayland, both are still atrocious and reduced to bare minimum.
On X11, Wacom has a better support and some DE like Plasma propose a descent GUI for configuring them
5 ★On another hand, the XPPen models are supported mostly by pure luck when their circuit board is standard UGEE Tablet architecture already supported in the kernel, and then, even with that they require post tweaks and scripts. That's what I try to post on my blog, under the "hardware" tag https://www.davidrevoy.com/index.php?tag/hardware
Konqi@mastodon.social
Excellent! Thank you David, I was asking you about your experience because following your post series I started to get interested into maybe acquire one inexpensive table for personal use.
★dustin@dustinwilson.com
I ran into the same problem with Wacom's tablets where the surface would wear down and become unusable. I went through two of them at an old job. I've been using an Intuos 4 XL at home for 14 years without any issues. I thought I'd try some new ones, but I wasn't about to buy an Intuos Pro. I got an XP-Pen Deco Pro XLW a few months ago. I'm worried it might wear down like the Intuos Pros did. Yours hasn't yet?
dustin@dustinwilson.com
I was seriously considering putting some sort of adhesive protector on it so when it does wear down I can just replace it... like the old Wacom tablets had.
davidrevoy
@dustin I never tried the XP-Pen Deco Pro series (nor the new gen2) so I can't really give you a feedback about what I'm thinking about the quality of the overlay surface, all I can say is they look amazing from what I see on the shop/product info, especially for non-display tablet. Three sizes, and the same tech for the stylus as my Artist Pro 16 gen2. After the review of the 19 Pro gen2 and if everything goes well, I'll probably ask my contact at marketing to try a medium model of that. 1/2
★davidrevoy
@dustin overlaying the default surface is always tricky: it's a very hard to balance game of plastic hardness.
★I think the right balance is when the stylus tip is slightly softer than the surface; so this one doesn't scratch the surface at all and the tips wears slowly, take a gentle flat that improve a bit the feeling of friction that is necessary to get a minimum feedback while tracing.
Unfortunately, manufacturer never publish the surface or plastic of the tip hardness on the Mohs scale. 2/2
dustin@dustinwilson.com
Yeah exactly. This one doesn't feel like you're scratching into the tablet with a diamond like it does with Wacom at least, but I'm just wary. I've only just within the past couple of days really started using it a lot, so maybe I'll see if I've worn into it after a few months of use.
★kate@federatedfandom.net
I was just thinking I should check your blog to see how that brand plays with foss... Your timing is immaculate
davidrevoy
@kate 😊 Thank you. Well, I have so far workaround for the 16 Artist Pro (gen2) and the 24 Pro ( https://www.davidrevoy.com/index.php?tag/hardware ), all other model of this brand is still a bit in the unknown.
4 ★I decided to accept a review for their 19 Artist Pro, deadline: mid November (I still haven't got it). So, I hope this model will have the same circuit board than the 16 Artist Pro (gen2) and I'll can just copy paste my method and adjust some variable here and there. 😆
silmathoron@floss.social
you're on X11, right? Do you know if that works also for wayland?
davidrevoy
@silmathoron Hey, yes, I'm still on X11, KDE Debian 12. (due to Krita not being designed for Wayland and buggy under XWayland, issues with color management, and tablet configuration).
Udev is also part of Wayland, afaik, so it should also work there ™ (but untested here)
★TopazRabbit@oldbytes.space
I had looked into this and decided to design my own macropad instead. I figured it would be a pain to configure in Linux. :blobcry:
davidrevoy
@TopazRabbit You did the right thing, imo! 👍
This ACK05 is so locked at its core... When I see in comparison the current Kickstarter for the new Duckypad Pro ( https://www.kickstarter.com/projects/dekunukem/duckypad-pro-advanced-macro-scripting-beyond-qmk-via ) and all the features it puts on the table and the ease of configuration... the OLED screen, etc... :blobaww:
It's amazing how far XPpen are lagging behind in terms of usability despite having the hardware.
4 ★tirifto@jam.xwx.moe
@TopazRabbit But does it quack when you press a key? :gutkato_pensas: ★
poleguy@mastodon.social
@TopazRabbit I'd love to see your progress. I did a macropad for Linux for myself on the cheap. I use it daily and it is magical!
https://github.com/poleguy/remap
I also use a work provided huion Kamvas pro 13 for remote whiteboard type engineering work (krita mostly). Pen works fine but I never bothered configuring the buttons on it.
★TopazRabbit@oldbytes.space
@poleguy Here's what I have so far. No public plans available yet, but I'll get around to it eventually. Uses QMK for config and has hot swappable sockets for the keys.
🖼️ 1d817322dfaaf14a.jpgdavidrevoy
@TopazRabbit @poleguy 😍 Wow! Good work 👍
★raghukamath@raghukamath.com
I have somewhat accepted this fate and tried to use it with the input remapper program. As for the tablet I wish to see udev-hid-bpf work with default Debian kernel. that would take away some burden of keeping the liquorix kernel up to date for security reasons.
davidrevoy
@raghukamath Oh yes, this Debian policy to not get the bpf system in their default kernels is really a pain...
I haven't retried the input-remapper in age with this device and forgot about it: can it bypass the two key shortcut and assign instead only a single keypress? (eg. reassigning the Ctrl+O to a simple B?)
raghukamath@raghukamath.com
Yes it can, I have mapped it to E key. The only issue I found that it is hard to map Ctrl N since input remapper captures this as a shortcut for itself to create a new shortcut entry scheme :) so it drops your exisiting changes when you press Ctrl N and creates new list of entries :P. May be worth filing a bug with input remapper but I did not have time to check it out further.
davidrevoy
@raghukamath Thank you for the feedback and confirming, I had a vague souvenir input-remapper was indeed capable of this.
I'll retest it and update the blog post, this is a very useful information. 👍
(and haha for Ctrl+N. I had the same issue with running evtest ; the Ctrl+Shift+Z (w because of azerty here) button was triggering the "Close Session" of Konsole here. Impossible to get the MSC scan code of the key without configuring the shortcut of Konsole. 😆)
★davidrevoy
@raghukamath Article edited with a new chapter for input-remapper, thanks again!
★raghukamath@raghukamath.com
hey deevad thanks for updating the article. It seems you are using a newer version of input-remapper it looks different than my version from debian repo. Did you install it from somewhere else?
davidrevoy
@raghukamath Hey, yes: I got it from the Github repo; the 2.0.1 from September 2023, it has a deb package so I tried and it works 😊 💜 :debian: https://github.com/sezanzeb/input-remapper/releases
4 ★raghukamath@raghukamath.com
Unfortunately i had earlier version installed and when I tried to install it from github few months ago it gave me some error about missing service which i couldn't solve back then, I might give it another go
davidrevoy
@raghukamath True, I quickly browsed my bash history and had (I think) to `sudo apt install pkexec` because it wouldn't launch from the main menu icon and once I tried to exec it via CLI in Konsole I think it complained about not having this libs.
raghukamath@raghukamath.com
and also @redstrate , I was testing neon unstable iso and surprisingly this shortcut remote was listed in the drawing tablet settings dropdown. Although it being the remote meant there was nothing to configure. But I think here the drawing tablet KCM should take into account that this is a keypad and hide the options like monitor mapping and calibration and provide the option to assign keyboard shortcuts.
🖼️ 1f1af19d0e3296b6.pngredstrate@mastodon.art
Can you do a `sudo libinput list-devices` and paste it in a bin somewhere? I wonder why it's reporting itself as a tablet pen 😄
davidrevoy
@raghukamath @redstrate Support is coming 😉 WIP:
3 ★- https://gitlab.freedesktop.org/libevdev/udev-hid-bpf/-/issues/32
- https://github.com/linuxwacom/libwacom/pull/777
and on Gnome https://gitlab.gnome.org/GNOME/gnome-control-center/-/issues/3216
redstrate@mastodon.art
@raghukamath Oh cool! So it's the same remote I saw in chat :)
★raghukamath@raghukamath.com
That is nice to see. Kudos to @whot and Benjamin Tissoires 👏🏼
★csolisr@hub.azkware.net
Talking about open-source firmware, are there any macropads that use QMK? qmk.fm/
davidrevoy
@csolisr Yes, some exists and I could find them in my research using a search with the keyword "pad" on this big list https://github.com/qmk/qmk_firmware/tree/master/keyboards ; but I also learnt that QMK just reasign keys; you can't really make complex macro with it.
★The best option remains, IMO, pad like the https://www.tindie.com/products/dekuNukem/duckypad-do-it-all-mechanical-macropad/ , with a script language that you can edit on the built-in SDcard reader and that can execute complex macro and support multiple layout (and OLED screen). and it's open and OS independant.
overbyte@gamepad.club
I found using the xppen artist pro 16tp on Ubuntu with wayland and multiple screens to be a crap fest with crashing drivers for the tablet functionality and setting the active area in the software being a pain. The screen came straight up though
davidrevoy
@overbyte I guess you are using the proprietary driver when you say "crashing drivers"; if you combine that with Wayland and possibly some Snap Ubuntu in the mix I can indeed imagine the crap fest. 🤔
All I can propose is what I wrote about my distro of choice: https://www.davidrevoy.com/article1030/debian-12-kde-plasma-2024-install-guide , and https://www.davidrevoy.com/article1004/xppen-artist-pro-16-gen-2-review-on-gnulinux about how to configure the Artist 16 Pro with only Free/Libre and Open Source Software. Here this mix is really solid and stable.
2 ★overbyte@gamepad.club
thanks very much. I’ll have read
★Ray_Of_Sunlight@mastodon.social
Windows users: **Scream and run in fear**
★frd@pixelfed.social
One of the tasks of KDE Goals' - We Care About Your Input goal is to simplify this process. There is a Matrix room if you'd like to keep up with the progress or join the effort. Here: https://matrix.to/#/#kde-input:kde.org ★
davidrevoy
@frd Thank you! I'll join.
★Nekofreak@mastodon.social
Many thanks for all the work you do for all of us FOSS dorks. The last job I had I was able to fulfill all my design duties using open source only and I believe I have to thank you for showing me and many others it was possible.
★davidrevoy
@Nekofreak Thank you! ☺️
whot@fosstodon.org
a naive guess says this should work just like the expresskey remote and the default mappings look suspiciously similar to the inspiroy. Do you mind filing a bug against udev-hid-bpf with the hid-recorder output for each button? We might be able to remap this to button 1..x, add it to libwacom and then have the default button mapping interfaces work.
★davidrevoy
@whot Remap the keys of the ACK05 as tablet buttons? 🤯 Sounds like a brilliant idea and it worth trying it. Sure, I'll fill a new issue with all keys and dial output with hid-recorder.
★davidrevoy
@whot By the way, I have seen the replay of your conference with Benjamin at the Linux Plumbers Conf in Vienna. https://www.youtube.com/live/rQtQ-Nd1ZmA?t=28884s , it was very interesting! 👍
I really enjoyed learning about the structure of the project, the user hack/testing/stable and the naming convention. It helped me at browsing the source (even if I can't still understand what's going on for many lines, even on simple one like the code for the foot pedal 😆 https://gitlab.freedesktop.org/libevdev/udev-hid-bpf/-/blob/main/src/bpf/userhacks/0010-QuinHeng__PCsensor-FootSwitch.bpf.c?ref_type=heads ) But I'm trying to learn.
whot@fosstodon.org
I recommend reading my post on understanding HID first, no chance to understand this otherwise.
https://who-t.blogspot.com/2018/12/understanding-hid-report-descriptors.html
The *code* is simple, but only if you understand all the magic that goes on behind the scenes :)
As it happens, udev-hid-bpf also has a tutorial which may make things more or less confusing: https://libevdev.pages.freedesktop.org/udev-hid-bpf/tutorial.html
wayofwood@mastodon.social
Did you have a look at actkbd? It can call scripts based on keys from a specific device. This should make it easy to implement different layers. I have some keys configured to work differently depending on the active window - which works nicely...
biscuitcats@mastodon.social
Mhh, is the premise that a macro pad is better in the long run? How would it compare with something like this? https://www.whatgeek.com/products/doio-kb16-01-macro-keyboard-16-keys-3-knob-macro-pad
davidrevoy
@biscuitcats Hey, that's the main point of my conclusion in the article. But I redirect to a more open and easy to program one, the DuckyPad https://www.tindie.com/products/dekuNukem/duckypad-do-it-all-mechanical-macropad/ or a ~15$ DIY on top of a USB numeric keypad.
★biscuitcats@mastodon.social
hehe! I actually did read it (most of it the technical parts are just beyond my level) unfortunately I do not have the tools or skills for a DIY route (Also I like pink) The macro pads market is quite big and that's awesome the more choice the better even if you can't DIY your whatever reason.
★davidrevoy
@biscuitcats True!
mhunt@socel.net
didn't you have a custom made pad ?
davidrevoy
@mhunt Oh yes, I have this one https://www.davidrevoy.com/article989/how-to-customise-a-usb-numeric-keypad-under-gnulinux , and also a 8bit do zero gamepad (mini).
★But I just saw this Xppen ACK05 was now the default with all newer XpPen tablet and started to think it should probably get a better support. A fun rabbit hole 🐰
mhunt@socel.net
Good luck ! Hope you make it work.
icedquinn@blob.cat
> input remapper
TIL
i've done a wee bit of hardware hacking like this in the past.
though i'm not sure why there isn't some quivalent that has via configs. a tiny keyboard and a scroll wheels not super complex ★
marsik@witter.cz
The Nordic chip is quite popular in the maker community. It is just the Bluetooth soft core that is closed. I did some analysis of the device and the firmware is not even locked and can be downloaded. A new one could be written too, but it is a lot of work to implement the HID stack over Bluetooth. So at the end I decided to write a user space remapping program that utilizes the same raw mode the original application provided by XP pen uses. https://github.com/MarSik/kymars-xppen-act05
★davidrevoy
@marsik Wow! That's really cool and thank you for the info and sharing your code under GPL.
I tried to search Github prior making my article, but with the keyword ACK05 ; I see you use ACT05, do you think it is a slightly different device?
I'll test and note to update my article and include your user space remapping software. 👍
marsik@witter.cz
I think I just messed up the name, mine is ACK05 as well. I will fix the description to appear in searches.
marsik@witter.cz
I fixed the name 🤦 and checked my notes. I was thinking maybe ZMK could be used (zmk.dev, under MIT license, supports NRF52), but never got to do it. The exact cpu in the keyboard is nRF52833 and I have most of the pins mapped. I was able to read all keys, rotary encoder and blink with LEDs as well as read the power switch and turn off the device power via a SWD debugger. Just in case someone is interested in implementing the firmware. I have no time for that myself.
★Post a reply
The comments are synchronised every 12h with the replies to this post on Mastodon:How to use this? (click here to unfold)
Open a new Mastodon account on the server of your choice. Then, Copy/Paste the adress above in your Mastodon 'Search' field. The post will appear and you'll be able to fully interact with it. You'll have full control of your posts: edit, remove, etc. After that, your message will appear here.
Just please note that it may take up to 12 hours for your changes to be reflected here.