Author Topic: [Raspberry pi] 3.5 inch display - rotation does not work  (Read 533 times)

0 Members and 1 Guest are viewing this topic.

Offline bodzio_stawskiTopic starter

  • Regular Contributor
  • *
  • Posts: 53
  • Country: lt
[Raspberry pi] 3.5 inch display - rotation does not work
« on: May 05, 2024, 11:03:29 am »
Hello!

This week I started learning about Raspberry PI 4B and a 3.5 inch MHS display - the same model as described here:

http://www.lcdwiki.com/MHS-3.5inch_RPi_Display

So the drivers come from github from goodtft, updated basically on a regular basis:

https://github.com/goodtft/LCD-show

First of all, I installed Raspberry PI OS. Unfortunately, I realized I didn't have a MicroHDMI cable, so I had to settle for VNC to start with. Thanks to this, I managed to connect remotely to Raspberry before I could even install the LCD driver.

Unfortunately, due to my ignorance, I started installing the driver for the Waveshare 3.5 inch display instead of MHS, then I simply formatted the SD card with Raspberry OS and installed everything again. Then I started working on the LCD driver for the MHS display according to the guide from the link a few lines above. And it installed.

Now I control it via VNC and everything can be seen on the LCD, or control it on the LCD itself (touch screen function works). However, it turns out that the screen rotation option is somehow disabled permanently and changing the parameters related to it does not affect it.




According to some information from the Internet, it should be possible to set it this way:


a) Using the following commands - nothing changed for me:

Code: [Select]
cd LCD-show/
sudo ./rotate.sh 90
b) By reinstalling and setting the rotation at the very beginning - nothing changed

Code: [Select]
sudo rm -rf LCD-show
git clone [url]https://github.com/goodtft/LCD-show.git[/url]
chmod -R 755 LCD-show
cd LCD-show/
sudo ./MHS35-show

c) By getting into the config.txt file and trying to change this value "90"; this didn't change anything, so I also tried changing the name mhs to tft35a, and then mhs35 to piscreen,drm (To make sure that the manufacturer did not deceive me with the print on the silkscreen):

Code: [Select]
dtoverlay=mhs35:rotate=90
 
Code: [Select]
# For more options and information see
# http://rpf.io/configtxt
# Some settings may impact device functionality. See lin>

# uncomment if you get no picture on HDMI for a default >
#hdmi_safe=1

uncomment the following to adjust overscan. Use positi>
# goes off screen, and negative if there is too much bor>
#overscan_left=16
#overscan_right=16
#overscan_top=16
#overscan_bottom=16

uncomment to force a console size. By default it will >
# overscan.
#framebuffer_width=1280
#framebuffer_height=720

uncomment if hdmi display is not detected and composit>
#hdmi_force_hotplug=1

# uncomment to force a specific HDMI mode (this will for>
#hdmi_group=1
#hdmi_mode=1

 uncomment to force a HDMI mode rather than DVI. This c>
# DMT (computer monitor) modes
#hdmi_drive=2

# uncomment to increase signal to HDMI, if you have inte>
# no display
#config_hdmi_boost=4

# uncomment for composite PAL
#sdtv_mode=2

uncomment to overclock the arm. 700 MHz is the default.
#arm_freq=800

# Uncomment some or all of these to enable the optional >
#dtparam=i2c_arm=on
#dtparam=i2s=on
#dtparam=spi=on

Uncomment this to enable infrared communication.
#dtoverlay=gpio-ir,gpio_pin=17
#dtoverlay=gpio-ir-tx,gpio_pin=18

# Additional overlays and parameters are documented /boo>

Enable audio (loads snd_bcm2835)
dtparam=audio=on

# Automatically load overlays for detected cameras
camera_auto_detect=1

Automatically load overlays for detected DSI displ>
display_auto_detect=1

# Enable DRM VC4 V3D driver
#dtoverlay=vc4-kms-v3d
max_framebuffers=2

Run in 64-bit mode
arm_64bit=1

# Disable compensation for displays with overscan
disable_overscan=1

[cm4]
# Enable host mode on the 2711 built-in XHCI USB con>
# This line should be removed if the legacy DWC2 con>
# (e.g. for USB device mode) or if USB support is no>
otg_mode=1

[all]

[pi4]
# Run as fast as firmware / board allows
arm_boost=1

[all]
hdmi_force_hotplug=1
dtparam=i2c_arm=on
dtparam=spi=on
enable_uart=1
dtoverlay=mhs35:rotate=90
hdmi_group=2
hdmi_mode=1
hdmi_mode=87
hdmi_cvt 480 320 60 6 0 0 0
hdmi_drive=2
For now, the screen still doesn't rotate. Thanks to this, I always have the screen with the power cable facing down, which makes it difficult to place it normally. I checked this error by installing Raspberry Pi OS 64-bit and then 32-bit (both via Raspberry Pi Imager v1.8.5, released 2024-03-15)

Is it possible that something has been messed with in the RPI settings since these reinstallations, that the screen rotation option is blocked, or am I just doing something else very wrong? I will be grateful for your help.

Regards

Bogdan
 

Offline Nominal Animal

  • Super Contributor
  • ***
  • Posts: 6440
  • Country: fi
    • My home page and email address
Re: [Raspberry pi] 3.5 inch display - rotation does not work
« Reply #1 on: May 05, 2024, 11:38:19 am »
Perhaps it simply defaults to 90 degree rotation, as many of these small screens are actually portrait orientation by default?

That is, have you tried e.g.
    sudo ./rotate.sh 0
or
    sudo ./rotate.sh 180
?

Also, you do realize you need to reboot the Pi for the new rotation to take effect; it is not immediate?
 

Offline bodzio_stawskiTopic starter

  • Regular Contributor
  • *
  • Posts: 53
  • Country: lt
Re: [Raspberry pi] 3.5 inch display - rotation does not work
« Reply #2 on: May 05, 2024, 12:28:02 pm »
Hi, thank you for your reply!

Yes, I am aware of the need to restart the raspberry after such operations. For me, after performing the operation from the Terminal available in Raspberry OS, the situation is as follows:

1) command:
Code: [Select]
sudo ./rotate.sh 0
(followed by:
Code: [Select]
sudo reboot)

will cause the following line
Code: [Select]
dtoverlay=mhs35:rotate=90 to remain in the config.txt file (so nothing will change)

2) command:

Code: [Select]
sudo ./rotate.sh 180
provides the return text as follows:

LCD rotate value is set to 180
reboot now


However, this time the system resets itself. After restarting, the following entry appears in the config.txt file:

Code: [Select]
dtoverlay=mhs35:rotate=270
So you can see that the value in config.txt is somehow shifted forward by 90.


3) Entering
 
Code: [Select]
sudo ./rotate.sh 0 will once again cause the system to reset itself and the value in config.txt will return to 90.

The visual orientation of the image on the screen is still the same after each of these steps (i.e. with the power port facing down).
« Last Edit: May 05, 2024, 12:30:00 pm by bodzio_stawski »
 

Offline Nominal Animal

  • Super Contributor
  • ***
  • Posts: 6440
  • Country: fi
    • My home page and email address
Re: [Raspberry pi] 3.5 inch display - rotation does not work
« Reply #3 on: May 05, 2024, 01:34:22 pm »
The MHS35-Show script you use, can install xserver-xorg-input-evdev from http://mirrors.zju.edu.cn/raspbian/raspbian, which makes myself a bit, uh, suspicious... but really, it is just horribly shoddy work; bad enough to make my eyes bleed.

Anyway, it seems to using the "standard" fbtft driver, just configuring it differently for specific displays.  As you do get a display, the driver is already installed, it's just its configuration that needs fixing.  For MHS35, the base device tree overlay (mhs35-overlay.dtb) you should see in your /boot/overlays/mhs35.dtb0, contains
Code: [Select]
/dts-v1/;

/ {
compatible = "brcm,bcm2835\0brcm,bcm2708\0brcm,bcm2709";

fragment@0 {
target = <0xdeadbeef>;

__overlay__ {
status = "okay";

spidev@0 {
status = "disabled";
};

spidev@1 {
status = "disabled";
};
};
};

fragment@1 {
target = <0xdeadbeef>;

__overlay__ {

tft35a_pins {
brcm,pins = <0x11 0x19 0x18>;
brcm,function = <0x00 0x00 0x00>;
linux,phandle = <0x01>;
phandle = <0x01>;
};
};
};

fragment@2 {
target = <0xdeadbeef>;

__overlay__ {
#address-cells = <0x01>;
#size-cells = <0x00>;

tft35a@0 {
compatible = "ilitek,ili9486";
reg = <0x00>;
pinctrl-names = "default";
pinctrl-0 = <0x01>;
spi-max-frequency = <0x6dac2c0>;
txbuflen = <0x8000>;
rotate = <0x5a>;
bgr = <0x00>;
fps = <0x1e>;
buswidth = <0x08>;
regwidth = <0x10>;
reset-gpios = <0xdeadbeef 0x19 0x01>;
dc-gpios = <0xdeadbeef 0x18 0x00>;
debug = <0x00>;
init = <0x10000f1 0x36 0x04 0x00 0x3c 0x0f 0x8f 0x10000f2 0x18 0xa3 0x12 0x02 0xb2 0x12 0xff 0x10 0x00 0x10000f8 0x21 0x04 0x10000f9 0x00 0x08 0x1000036 0x08 0x10000b4 0x00 0x10000c1 0x41 0x10000c5 0x00 0x91 0x80 0x00 0x10000e0 0x0f 0x1f 0x1c 0x0c 0x0f 0x08 0x48 0x98 0x37 0x0a 0x13 0x04 0x11 0x0d 0x00 0x10000e1 0x0f 0x32 0x2e 0x0b 0x0d 0x05 0x47 0x75 0x37 0x06 0x10 0x03 0x24 0x20 0x00 0x100003a 0x55 0x1000011 0x1000036 0x28 0x20000ff 0x1000029>;
linux,phandle = <0x02>;
phandle = <0x02>;
};

tft35a-ts@1 {
compatible = "ti,ads7846";
reg = <0x01>;
spi-max-frequency = <0x1e8480>;
interrupts = <0x11 0x02>;
interrupt-parent = <0xdeadbeef>;
pendown-gpio = <0xdeadbeef 0x11 0x01>;
ti,x-plate-ohms = [00 3c];
ti,pressure-max = [00 ff];
linux,phandle = <0x03>;
phandle = <0x03>;
};
};
};

__overrides__ {
speed = <0x02 0x7370692d 0x6d61782d 0x66726571 0x75656e63 0x793a3000>;
txbuflen = [00 00 00 02 74 78 62 75 66 6c 65 6e 3a 30 00];
rotate = [00 00 00 02 72 6f 74 61 74 65 3a 30 00];
fps = [00 00 00 02 66 70 73 3a 30 00];
bgr = [00 00 00 02 62 67 72 3a 30 00];
debug = <0x02 0x64656275 0x673a3000>;
swapxy = <0x03 0x74692c73 0x7761702d 0x78793f00>;
};

__symbols__ {
tft35a_pins = "/fragment@1/__overlay__/tft35a_pins";
tft35a = "/fragment@2/__overlay__/tft35a@0";
tft35a_ts = "/fragment@2/__overlay__/tft35a-ts@1";
};

__fixups__ {
spi0 = "/fragment@0:target:0\0/fragment@2:target:0";
gpio = "/fragment@1:target:0\0/fragment@2/__overlay__/tft35a@0:reset-gpios:0\0/fragment@2/__overlay__/tft35a@0:dc-gpios:0\0/fragment@2/__overlay__/tft35a-ts@1:interrupt-parent:0\0/fragment@2/__overlay__/tft35a-ts@1:pendown-gpio:0";
};

__local_fixups__ {
fixup = "/fragment@2/__overlay__/tft35a@0:pinctrl-0:0\0/__overrides__:speed:0\0/__overrides__:txbuflen:0\0/__overrides__:rotate:0\0/__overrides__:fps:0\0/__overrides__:bgr:0\0/__overrides__:debug:0\0/__overrides__:swapxy:0";
};
};
which basically describes the display (and touch screen) configuration.
See the line rotate = <0x5A>;? <0x5A> = <90>, so it definitely defaults to 90 degrees of rotation.

(Note that if you install device-tree-compiler package, you can convert .dtb and .dtbo files to sources using
    dtc -I dtb -O dts filename source-filename
 and sources to device tree blobs or overlays using
    dtc -I dts -O dtb source-filename filename
but as your display is a standard ILI9486 one using SPI and configured via device tree, you don't need to.)

The MHS35-Show script also adds the following lines to your /boot/config.txt:
Code: [Select]
hdmi_force_hotplug=1
dtparam=i2c_arm=on
dtparam=spi=on
enable_uart=1
dtoverlay=mhs35:rotate=90
hdmi_group=2
hdmi_mode=1
hdmi_mode=87
hdmi_cvt 480 320 60 6 0 0 0
hdmi_drive=2
where you should take note of the dtoverlay=mhs35:rotate=90 line.

If you have run MHS50-Show script more than once after installing Raspbian, you will have multiple copies of the above settings in /boot/config.txt.  Use your favourite editor, for example nano, to edit it and remove the extra copies:
    sudo nano /boot/config.txt
In nano, Ctrl+K deletes the current line, Ctrl+O saves the file, and Ctrl+X exits (as shown at the bottom of the editor window, with ^ being the Linuxy/Unixy abbreviation for the Control key).

After you have done that, you should only need to run one of
    sudo sed -i -e 's|^\(dtoverlay=mhs35:rotate\)=.*$|\1=0|g' /boot/config.txt
    sudo sed -i -e 's|^\(dtoverlay=mhs35:rotate\)=.*$|\1=90|g' /boot/config.txt
    sudo sed -i -e 's|^\(dtoverlay=mhs35:rotate\)=.*$|\1=180|g' /boot/config.txt
    sudo sed -i -e 's|^\(dtoverlay=mhs35:rotate\)=.*$|\1=270|g' /boot/config.txt
and reboot, to change the rotation of your display.  (The above only changes degrees on the dtoverlay=mhs35:rotate=degrees line, which you can do equally well using e.g. sudo nano /boot/config.txt if you prefer.  Just remember to reboot afterwards for the change to take effect.)
« Last Edit: May 05, 2024, 01:36:04 pm by Nominal Animal »
 

Offline bodzio_stawskiTopic starter

  • Regular Contributor
  • *
  • Posts: 53
  • Country: lt
Re: [Raspberry pi] 3.5 inch display - rotation does not work
« Reply #4 on: May 05, 2024, 03:10:11 pm »
I'm not sure I understand everything correctly.

I have not experienced any duplication of any lines in the config.txt file. When I try to make changes both via the command line and directly in the config.txt file, I still have 93 lines of text in the config.txt file, just like in my first post, where I also inserted the content of the config file.

The problem is that all the changes in the config.txt file that are saved successfully are ignored by the raspberry itself and do not change the screen orientation. It's as if the kernel completely ignored what changes in the config file.
« Last Edit: May 05, 2024, 03:20:57 pm by bodzio_stawski »
 

Offline Nominal Animal

  • Super Contributor
  • ***
  • Posts: 6440
  • Country: fi
    • My home page and email address
Re: [Raspberry pi] 3.5 inch display - rotation does not work
« Reply #5 on: May 05, 2024, 05:26:51 pm »
You could install dtc,
    sudo apt install device-tree-compiler
and then run
Code: [Select]
cd ~
dtc -I dtb -O dts /boot/overlays/mhs35.dtbo mhs35.dts
sed -i -e 's|^\([ \t]*\)rotate *= *<[^>]*>|\1rotate = <0>|g' mhs35.dts
dtc -I dts -O dtb mhs35.dts mhs35.dtbo
sudo cp -f mhs35.dtbo /boot/overlays/mhs35.dtbo
sudo cp -f mhs35.dtbo /boot/overlays/mhs35-overlay.dtb
sudo chmod u=rw,go=r /boot/overlays/mhs35*.dtb*
to decompile the device tree overlay, change the rotation parameter, recompile it, and save it back.  Reboot.  If the display orientation changes, but isn't correct, run
Code: [Select]
cd ~
sed -i -e 's|^\([ \t]*\)rotate *= *<[^>]*>|\1rotate = <180>|g' mhs35.dts
dtc -I dts -O dtb mhs35.dts mhs35.dtbo
sudo cp -f mhs35.dtbo /boot/overlays/mhs35.dtbo
sudo cp -f mhs35.dtbo /boot/overlays/mhs35-overlay.dtb
sudo chmod u=rw,go=r /boot/overlays/mhs35*.dtb*
and reboot.

In both cases, the sed command edits the rotate value in mhs35.dts.  You can use nano mhs35.dts instead, if you don't trust my regular expression. :|

If this does not fix it either, then deeper digging is needed.  Listing the files you have in /boot/overlays/ would be a good start for that.

Edited to add: Also, if you run a 5.4 or newer kernel, then you might be using TINYDRM_ILI9486 (ili9486) DRM driver instead (which is a much better solution anyway).  So, do check your kernel version (uname -r or cat /proc/version), too.
« Last Edit: May 05, 2024, 05:58:44 pm by Nominal Animal »
 
The following users thanked this post: bodzio_stawski

Offline bodzio_stawskiTopic starter

  • Regular Contributor
  • *
  • Posts: 53
  • Country: lt
Re: [Raspberry pi] 3.5 inch display - rotation does not work
« Reply #6 on: May 05, 2024, 06:37:33 pm »
Thanks for the reply :)

You could install dtc,
    sudo apt install device-tree-compiler
and then run
Code: [Select]
cd ~
dtc -I dtb -O dts /boot/overlays/mhs35.dtbo mhs35.dts
sed -i -e 's|^\([ \t]*\)rotate *= *<[^>]*>|\1rotate = <0>|g' mhs35.dts
dtc -I dts -O dtb mhs35.dts mhs35.dtbo
sudo cp -f mhs35.dtbo /boot/overlays/mhs35.dtbo
sudo cp -f mhs35.dtbo /boot/overlays/mhs35-overlay.dtb
sudo chmod u=rw,go=r /boot/overlays/mhs35*.dtb*
to decompile the device tree overlay, change the rotation parameter, recompile it, and save it back.

After this line I get:

Code: [Select]
Usage: dtc [options] <input file>

Options: -[qI:O:o:V:d:R:S:p:a:fb:i:H:sW:E:@AThv]
  -q, --quiet               
Quiet: -q suppress warnings, -qq errors, -qqq all
  -I, --in-format <arg>     
Input formats are:
dts - device tree source text
dtb - device tree blob
fs  - /proc/device-tree style directory
 -o, --out <arg>           
Output file
  -O, --out-format <arg>     
Output formats are:
dts - device tree source text
dtb - device tree blob
yaml - device tree encoded as YAML
asm - assembler source
  -V, --out-version <arg>   
Blob version to produce, defaults to 17 (for dtb and asm output)
  -d, --out-dependency <arg>
Output dependency file
  -R, --reserve <arg>       
Make space for <number> reserve map entries (for dtb and asm output)
  -S, --space <arg>         
Make the blob at least <bytes> long (extra space)
  -p, --pad <arg>           
Add padding to the blob of <bytes> long (extra space)
  -a, --align <arg>         
Make the blob align to the <bytes> (extra space)
  -b, --boot-cpu <arg>       
Set the physical boot cpu
  -f, --force               
Try to produce output even if the input tree has errors
  -i, --include <arg>       
Add a path to search for include files
  -s, --sort                 
Sort nodes and properties before outputting (useful for comparing trees)
  -H, --phandle <arg>       
Valid phandle formats are:
legacy - "linux,phandle" properties only
epapr  - "phandle" properties only
both   - Both "linux,phandle" and "phandle" properties
  -W, --warning <arg>       
Enable/disable warnings (prefix with "no-")
  -E, --error <arg>         
Enable/disable errors (prefix with "no-")
  -@, --symbols             
Enable generation of symbols
  -A, --auto-alias           
Enable auto-alias of labels
  -T, --annotate             
Annotate output .dts with input source file and line (-T -T for more details)
  -h, --help                 
Print this help and exit
  -v, --version             
Print version and exit

Error: missing files
even though the file mhs35.dtbo is in the Overlays folder, and has the appropriate access permissions, so it should be possible for the dtc command to process it...

Code: [Select]
ls /boot/overlays
act-led.dtbo
adafruit18.dtbo
adafruit-st7735r.dtbo
adau1977-adc.dtbo
adau7002-simple.dtbo
ads1015.dtbo
ads1115.dtbo
ads7846.dtbo
adv7282m.dtbo
adv728x-m.dtbo
akkordion-iqdacplus.dtbo
allo-boss2-dac-audio.dtbo
allo-boss-dac-pcm512x-audio.dtbo
allo-digione.dtbo
allo-katana-dac-audio.dtbo
allo-piano-dac-pcm512x-audio.dtbo
allo-piano-dac-plus-pcm512x-audio.dtbo
anyspi.dtbo
apds9960.dtbo
applepi-dac.dtbo
arducam-64mp.dtbo
arducam-pivariety.dtbo
at86rf233.dtbo
audioinjector-addons.dtbo
audioinjector-bare-i2s.dtbo
audioinjector-isolated-soundcard.dtbo
audioinjector-ultra.dtbo
audioinjector-wm8731-audio.dtbo
audiosense-pi.dtbo
audremap.dtbo
balena-fin.dtbo
bcm2712d0.dtbo
camera-mux-2port.dtbo
camera-mux-4port.dtbo
cap1106.dtbo
chipdip-dac.dtbo
cirrus-wm5102.dtbo
cma.dtbo
cm-swap-i2c0.dtbo
crystalfontz-cfa050_pi_m.dtbo
cutiepi-panel.dtbo
dacberry400.dtbo
dht11.dtbo
dionaudio-kiwi.dtbo
dionaudio-loco.dtbo
dionaudio-loco-v2.dtbo
disable-bt.dtbo
disable-bt-pi5.dtbo
disable-emmc2.dtbo
disable-wifi.dtbo
disable-wifi-pi5.dtbo
dpi18cpadhi.dtbo
dpi18.dtbo
dpi24.dtbo
draws.dtbo
dwc2.dtbo
dwc-otg.dtbo
edt-ft5406.dtbo
enc28j60.dtbo
enc28j60-spi2.dtbo
exc3000.dtbo
fbtft.dtbo
fe-pi-audio.dtbo
fsm-demo.dtbo
gc9a01.dtbo
ghost-amp.dtbo
goodix.dtbo
googlevoicehat-soundcard.dtbo
gpio-charger.dtbo
gpio-fan.dtbo
gpio-hog.dtbo
gpio-ir.dtbo
gpio-ir-tx.dtbo
gpio-key.dtbo
gpio-led.dtbo
gpio-no-bank0-irq.dtbo
gpio-no-irq.dtbo
gpio-poweroff.dtbo
gpio-shutdown.dtbo
hat_map.dtb
hd44780-lcd.dtbo
hdmi-backlight-hwhack-gpio.dtbo
hifiberry-amp100.dtbo
hifiberry-amp3.dtbo
hifiberry-amp4pro.dtbo
hifiberry-amp.dtbo
hifiberry-dac8x.dtbo
hifiberry-dac.dtbo
hifiberry-dacplusadc.dtbo
hifiberry-dacplusadcpro.dtbo
hifiberry-dacplusdsp.dtbo
hifiberry-dacplus.dtbo
hifiberry-dacplushd.dtbo
hifiberry-digi.dtbo
hifiberry-digi-pro.dtbo
highperi.dtbo
hy28a.dtbo
hy28b-2017.dtbo
hy28b.dtbo
i2c0.dtbo
i2c0-pi5.dtbo
i2c1.dtbo
i2c1-pi5.dtbo
i2c2-pi5.dtbo
i2c3.dtbo
i2c3-pi5.dtbo
i2c4.dtbo
i2c5.dtbo
i2c6.dtbo
i2c-bcm2708.dtbo
i2c-fan.dtbo
i2c-gpio.dtbo
i2c-mux.dtbo
i2c-pwm-pca9685a.dtbo
i2c-rtc.dtbo
i2c-rtc-gpio.dtbo
i2c-sensor.dtbo
i2s-dac.dtbo
i2s-gpio28-31.dtbo
ilitek251x.dtbo
imx219.dtbo
imx258.dtbo
imx290.dtbo
imx296.dtbo
imx327.dtbo
imx378.dtbo
imx462.dtbo
imx477.dtbo
imx519.dtbo
imx708.dtbo
interludeaudio-analog.dtbo
interludeaudio-digital.dtbo
iqaudio-codec.dtbo
iqaudio-dac.dtbo
iqaudio-dacplus.dtbo
iqaudio-digi-wm8804-audio.dtbo
iqs550.dtbo
irs1125.dtbo
i-sabre-q2m.dtbo
jedec-spi-nor.dtbo
justboom-both.dtbo
justboom-dac.dtbo
justboom-digi.dtbo
ltc294x.dtbo
max98357a.dtbo
maxtherm.dtbo
mbed-dac.dtbo
mcp23017.dtbo
mcp23s17.dtbo
mcp2515-can0.dtbo
mcp2515-can1.dtbo
mcp2515.dtbo
mcp251xfd.dtbo
mcp3008.dtbo
mcp3202.dtbo
mcp342x.dtbo
media-center.dtbo
merus-amp.dtbo
mhs35.dtbo
mhs35.dts
mhs35-overlay.dtb
midi-uart0.dtbo
midi-uart0-pi5.dtbo
midi-uart1.dtbo
midi-uart1-pi5.dtbo
midi-uart2.dtbo
midi-uart2-pi5.dtbo
midi-uart3.dtbo
midi-uart3-pi5.dtbo
midi-uart4.dtbo
midi-uart4-pi5.dtbo
midi-uart5.dtbo
minipitft13.dtbo
miniuart-bt.dtbo
mipi-dbi-spi.dtbo
mlx90640.dtbo
mmc.dtbo
mz61581.dtbo
ov2311.dtbo
ov5647.dtbo
ov64a40.dtbo
ov7251.dtbo
ov9281.dtbo
overlay_map.dtb
papirus.dtbo
pca953x.dtbo
pcf857x.dtbo
pcie-32bit-dma.dtbo
pcie-32bit-dma-pi5.dtbo
pibell.dtbo
pifacedigital.dtbo
pifi-40.dtbo
pifi-dac-hd.dtbo
pifi-dac-zero.dtbo
pifi-mini-210.dtbo
piglow.dtbo
piscreen2r.dtbo
piscreen.dtbo
pisound.dtbo
pisound-pi5.dtbo
pitft22.dtbo
pitft28-capacitive.dtbo
pitft28-resistive.dtbo
pitft35-resistive.dtbo
pps-gpio.dtbo
proto-codec.dtbo
pwm1.dtbo
pwm-2chan.dtbo
pwm.dtbo
pwm-ir-tx.dtbo
qca7000.dtbo
qca7000-uart0.dtbo
ramoops.dtbo
ramoops-pi4.dtbo
README
rotary-encoder.dtbo
rpi-backlight.dtbo
rpi-codeczero.dtbo
rpi-dacplus.dtbo
rpi-dacpro.dtbo
rpi-digiampplus.dtbo
rpi-ft5406.dtbo
rpi-poe.dtbo
rpi-poe-plus.dtbo
rpi-sense.dtbo
rpi-sense-v2.dtbo
rpi-tv.dtbo
rra-digidac1-wm8741-audio.dtbo
sainsmart18.dtbo
sc16is750-i2c.dtbo
sc16is752-i2c.dtbo
sc16is752-spi0.dtbo
sc16is752-spi1.dtbo
sdhost.dtbo
sdio.dtbo
sdio-pi5.dtbo
seeed-can-fd-hat-v1.dtbo
seeed-can-fd-hat-v2.dtbo
sh1106-spi.dtbo
si446x-spi0.dtbo
smi-dev.dtbo
smi.dtbo
smi-nand.dtbo
spi0-0cs.dtbo
spi0-1cs.dtbo
spi0-2cs.dtbo
spi1-1cs.dtbo
spi1-2cs.dtbo
spi1-3cs.dtbo
spi2-1cs.dtbo
spi2-1cs-pi5.dtbo
spi2-2cs.dtbo
spi2-2cs-pi5.dtbo
spi2-3cs.dtbo
spi3-1cs.dtbo
spi3-1cs-pi5.dtbo
spi3-2cs.dtbo
spi3-2cs-pi5.dtbo
spi4-1cs.dtbo
spi4-2cs.dtbo
spi5-1cs.dtbo
spi5-1cs-pi5.dtbo
spi5-2cs.dtbo
spi5-2cs-pi5.dtbo
spi6-1cs.dtbo
spi6-2cs.dtbo
spi-gpio35-39.dtbo
spi-gpio40-45.dtbo
spi-rtc.dtbo
ssd1306.dtbo
ssd1306-spi.dtbo
ssd1331-spi.dtbo
ssd1351-spi.dtbo
superaudioboard.dtbo
sx150x.dtbo
tc358743-audio.dtbo
tc358743.dtbo
tinylcd35.dtbo
tpm-slb9670.dtbo
tpm-slb9673.dtbo
uart0.dtbo
uart0-pi5.dtbo
uart1.dtbo
uart1-pi5.dtbo
uart2.dtbo
uart2-pi5.dtbo
uart3.dtbo
uart3-pi5.dtbo
uart4.dtbo
uart4-pi5.dtbo
uart5.dtbo
udrc.dtbo
ugreen-dabboard.dtbo
upstream.dtbo
upstream-pi4.dtbo
vc4-fkms-v3d.dtbo
vc4-fkms-v3d-pi4.dtbo
vc4-kms-dpi-generic.dtbo
vc4-kms-dpi-hyperpixel2r.dtbo
vc4-kms-dpi-hyperpixel4.dtbo
vc4-kms-dpi-hyperpixel4sq.dtbo
vc4-kms-dpi-panel.dtbo
vc4-kms-dsi-7inch.dtbo
vc4-kms-dsi-generic.dtbo
vc4-kms-dsi-lt070me05000.dtbo
vc4-kms-dsi-lt070me05000-v2.dtbo
vc4-kms-dsi-waveshare-panel.dtbo
vc4-kms-kippah-7inch.dtbo
vc4-kms-v3d.dtbo
vc4-kms-v3d-pi4.dtbo
vc4-kms-v3d-pi5.dtbo
vc4-kms-vga666.dtbo
vga666.dtbo
vl805.dtbo
w1-gpio.dtbo
w1-gpio-pi5.dtbo
w1-gpio-pullup.dtbo
w1-gpio-pullup-pi5.dtbo
w5500.dtbo
watterott-display.dtbo
waveshare-can-fd-hat-mode-a.dtbo
waveshare-can-fd-hat-mode-b.dtbo
wittypi.dtbo
wm8960-soundcard.dtbo

EDIT:
Edited to add: Also, if you run a 5.4 or newer kernel, then you might be using TINYDRM_ILI9486 (ili9486) DRM driver instead (which is a much better solution anyway).  So, do check your kernel version (uname -r or cat /proc/version), too.

The kernel is supposedly 6.6.20. I will look for this TINYDRM_ILI9486 (ili9486) DRM driver.
« Last Edit: May 05, 2024, 06:47:43 pm by bodzio_stawski »
 

Offline radiolistener

  • Super Contributor
  • ***
  • Posts: 3502
  • Country: ua
Re: [Raspberry pi] 3.5 inch display - rotation does not work
« Reply #7 on: May 05, 2024, 08:03:06 pm »
config.txt, cmdline.txt and overlays folder are moved from /boot/ to /boot/firmware/ with some update for 6.* kernel.

So, the proper way is to edit /boot/firmware/config.txt instead of /boot/config.txt

if you edit /boot/config.txt it won't have effect.

Did you take this into account?
 
The following users thanked this post: bodzio_stawski

Offline bodzio_stawskiTopic starter

  • Regular Contributor
  • *
  • Posts: 53
  • Country: lt
Re: [Raspberry pi] 3.5 inch display - rotation does not work
« Reply #8 on: May 05, 2024, 09:31:49 pm »
config.txt, cmdline.txt and overlays folder are moved from /boot/ to /boot/firmware/ with some update for 6.* kernel.

So, the proper way is to edit /boot/firmware/config.txt instead of /boot/config.txt

if you edit /boot/config.txt it won't have effect.

Did you take this into account?

I didn't take this into account at all, I admit. When I came to the conclusion that terminal commands change the values ​​in the /boot/config.txt file, I had no idea that this second file (/boot/firmware/config.txt) exists. Thank you very much, this solved the problem and now the rotation finally works. Thanks also to you, Nominal Animal, because you gave me a lot of new content along the way, also devoting your time. Thank you gentlemen!
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf