Repository navigation
Improve controller detection before autoboot and reduce module loading overhead - #42
Open
tganet-oliveira wants to merge 1 commit into
Open
tganet-oliveira wants to merge 1 commit into
tganet-oliveira 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.
Summary
Improve external controller detection during startup and remove redundant work during module loading.
Controller detection
Previously, EnvironmentLoader initialized KPAD and immediately checked controller input once before starting the default environment. External controllers may not have samples available at that point, causing a held X button to be missed.
This change:
The polling window is skipped when the selection menu must open because no valid default environment is configured.
An environment path supplied by IOSU continues to bypass the SD configuration and startup button check.
Startup tradeoff
When a default environment is configured and X is not detected, the polling window adds approximately one second before autoboot. This gives external controllers time to provide input samples after initialization.
The controller initialization timing is a suspected cause of the reported issue; hardware testing is still needed to confirm the fix.
Module loading optimizations
These changes reduce repeated work while preserving module execution order.
No performance measurements have been collected, so the actual startup improvement remains unverified.
Validation
git diff --checkpassed.Hardware validation checklist
Related issue
Refs #ISSUE_NUMBER