PI4 Multiple Displays Topic is solved

Having issues with your DietPi installation or found a bug? Post it here.
Post Reply
Shaggy
Posts: 2
Joined: Mon Oct 11, 2021 6:02 pm

PI4 Multiple Displays

Post by Shaggy »

Hello Community,

Somewhat new when it comes to Linux. Finding out how I can search for this issue if there is no fix.

Issue:
I upgraded from Buster to Bullseye recently. Everything was running great except for multiple displays. Before the upgrade, both displays worked. After the upgrade, only one display works from the first HDMI port. I do have a black screen and the monitor is able to show as if it's receiving a signal because it does not show "no video connected".

I am still fairly new to Linux. I have ran xrandr to see only the one display I can modify. It is updated with the latest packages. With me being so new, any other troubleshooting steps I can do?

Update 1: I was able to run

Code: Select all

tvservice -l
and see both displays. I am also running XFCE from the default installs. While browsing through the forums, I read somewhere that DietPI is based off of Raspberry PI OS which is what led me to try the

Code: Select all

tvservice -l
command and received the output I did.

Beyond this, any ideas what I could try with Kernal version 5.10 to get both displays working with XFCE4? Would this be more relevant with XFCE4?
User avatar
MichaIng
Site Admin
Posts: 3357
Joined: Sat Nov 18, 2017 6:21 pm

Re: PI4 Multiple Displays

Post by MichaIng »

Can you please paste the following:

Code: Select all

grep -E 'max_framebuffers|dtoverlay' /boot/config.txt
ls -l /dev/fb* /dev/dri
Shaggy
Posts: 2
Joined: Mon Oct 11, 2021 6:02 pm

Re: PI4 Multiple Displays

Post by Shaggy »

MichaIng wrote: Tue Oct 12, 2021 6:34 pm Can you please paste the following:

Code: Select all

grep -E 'max_framebuffers|dtoverlay' /boot/config.txt
ls -l /dev/fb* /dev/dri

Code: Select all

$grep -E 'max_framebuffers|dtoverlay' /boot/config.txt
#max_framebuffers=0
dtoverlay=disable-wifi

$sudo ls -l /dev/fb* /dev/dri
ls: cannot access '/dev/dri': No such file or directory
crw-rw---- 1 root video 29, 0 Oct 11 14:04 /dev/fb0

After some more messing around and researching, I managed to put it somewhat together with the dietpi tool and commands.
The "disable-wifi" didn't look right and I believe is a bug from when updating the PI and modifying the displays. I went back and chose the correct resolution which fixed the display issue. I also ran the wrong command originally as well:

Code: Select all

~$ grep -E 'max_framebuffers|dtoverlay' /boot/config.txt
#max_framebuffers=0
dtoverlay=disable-wifi
dtoverlay=vc4-kms-v3d-pi4
~$ sudo ls -l /dev/fb* /dev/dri
crw-rw---- 1 root video 29, 0 Oct 14 05:54 /dev/fb0

/dev/dri:
total 0
drwxr-xr-x  2 root root        100 Oct 14 05:54 by-path
crw-rw----+ 1 root video  226,   0 Oct 14 05:54 card0
crw-rw----+ 1 root video  226,   1 Oct 14 05:54 card1
crw-rw----+ 1 root render 226, 128 Oct 14 05:54 renderD128
User avatar
MichaIng
Site Admin
Posts: 3357
Joined: Sat Nov 18, 2017 6:21 pm

Re: PI4 Multiple Displays

Post by MichaIng »

Okay great. The disable-wifi is correct if you don't use WiFi, but not related to this issue indeed. What I wanted to see is whether a KMS/DRM driver is enabled, and on your first output it was not, on your second output it is. You have two DRI devices card0 and card1, so they can be correctly used both. Interesting and what looks like a bug is that only one framebuffer device /dev/fb0 is present, while there should be a second one, at least when KMS is disabled and two screens attached. The max_framebuffers option is commented and at least the RPi docs state that in this case two framebuffers are loaded when two screens are attached.

So maybe it would be possible as well to switch via resolution options from KMS to a framebuffer driver (the resolutions without "OpenGL"), or removing the droverlay=vc4* manually from config.txt, and add/set max_framebuffers=2.

If this issue can be replicated, we could report it to the RPi developers, so that two framebuffers are loaded by default with two HDMI ports and screens attached.

But generally on RPi4 fKMS or KMS should perform better than the framebuffer driver, so in your case I'd leave it like that :).
Post Reply