Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added support for Lenovo Ideapad Duet #636

Merged
merged 9 commits into from
Mar 2, 2024
15 changes: 15 additions & 0 deletions data/leonovo-ideapad-duet.tablet
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#This is for the Google Kukui Lenovo Ideapad Duet
whot marked this conversation as resolved.
Show resolved Hide resolved

[Device]
Name=Lenovo Ideapad Duet
Class=ISDV4
DeviceMatch=i2c:27C6:0E30
Width=8.5
Height=5.25
Neolanco marked this conversation as resolved.
Show resolved Hide resolved
IntegratedIn=Display;System
#Styli=@generic-no-eraser
Styli=0x812
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you run libinput record, the ABS_MISC event tells you the tool id and thus the styli to pick. Generally if you support 0x812 that means you also support the various other pens in that group - though 0x812 is the very old intuos pen (15+ years old now).

So my guess is that it's either @generic-no-eraser or the @isdv4-aes group or we need another set of pens defined here.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually, in the libwacom repository there's ./tools/show-stylus.py which will tell you the tool ID in slightly more human-readable format.

Copy link
Contributor Author

@Neolanco Neolanco Feb 14, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually, in the libwacom repository there's ./tools/show-stylus.py which will tell you the tool ID in slightly more human-readable format.

So this is my output:

./show-stylus.py
Using "hid-over-i2c 27C6:0E30 Stylus": /dev/input/event5
Using stylus file(s): /usr/share/libwacom/libwacom.stylus
Tool id 0x1 serial 0x0 in-proximity: False 
^CTerminating
Suggested line for .tablet file:
Styli=isdv4-aes

But 0x1 has a button and a eraser button, which mine doesn't. I also couldn't find one that has.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

0x27C6 says it's a Goodix USB ID so basically what we have here is a stylus that's not a wacom stylus and libwacom implicitly assumes that all styli with IDs are wacoms.

So if the ID is "re-used" we need to fix libwacom to be able to tell the difference between wacom styli and non-wacom styli. Then we can add a new definition for this stylus with 72C6:1. I wonder what the effect of this will be on the API...


[Features]
Stylus=true
Touch=true