Repository navigation
feat: experimental gyro aiming on the on-screen keyboard - #204
Merged
Merged
Conversation
nextestudios
force-pushed
the
feature/77-gyro-keyboard
branch
from
September 27, 2026 22:27
8fe785f to
ea8f928
Compare
Co-Authored-By: Claude Opus 5.5 <[email protected]>
nextestudios
force-pushed
the
feature/77-gyro-keyboard
branch
from
September 27, 2026 22:30
ea8f928 to
2f7be2c
Compare
4 tasks
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.
Summary
Experiment #77: gyro aiming on the on-screen keyboard, as a prototype behind a setting that is off by default, with findings in
docs/decisions/0007.SDL_GamepadHasSensor/SDL_SetGamepadSensorEnabled(SDL_SENSOR_GYRO)andSDL_EVENT_GAMEPAD_SENSOR_UPDATE(sensor timestamp when available). The sensor is only turned on while Configurações → Controles → Mira por giroscópio no teclado is on, and also for controllers connected later.GyroPointer: continuous calibration (bias learned while still), soft deadzone (2.5°/s), exponential smoothing, sensitivity (1 key per 4°), gap clamp (50 ms), so Bluetooth bursts don't turn into jumps.AppController.AimKeyboard): starts at the center of the focused key and moves in fractions of a key; crossing into another key focuses it, and South types as usual. It stops at the edges (no wrap). The D-pad still works and re-anchors the pointer. R3 recenters, and the footer shows "Recentralizar mira" only when the active controller has an enabled gyro. Only the active controller aims, only on the keyboard, and never in the background. Nothing depends on the gyro.0007explains this and gives next steps (a dedicated hold on L3, or aim-after-flick) if hardware shows accidental movement. The tuning values live inGyroSettings, not in the UI yet.Tests (CI)
GyroPointerTests(2): drift learned while still and tremor ignored; direction, proportional movement and gap clamp.GyroKeyboardJourneyTests: off by default; points at keys within/over key boundaries; no wrap at edges; D-pad re-anchors; R3 recenters without switching view; South types the aimed key.Manual (not hardware validated)
Added to
docs/TESTING.mdunder "Mira por giroscópio no teclado (#77)": DualSense over USB and Bluetooth, resting drift over 1 min, tremor while typing with the D-pad, timing D-pad vs gyro, and Xbox (no gyro). The measurement results go intodocs/decisions/0007.Closes #77
🤖 Generated with Claude Code