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

Doubled key inputs in LineageOS Recovery #117

Open
argonym opened this issue Feb 22, 2025 · 6 comments
Open

Doubled key inputs in LineageOS Recovery #117

argonym opened this issue Feb 22, 2025 · 6 comments
Assignees
Labels

Comments

@argonym
Copy link

argonym commented Feb 22, 2025

What happened?

In the (manual) setup, a single press on the volume up (+) or down (-) key always is like two presses: The current choice and the next choice receive the same key input. So that I can effectively only make every other choice.
(It just does not happen after the very first (+) that enables the manual setup but only when this is a new installation - so that I can make the first "install ... yes/no" choice. But then not the second one, and so on.)

This happens in LineageOS 22.1 Recovery on two Google Pixels 3.

Maybe it will help to clear the key input buffer right before reading from it (or similar).

I'd be glad to try out any changes that might fix this issue. :) Thanks a lot.

Version

1.3.1.77-alpha-76501f9

Android version

15

Custom ROM

LineageOS 22.1 on Pixel3 (blueline) with LineageOS recovery

Relevant log output


@argonym argonym added bug needs triage Pending review to ensure they are relevant, actionable and contain all necessary information labels Feb 22, 2025
@ale5000-git
Copy link
Member

Please flash the same zip again using this procedure:

  • First enable the debug log with:
    adb shell "setprop zip.common.DEBUG_LOG 1"

  • Then flash the zip (during the flash you will find a Creating log message with the path of the log).

  • At the end please take the debug-a5k.log and post it here.

@ale5000-git ale5000-git removed the needs triage Pending review to ensure they are relevant, actionable and contain all necessary information label Feb 23, 2025
@argonym
Copy link
Author

argonym commented Feb 25, 2025

Thank you for the instructions.

After enabling the DEBUG_LOG there is the message that the log will get written to /sdcard/debug-a5k.log, but after rebooting to Android I could not find this file. Is this expected? (There also is a message that the data partition could not be mounted. And, on a side note, the MicroG etc. installation does not survive an LineageOS OTA update.)

Anyway, I realized that after enabling the ADB Shell in LineageOS recovery, I could use adb pull sdcard/debug-a5k.log <dest> to download the file. So here it is: debug-a5k-76501f9.log (v1.3.1.77-alpha-76501f9-full 76501f9)
Notice I answered all questions I could with VolDown/- (besides the first VolUp/+ for enabling the live setup). I.e. e.g. I did not have a chance to choose "Uninstall" (because "Reinstall" is already chosen by the VolUp/+ press for enabling live setup).
(And there is a little peculiarity that if this was a first installation, the first choice (install PlayStore iirc) can actually be made.)

I also tried the latest build I could find: v1.3.1.80-alpha-b4ea4cc-oss-DEBUG (b4ea4cc) from #118 (comment) :

No changes concerning the /data mount issue.
But I noticed that "Using: keycheck" changed to "Using: input event"

With this build the doubled key inputs issue is gone. I.e. every choice can be answered.

However, in this "input event" mode only the VolUp/+ key (115) is recognized.
Pressing VolDown/- does not have not any result.
So here is the log with just VolUp/+ keys pressed: debug-a5k-b4ea4cc.log (v1.3.1.80-alpha-b4ea4cc-oss-DEBUG b4ea4cc)

HTH

@ale5000-git
Copy link
Member

"Keycheck" can't be fixed, but I have excluded it on your device.
"Input event" is just an unbuffered read of the input event, it is strange that it behave like this on some devices.
I haven't figured out the cause yet, but I'm thinking about it.

Other problems will be fixed later.

@ale5000-git
Copy link
Member

@argonym

Could you please flash this zip using this procedure?
https://share.freepro.com/ffc22ee2-bfc1-4f86-915b-9f956e9e42fa

  • First enable the debug log with:
    adb shell "setprop zip.common.DEBUG_LOG 1"

  • Then flash the zip (during the flash you will find a Creating log message with the path of the log).

  • At the end please take the debug-a5k.log and post it here.

@argonym
Copy link
Author

argonym commented Feb 28, 2025

@ale5000-git
Here it is: debug-a5k-8b2da84.log
At the first question "What do you want to do?" I pressed VolDown/-, but this key press does not even appear in the debug log.

@ale5000-git
Copy link
Member

@argonym
The code seems to be working correctly but still it get the wrong data.

Could you please flash this zip using this procedure? https://github.com/micro5k/microg-unofficial-installer/releases/tag/nightly

  • Enable the debug log with:
    adb shell "setprop zip.common.DEBUG_LOG 1"

  • Enable key test mode with:
    adb shell "setprop zip.microg-unofficial-installer.KEY_TEST_ONLY 1"

  • Then flash the zip.
    Never ever press the volume +, only press volume - and all other physical keys that you may have on your phone like menu, power, etc.
    It will end after 10 key presses.

  • At the end please take the debug-a5k.log and post it here.

NOTE: This procedure will NOT change anything on the device so it is relatively safe.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants