How can I rotate my touchscreen display 180 so that I can stand it up with the power coming out of the top, rather than the bottom as it does now? Thanks (I'm a total novice with Linux so please be gentle)
3 Answers
Assuming you have one of these (different size is fine too), they are compatible with/same as the waveshare products available here.
Using LCD-show drivers and scripts
I have posted the setup details here. As part of the driver bundle there are number of scripts and the instructions to configure the orientations are also available on that site.
Here's an extract
Toggle between LCD and HDMI display Once this LCD is enabled, meanwhile the default settings for HDMI are changed. If you want to use another HDMI monitor, please run the following command:
cd LCD-show/ ./LCD-hdmi
This toggles the mode to LCD display:
./LCD35-showScreen orientation settings
After touch driver installed, the screen orientation can be set by these commands:
0 degree rotation
cd LCD-show/ ./LCD35-show 090 degree rotation
cd LCD-show/ ./LCD35-show 90180 degree rotation
cd LCD-show/ ./LCD35-show 180270 degree rotation
cd LCD-show/ ./LCD35-show 270
Alternative solution
If the LCD-show script doesn't work for your configuration you can also try and edit the boot configuration manually. That is what these scripts do anyway:
sudo nano /boot/config.txt
Look for a line dtoverlay=waveshare35a or any other display identifier after dtoverlay=. To that line you can append ,rotate= like so:
dtoverlay=waveshare35a,rotate=90
Next exit nano and save changes with ctrl+x followed by Y and ENTER. This requires a reboot to take effect:
sudo reboot
Note that if you're using a touchscreen you'll also have to swap the touch X and Y axis. For more information check this display configuration overview.
- 103
- 4
- 2,446
- 1
- 16
- 23
Try adding display_rotate=2 to /boot/config.txt. Reboot required.
Source: https://www.raspberrypi.org/documentation/configuration/config-txt.md
You may also want to try adding lcd_rotate=2 instead of display_rotate=2.
Source: https://www.raspberrypi.org/documentation/hardware/display/troubleshooting.md
- 670
- 5
- 10
The Switch between HDMI and the touch Display is done by rewriting all of the config files and Drivers. Try editing the corresponding files behind the LCD35show first.
- 1
