Push adbkey to device.

When flashing mobile devices with custom ROMs, I have often experienced that the initial screen resolution when booting the new image the first time is terrible wrong. When this happens I usually change the screen resolution with the following commands (this is for my Xiaomi Mi Note Pro, find your setting on www.gsmarena.com or another phone site)

adb shell wm size 1440×2560
adb shell wm density 560

This will fix the resolution, but i still have bad resolution in the boot process, I haven’t figured out how to change that yet. If you know please leave a comment.

Sometimes the resolution is so bad that i cant even push the accept button on the USB debug prompt, this means that I cannot use adb to change the screen resolution. If this happens you have to reboot into the recovery (I prefer TWRP) and copy your adbkey.pub to theĀ /data/misc/adb/adb_keys file. You can do it like this:

adb push adbkey.pub /data/misc/adb/adb_keys

Reboot your device and you are now able to use adb to change the screen resolution.

Leave a Reply

Your email address will not be published. Required fields are marked *

Are you human? * Time limit is exhausted. Please reload CAPTCHA.

This site uses Akismet to reduce spam. Learn how your comment data is processed.