Recently switched my Pi4 over to the 64 bit Pi OS. I have a 7" Raspberry monitor that is displaying upside down so I have to turn my monitor 180. I tried display_rotate=2 in config.txt but no joy. Then I tried lcd_rotate=2 but still no joy. Then I tried display_rotate=2 AND lcd_rotate=2 in the config.txt During the reboot process I got a very short display that was correct but when it finished the reboot I was right back to being upsidedown. This was not an issue when I was running Raspbian Buster, the previous OS. Any fix or suggestions are greatly appreciated.
In the terminal
sudo nano /boot/config.txt
Then add the line:
lcd_rotate=2
Thats what is seen on the forums
Open the Terminal screen.
Access the config file using sudo nano /boot/config.txt
Enter a new line with the text display_rotate=2 (CASES OF NON-TOUCH DISPLAYS)
Press CONTROL+X then Y then ENTER to Save
Type sudo reboot to reboot and your LCD will be rotated!
To set screen orientation when in console mode, you will need to edit the kernel command line to pass the required orientation to the system.
sudo nano /boot/cmdline.txt
To rotate by 90 degrees clockwise, add the following to the cmdline, making sure everything is on the same line, do not add any carriage returns. Possible rotation values are 0, 90, 180 and 270.
video=DSI-1:[email protected],rotate=90
—— assuming you dont have a built in display and you are using HDMI?
The DSI text should be changed to HDMI
FOR NON TOUCH DISPLAYS
———
Launch the terminal and execute the commandaccording to the rotation you want.
DISPLAY=:0 xrandr --output HDMI-1 --rotate right
DISPLAY=:0 xrandr --output HDMI-1 --rotate left
DISPLAY=:0 xrandr --output HDMI-1 --rotate inverted
To reset rotation back to normal, use the command
DISPLAY=:0 xrandr --output HDMI-1 --rotate normal
Kenora_I said:
Open the Terminal screen.
Access the config file using sudo nano /boot/config.txt
Enter a new line with the text display_rotate=2 (CASES OF NON-TOUCH DISPLAYS)
Press CONTROL+X then Y then ENTER to Save
Type sudo reboot to reboot and your LCD will be rotated!
Click to expand...
Click to collapse
Thanks for the reply. However, I tried this and it did not rotate.
Kenora_I said:
To set screen orientation when in console mode, you will need to edit the kernel command line to pass the required orientation to the system.
sudo nano /boot/cmdline.txt
To rotate by 90 degrees clockwise, add the following to the cmdline, making sure everything is on the same line, do not add any carriage returns. Possible rotation values are 0, 90, 180 and 270.
video=DSI-1:[email protected],rotate=90
—— assuming you dont have a built in display and you are using HDMI?
The DSI text should be changed to HDMI
Click to expand...
Click to collapse
I am not using HDMI. As I mentioned, I'm using the official 7" Raspberry non-touch display.
Related
to increase resolution on webtop
edit xorg.conf file (/osh/etc/X11/xorg.conf)
Code:
Section "Screen"
Identifier "Screen HDMI"
Device "Tegra HDMI"
Monitor "HDMI"
DefaultDepth 24
SubSection "Display"
Depth 24
# Uncomment to override the preferred resolution chosen by UseEDIDModes
Modes "1280x720"
ViewPort 0 0
# Defaults to the size of the chosen mode
Virtual 1366 1024
EndSubsection
EndSection
change line Virtual to eg
Code:
Virtual 1920 1080
and from a terminal execute
Code:
xrandr -s 1920x1080
Does that resolution work with the dock?
Sent from my NINJATRIX
I tested it with multimedia dock and fullHD TV
error
something to the tune of "size not in available modes"
i'm using the hdmi hack, no dock
aaron.a said:
error
something to the tune of "size not in available modes"
i'm using the hdmi hack, no dock
Click to expand...
Click to collapse
Make sure you use a resolution your tv/monitor supports. Technically you should be able to set the res from the little monitor icon on the top of the screen.
For more flexibility you can comment the virtual mode out and write several resolutions in modes like : Modes "1920x1080 1680x1050 1280x800" and so on. Than use the xrandr command for different monitors/tvs
Lapdock?!?
How about the Lapdock? I have a strange problem in lapdock, where when I try to change the default display resolution (on the settings icon inside webtop) it does nothing at all, and my screen stops being full screen (i get black straps on the monitor edges).
Should I change this line to make my screen defaults to lapdock native display resolution of 1366x768?
Code:
# Uncomment to override the preferred resolution chosen by UseEDIDModes
Modes "1366X768"
ViewPort 0 0
And still alter the other line as well for when i plug my phone on my Full HD TV?
Code:
# Defaults to the size of the chosen mode
Virtual 1920 1080
Thanks in advance.
this requires the webtopmod? not able to run xrandr.
this is from a-trix.net site right?
Hi,
If I change the resolution to full HD and if I try the webtop on a HD Ready TV, will it work ?
Thank you.
Ronaldo_9 said:
this is from a-trix.net site right?
Click to expand...
Click to collapse
yes I first publish on that forum
-JFK- said:
Hi,
If I change the resolution to full HD and if I try the webtop on a HD Ready TV, will it work ?
Thank you.
Click to expand...
Click to collapse
You can obtain different configuration changing xorg.conf file
a desktop at fullHD resolution that scroll on HDready resolution
or a desktop at fullHD scaled on another resolution
for reference
http://www.x.org/releases/current/doc/man/man5/xorg.conf.5.xhtml
i got it going. an error on my part. i added an additional line for my resolution instead of adding it inside the quotes
thanks for sharing you're knowledge's =D
can you elaborate please, is this done inside webtop? cause i searched my /osh folder with root explorer and there's no etc folder in it
I get xrandr: not found.
Point me the right way please?
<edit> Would this be a path issue?
^^^^^^^^^^^^^^^^^^
Same
Sent from my MB860 using XDA App
CaelanT said:
I get xrandr: not found.
Point me the right way please?
<edit> Would this be a path issue?
Click to expand...
Click to collapse
The same to me!
And I am needing the webtop for videos.
But...
One thing that I realized, for pictures and musics the resolution its ok, but for videos not. Why?
xrandr appears to be in /usr/bin so that shouldn't be an issue.
Code:
# which xrandr
/usr/bin/xrandr
#
My issue is that when I run xrandr (and this is on a Photon, not an Atrix) is that it comes back with "No display".
John Kotches said:
My issue is that when I run xrandr (and this is on a Photon, not an Atrix) is that it comes back with "No display".
Click to expand...
Click to collapse
Solved this, also set up the adas user to pull up @ 1920x1080 automatically on login by updating .profile.
Regards,
Hello, i have the 1cm dead touchscreen zone in the top and bottom, not good for the android taskbar...
Can we recalibrate the resolution / screen parameter to reduce a little the screen height to fix the problem ??
Thank you.
same problem here .. heeeelp
yeeeeeeeeeeeee .. after month or more looking for solution and tried everything on web i finally found it broo
download from the play store NOmone resolution changer and use it
our default settings is 1024 768 160
u just change the first number i use 880 768 160
as i have 2 cm below of dead touchscreen :S
i hope this works for u
I7V said:
yeeeeeeeeeeeee .. after month or more looking for solution and tried everything on web i finally found it broo
download from the play store NOmone resolution changer and use it
our default settings is 1024 768 160
u just change the first number i use 880 768 160
as i have 2 cm below of dead touchscreen :S
i hope this works for u
Click to expand...
Click to collapse
Than You, i had no success with NOMONE Resolution Changer, impossible to install for me tough Play Store (not allowed in my country) and the multiple apk found on the net was not good, an error 'probleme with parsing installer' something like this.
I found "Resolution Changer Pro" who work very well, the perfect resolution for me is : 970 x 768.
Or even easier, use a simple adb debug shell command:
Code:
adb shell
wm overscan 0,300,0,400
For this to work, you must have adb installed on your pc/mac and usb-debugging activated on your android device.
The above command will shrink the useful screen area with 300px from top and 400px from bottom.
Feel free to experiment those parameters to find the best fit for your situation.
Hi guys! I start to thank you a lot for your suggestions but before making any disaster i should be really grateful if you could give me an help.
I need to resize the screen of my Nexus 7 (2013) in order to fit with the car-dash enclosure where i'm willing to install it.
The enclosure i bought was supposed to fit for the nexus display but regrettably whilst the latter is of abt 15.3cm wide x 9.5 cm "tall" (sorry for my english) the enclosure has a window of 15.3 cm wide but only 8.7 cm tall which would make impossible the access to the softkeys.
In view of the above and considering also that there is no space available to enlarge the window of the enclosure i thought and hoped it would have been easier to resize the screen.
Now the question is: considering that the measures reported are relevant to the device in landscape mode may i kidly ask you the command variables that i have to amend to cut off the 0.8 cm on the bottom side of the screen (again landscape mode).
Thanks a lot in advance for your help!
Hello, Please i need help. I have a Dead Touch Zone (at the bottom 30% aprox.), i installed and i resized screen with ADB (adb shell wm overscan 0,0,0,600) BUT... I can´t use some apps (google play, whatsaap, etc) because it shows like they are behind backgroud.. Check pics attached for understanding.
eric_thefool said:
Hi guys! I start to thank you a lot for your suggestions but before making any disaster i should be really grateful if you could give me an help.
!
Click to expand...
Click to collapse
Did you solve the problem?
davis_llb26 said:
Hello, Please i need help. I have a Dead Touch Zone (at the bottom 30% aprox.), i installed and i resized screen with ADB (adb shell wm overscan 0,0,0,600) BUT... I can´t use some apps (google play, whatsaap, etc) because it shows like they are behind backgroud.. Check pics attached for understanding.
Click to expand...
Click to collapse
Did u get through with this problem..??
i too have the same problem but mine is 25% of the screen so i can use whats app and all other app but the plain box is disturbing me too...
Confirm the adb route works without root!
silvake said:
Or even easier, use a simple adb debug shell command:
Code:
adb shell
wm overscan 0,300,0,400
For this to work, you must have adb installed on your pc/mac and usb-debugging activated on your android device.
The above command will shrink the useful screen area with 300px from top and 400px from bottom.
Feel free to experiment those parameters to find the best fit for your situation.
Click to expand...
Click to collapse
A long time since the original post and answers, but I thought it should be noted that this method works well. Thanks silvake.
My Mecer tablet stopped responding in the top 2-3cm after many years of loyal service. Could have been a drop or simply age. It is still useful and wish to give it to someone in need. So searching around and several different sites yielded some results. Note this is not a mainstream device so rooting was not an option nor attempted. Indeed drivers and any info is sparse for this device.
For anyone attempting this, I will outline my method and steps.
1. Enable USB debugging. There are many tutorials. Settings->About->Build number(tap x 7); Developer Options->USB debugging
2. Connect device with USB Cable. Give permission on device. You will need to make sure that windows installs drivers. At first windows failed to install all drivers. Not sure how it managed, but it connected eventually.
3. Download adb: https://android.izzysoft.de/downloads.php. I used https://android.izzysoft.de/downloads.php?file=adb-binaries-windows-29.0.4.zip. Decompress to desired folder. Open cmd to the folder.
4. Run adb.exe with 'adb devices' and confirm device is listed. First attempt showed:
D:\Downloads\Apps\adb-binaries-windows-29.0.4>adb devices
* daemon not running; starting now at tcp:5037
* daemon started successfully
List of devices attached
0123456789ABCDEF unauthorized
I had to give permission on the device. Reconnected USB.
D:\Downloads\Apps\adb-binaries-windows-29.0.4>adb devices
List of devices attached
0123456789ABCDEF device
Success! Device is now connected.
Next get the current display stats:
Type 'adb shell'
Confirm connection. Mine showed: [email protected]:/ #
Type: ‘dumpsys display | grep mBaseDisplayInfo’
Below is the capture of the operation:
D:\Downloads\Apps\adb-binaries-windows-29.0.4>adb shell
[email protected]:/ # dumpsys display | grep mBaseDisplayInfo
mBaseDisplayInfo=DisplayInfo{"Built-in Screen", app 800 x 1280, real 800 x 1280, largest app 800 x 1280, smallest app 800 x 1280, 55.84 fps, rotation0, density 190 (190.0 x 190.0) dpi, layerStack 0, type BUILT_IN, FLAG_SECURE, FLAG_SUPPORTS_PROTECTED_BUFFERS}
This is not really required but helps to determine the current stats to make a guess on the number of pixels to adjust the screen by.
Next is the command to adjust the screen. The 4 numbers are the coordinates. Since mine was the top area I adjusted only that.
Type: wm overscan 0,50,0,0
The update is live and you should see the screen drop 50 pixels from the top.
This was not enough for me so repeat until the pull down of the status bar starts working again.
Here is the whole list to adjust the screen until everything is working again:
D:\Downloads\Apps\adb-binaries-windows-29.0.4>adb shell
[email protected]:/ # wm overscan 0,50,0,0
[email protected]:/ # wm overscan 0,70,0,0
[email protected]:/ # wm overscan 0,80,0,0
[email protected]:/ # wm overscan 0,100,0,0
[email protected]:/ # wm overscan 0,200,0,0
[email protected]:/ # wm overscan 0,120,0,0
[email protected]:/ # wm overscan 0,140,0,0
[email protected]:/ # wm overscan 0,150,0,0
[email protected]:/ # wm overscan 0,160,0,0
[email protected]:/ # wm overscan 0,170,0,0
[email protected]:/ # wm overscan 0,180,0,0
[email protected]:/ # wm overscan 0,190,0,0
[email protected]:/ # wm overscan 0,195,0,0
[email protected]:/ # exit
So I had to move the screen 195 pixels down until the dead touchscreen area was excluded.
Screen is obviously smaller but the frustration of having to rotate the device 180 to be able to pull down the status bar is removed. Much worth it.
Now a child in need of education can still learn and we have saved the device from landfill and reduced the carbon footprint.
You might have to adjust the pixel density to compensate for the loss, but I left it untouched. Your results will vary so I cannot assist.
Excerpt from another site:
"Additionally decreasing the density through the settings (Display & lights > screen > LCD density) or the wm command helped compensating for the lost display area:
wm density 360"
Hope this helps someone as it helped me.
T
Hello amazing people,
I am looking for your guide/advice for solving a screen resolution issue.
I am using a 4:3 ratio screen with a LCD driver on Radxa Zero.
the poblem is that the screen looks stretched laterally. I think its due to aspect ratio becuase the lcd is of 4:3 aspect ratio.
can anyone help me how can I change the aspect ratio using adb?
I have worked with size and density but failed to produce any results.
Many thanks to this amazing community.
the side of may cellphone is not working
I just picked up a VIVO XL3 running Marchmallow. It's a bit of a mess with bugs but here are a couple things you might find useful. Connect to the phone using ADB and USB Debugging from a PC. (Nothing special -- see other guides on how to do this.)
One Note: this phone is pretty insecure -- it seems to have no incorrect fingerprint limit (Where it will require a password/PIN.) I recommend you go into Settings -> Security and enable Require password at boot. Otherwise, even on reboot, you do not need a password ever -- the fingerprint will unlock it right away.
Anyway, onto the guide. Use ADB and open up a shell to the phone: (adb shell)
------
To see a list of apps that can run in the background run:
appops query-op RUN_IN_BACKGROUND allow
To set a particular app to not run in the background: (replace package-name below with a package from the list above.)
appops set package-name RUN_IN_BACKGROUND ignore
Example:
appops set net.slickdeals.android RUN_IN_BACKGROUND ignore
------
To hide (Debloat an app)
Unfortunately, this doesn't work on this phone. This won't be possible without root.
Trying to hide an app with "pm hide" command will give you this error:
Error: java.lang.SecurityException: Neither user 2000 nor current process has android.permission.MANAGE_USERS.
------
Since there is no way to change the screen DPI in the settings app, you can do it in ADB. The stock density setting is 360 and that makes everything way too big for my taste. The smaller the number, the smaller things get on the screen. I find 280 is a good setting and you can fit a lot more on the screen while my old eyes can still read it. I also set the font size to smallest in the settings app.
wm density 280
I did notice if I got too low system_ui crashes. Before you reboot the phone you MUST reset the DPI otherwise the phone may not boot back up again!! System_ui can crash and you'll still be on on the ADB connection:
wm density reset
Reboot after making changes.... although feel free to poke around to make sure you like the setting.
Thank you for posting this. The DPI setting helps tremendously because holy cow...
I'm curious if anyone knows where to get TWRP recovery image. I wish I could install Magisk on it.
Blu Vivo XL3+ change dpi in develpers options w/ no mod
adrianblack said:
I just picked up a VIVO XL3 running Marchmallow. It's a bit of a mess with bugs but here are a couple things you might find useful. Connect to the phone using ADB and USB Debugging from a PC. (Nothing special -- see other guides on how to do this.)
One Note: this phone is pretty insecure -- it seems to have no incorrect fingerprint limit (Where it will require a password/PIN.) I recommend you go into Settings -> Security and enable Require password at boot. Otherwise, even on reboot, you do not need a password ever -- the fingerprint will unlock it right away.
Anyway, onto the guide. Use ADB and open up a shell to the phone: (adb shell)
------
To see a list of apps that can run in the background run:
appops query-op RUN_IN_BACKGROUND allow
To set a particular app to not run in the background: (replace package-name below with a package from the list above.)
appops set package-name RUN_IN_BACKGROUND ignore
Example:
appops set net.slickdeals.android RUN_IN_BACKGROUND ignore
------
To hide (Debloat an app)
Unfortunately, this doesn't work on this phone. This won't be possible without root.
Trying to hide an app with "pm hide" command will give you this error:
Error: java.lang.SecurityException: Neither user 2000 nor current process has android.permission.MANAGE_USERS.
------
Since there is no way to change the screen DPI in the settings app, you can do it in ADB. The stock density setting is 360 and that makes everything way too big for my taste. The smaller the number, the smaller things get on the screen. I find 280 is a good setting and you can fit a lot more on the screen while my old eyes can still read it. I also set the font size to smallest in the settings app.
wm density 280
I did notice if I got too low system_ui crashes. Before you reboot the phone you MUST reset the DPI otherwise the phone may not boot back up again!! System_ui can crash and you'll still be on on the ADB connection:
wm density reset
Reboot after making changes.... although feel free to poke around to make sure you like the setting.
Click to expand...
Click to collapse
If you do into deveoplers option there one called "smallest width" in "drawing" section just under "networking" where you set USB to MTP.PTP or charging. Default setting was 360. Ive tryed 360, 420, 480, 720. All work well - Display adapts in seconds w/o reboot. When you go from 720 back down to 480 it asks you to reboot. No need to worry anymore if you an MOD or if your gonna soft brick. Personnally I like 480 with font size et to small (720 is great for watching vids and probably gaming - but leaves everything to small for day to day use, unless you have miget baby finger)
PScript - Im useing Microsoft Launcher instead of stock Launcher (See Screen Shots)
I own a Oneplus 3T, on which the bottom 1cm of the screen does not register any touch. I've concluded the problem to be with the digitizer, but am not in a state to replace the display. So, I was wondering if I could shift the bottom border about 100px upwards. I tried the
Code:
adb shell wm overscan 0,0,0,100
method, but that seems to break a lot of apps. The margin seems to vary for different apps. I also tried the
Code:
adb shell wm size 1080x1820
(original resolution being 1080x1920 pixels), and the apps had no problem adapting to the new resolution. But the resolution-resize resulted in the extra 100px being distributed on top and bottom equally as 50px. Now all that's remaining is to shift the display-area 50px upwards on the y-axis. Is there a command to do that? If not, are there any other alternatives for me to achieve the same result? Please help!
As an additional request, where can I get a list of all available ADB commands?
PS: I've already tried to enable the on-screen navigation buttons and use it to offset the display, but my Oxygen OS 5.0.3 does not allow both hardware and on-screen buttons to be active at the same time.
On Android head units, the orientation typically defaults to landscape. And has disabled auto-rotation, the screen will always remain in a landscape mode. This effectively means you can't use any software on Google Play Store or other places to change this default because auto-rotation is disabled (they at best, can reverse the screen but cannot rotate it). I need to change this feature to portrait for the custom firmware I placed on my head unit (which is using Android 10).
In my attempts to work out how to do this, I have gathered some information, but I have not got enough experience or knowledge to know how to do this. I really need some with experience who likes these challenges.
I believe in order to do this correctly, this needs to be done at root, and place in one of these locations in Magisk
(1) /data/adb/post-fs-data.d (think it needs to be here)
or
(2) /data/adb/service.d/
and the command syntax would look it something like this (3)
adb shell settings put system accelerometer_rotation 0 # auto-rotation, 0 disable, 1 enable
adb shell settings put system user_rotation 0 # actual-rotation, clockwise, options 0[0°], 1[90°],2[180°],3[270°]
source:- https://stackoverflow.com/questions/25864385/changing-android-device-orientation-with-adb
or (4)
content insert --uri content://settings/system --bind name:s:accelerometer_rotation --bind value:i:0
content insert --uri content://settings/system --bind name:s:user_rotation --bind value:i:0
or (5)
import android.provider.Settings;
// You can get ContentResolver from the Context
Settings.System.putInt(getContentResolver(), Settings.System.ACCELEROMETER_ROTATION, 0);
Settings.System.putInt(getContentResolver(), Settings.System.USER_ROTATION, 0);
or something else (Other source documents)
How to change Android default-natural orientation?
I have my device running android Jellybean 4.2.2 with Landscape as the default/natural orientation. How can I change the default/natural orientation of the same to portrait? Here is what I have t...
android.stackexchange.com
Disable Screen Rotation Landscape Mode in Android React Native
Disable Screen Rotation Landscape Mode in Android React Native. This tutorial explains how to disable screen rotation landscape mode in android react native application. There are two different types of orientation in android device, Portrait mode and Landscape mode. Portrait mode is default...
www.skptricks.com
Set Android default orientation to portrait mode - Boundary Devices
The default screen orientation for the Android-ready Nitrogen and Nitrogen53 is landscape. That’s fine for most people, but say you want it in portrait. Or upside down, or whatever. That’s a problem, since Android usually takes rotation instructions from code that expects motion sensor input...
boundarydevices.com
or (6)
There is an existing module I should be using ?
Thank you for any time you invest on this.
I have also been wondering if Magisk can do this, would be of value to have the ability to inject landscape or portrait as default, and the ability to turn on/off auto rotate would make this more appealing/useful code for developers and fix my issue?
Anyway, just an idea without the skill/knowledge to make it happen.