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

🐛 [BUG] - The system uses 60hz instead of using the highest refresh rate the monitor provides (mine is 100hz) #106

Open
AchIrsHam opened this issue Nov 6, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@AchIrsHam
Copy link

Description

Yes, i don't know if something necessary like this has to be reported to GitHub, but this is very annoying for me and I can't find a solution to my personal problem

Reproduction steps

1. Install a new fresh copy of BlissOS
2. Activate developer mode
3. Turn on 'Show refresh rate' options

Screenshots

I don't know how to take a screenshot by default in Bliss, the important thing is that a red number appears on the screen and says '60' (I know this is trivial, but I just followed the instructions)

Logs

why?

Category

Display

OS Version

16.x

@AchIrsHam AchIrsHam added the bug Something isn't working label Nov 6, 2024
@AchIrsHam
Copy link
Author

I just want to enjoy BlissOS with a high refresh rate

@Xtr126
Copy link

Xtr126 commented Nov 8, 2024

I'll just share my findings here.

The issue is that the default mode your monitor advertises to the OS (Bliss in this case) is the one with lower refresh rate.
Then hwcomposer picks it first and stuck with it.
It’s possible to tell drm_minigbm_celadon hwcomposer to use a specific mode by using kernel parameters, but this requires figuring out mode id and connector id which you can do only if you are familiar with linux terminal and kernel (graphics) drm subsystem in sysfs/dev.

For celadon hwc you can “select monitor” with these experimental flags, MODE_ID and CONNECTOR_ID https://github.com/BlissRoms-x86/device_generic_common/blob/6017b7d8071e148623efca41531fc1c5ff2a6092/init.sh#L498
This is how I got it to work long ago
Run this command cat /sys/class/drm/renderD128/device/drm/card0/card0-HDMI-A-1/modes
And get an output:

1920x1080
1920x1080
1920x1080i
1920x1080i
1920x1080i
1920x1080
1920x1080i
1920x1080i
1920x1080
1920x1080
1920x1080
1920x1080
1920x1080
1366x768
1280x720
1280x720
1280x720
1280x720
1024x768
1024x768
1024x768

If you want the second resolution, 1920x1080
then MODE_ID=2
Then obtain CONNECTOR_ID from logcat | grep hwc (as soon as android boots before logs are erased)
in my case it was CONNECTOR_ID=64

On one of my devices MULTI_REFRESH_RATE=1 was sufficient to let me switch between different refresh rates from Android settings > display.

Switching to gbm_gralloc might work as an alternative if you cannot find modes/connector, however it may cause other issues.

GRALLOC=gbm HWC=drm_gbm_cros drm_mode=1920x1080@100   video=1920x1080@100

TL;DR: You have find out the mode id and connector id for 100hz and supply them in kernel cmdline with MODE_ID= and CONNECTOR_ID= and use HWC=drm_minigbm_celadon GRALLOC=minigbm.

Another solution is to use edid_override feature of Linux kernel, it must be triggered before Android starts to use the GPU.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants