Boot to Qt for dual monitors on RPi4

  • Hi everyone,

    I am very new to Qt (literally in my 7 day trial) and trying to work out if Qt might be the right solution for what I'm trying to do. I have successfully got a test Qt Quick app to auto-start on my Raspberry Pi 4 with quiet boot etc. Now the last piece of the puzzle is that I need to make use of the second HDMI output on the RPi4. This can either be as a second window of the same app, or as a second/separate app running at the same time.

    I'm wondering if this is doable, and if so, how? I have no idea how to target the other monitor and so far I've just followed the Qt docs to get this far. If this part can be solved, I think I'll go all-in on Qt.

    Cheers and thanks in advance if anyone is able to help!


  • Lifetime Qt Champion

    Hi and welcome to devnet,

    You likely want to take a look at wayland and its support in Qt.

  • Thanks @SGaist very much for the pointer. I've started reading about Wayland.

    If anyone has ever successfully achieved dual monitor output in a Boot to QT setup, I'd still love to hear from you!


  • @lrtjosh I hit the same issue a few days ago with my new RPi4 but found a solution :) The initial symptom also was the rainbow boot splash on the second monitor.

    My setup:

    • RPi4 with two HDMI monitors connector
    • Yocto: Dunfell
    • meta-qt: 5.15.2

    The magic lines to activate the second monitor are the following ones in /boot/config.txt:


    Using these, directly after boot I see a tty also on the second screen. On this, I could simply run a multi-head QtWayland compositor via the eglfs QPA and render clients via wayland-egl (note that you have to activate the linux-dmabuf-v1 protocol). However, it should also work to just start Weston; but I did not test this.

Log in to reply