Skip to content

fix(ROG Ally): invert gyro yaw for deck-uhid target#607

Open
lonsdaleite wants to merge 1 commit into
ShadowBlip:mainfrom
lonsdaleite:fix/rog-ally-gyro-yaw-invert
Open

fix(ROG Ally): invert gyro yaw for deck-uhid target#607
lonsdaleite wants to merge 1 commit into
ShadowBlip:mainfrom
lonsdaleite:fix/rog-ally-gyro-yaw-invert

Conversation

@lonsdaleite

Copy link
Copy Markdown

Summary

Fix inverted gyro yaw (left/right rotation) on ASUS ROG Ally devices when using the deck-uhid target.

Problem

On ROG Ally / Ally X / Xbox Ally, gyro yaw is reversed with deck-uhid compared to ds5-edge. The IMU source is fine; the mismatch is in how yaw is written to the Deck UHID report versus how hid-steam exposes it as ABS_RZ.

Changes

  • Add invert_gyro_yaw to SteamDeckConfig
  • Apply yaw sign correction when writing gyro data in steam_deck_uhid
  • Enable inversion only for Ally DMI board names: RC71L, RC72LA, RC73XA, RC73YA (from the existing 50-rog_*.yaml profiles). This avoids affecting other handhelds that also use a BMI323 IIO source (e.g. Ayaneo). Detection uses runtime DMI board_name, so it still applies when the composite profile name is changed for controller spoofing.

Test plan

  • Tested manually on ASUS ROG Xbox Ally X with deck-uhid target
  • Verified left/right gyro rotation in inputplumber device 0 test
  • Compared behavior against ds5-edge target (yaw direction matches)

ROG Ally devices report gyro yaw with the opposite sign from what
hid-steam expects when using the deck-uhid target. Enable yaw inversion
only on known Ally DMI board names (RC71L, RC72LA, RC73XA, RC73YA).
@pastaq

pastaq commented Jun 15, 2026

Copy link
Copy Markdown
Contributor

This makes no sense to me. There are three distinct possibilities for this:

  • 1.) The ds5 yaw is wrong for all devices.
  • 2.) The deck-uhid is wrong for all devices.
  • 3.) The IMU matrix is wrong for the ROG Ally along with one of the previous two, leading to an inverted conclusion of which is wrong.

Given that SteamOS officially released on the Go S and was validated by Valve, and that it has been tested as 1:1 compatible with the deck as a source device, I think it's much more likely that 1 and 3 are more likely.

@lonsdaleite

lonsdaleite commented Jun 15, 2026

Copy link
Copy Markdown
Author

I didn't update Ally's matrix because I checked ds5 emulation and it worked correctly. But I definitely didn't think that maybe there are two problems exist simultaneously (1 and 3 from your message).
Unfortunately I don't have any another handheld, so I can't check it :(

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants