feat(Hardware Support): Add AYANEO NEXT 2 device and capability map - #658
Open
EightQuarterBit wants to merge 1 commit into
Open
feat(Hardware Support): Add AYANEO NEXT 2 device and capability map#658EightQuarterBit wants to merge 1 commit into
EightQuarterBit wants to merge 1 commit into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR implements support for the AYANEO NEXT 2, according to the issue opened here. After looking through the repo it seemed simple enough to implement myself, though I did hand off the legwork of writing the YAML files to Claude Sonnet 5, as well as having it verify I wasn't missing a file that needed to be modified.
The exact prompt I gave to Claude was:
That spat out the device and capability map, mostly cribbed from existing Ayaneo config. I went back and forth with Claude to see if there were better options than an Xbox Elite controller for this device, and to check up on LC/RC button functions, but in the end the only change I made to the generated config was renaming the "Ayaneo Button" from "Logo". I named it "Logo" in the issue, but it's labeled "Ayaneo Button" in existing capability maps, so that seemed like the better convention.
Tested on Bazzite Deck 44 by installing to
/etc/inputplumber/devices.d/and/etc/inputplumber/capability_maps.d/. After restarting InputPlumber, the built-in controller appeared as an Xbox Elite controller as expected. Back buttons were visible and successfully mapped/tested in Steam. The "Ayaneo Button" also correctly summons Quick Access. "T" button is mapped to QuickAccess2, which seems to take a screenshot in-game at the moment.A second, "ghost" Xbox Elite 2 controller also appeared on the system, though I've read reports of other users encountering the same behavior, so I'm assuming that's not a misconfiguration with these files. Claude seems to think it's InputPlumber generating a child Xbox Elite controller from my remapped physical controller. Surfacing it just in case that's not expected.
The "=" button was left emitting its default key combo since there didn't seem to be a better unopinionated option.
The LC and RC buttons, of course, weren't visible in Steam for mapping, since they aren't present on an Xbox Elite controller.
I haven't yet found a completely satisfactory way to test the gyro/accelerometer orientation, since that's not implemented on the Xbox Elite controller. There's no kernel-level mount matrix for this under
/sys/bus/iio/devices/iio:device0/in_mount_matrix, but watching the raw accelerometer output withwatch -n 0.2 'for f in /sys/bus/iio/devices/iio:device0/in_accel_x_raw; do echo "$f: $(cat $f)"; done'(repeat for Y and Z) it seemed to generate sensible values.Likewise I could not test setting the controller LED rings via InputPlumber in any way I or Claude could determine.
Happy to test further on either of those features if a more thorough test regimen can be recommended.