Cannot start QT graphical container

Hello,

I am trying to pull up a grahical Qt container on the Verdin imx8mplus with the Verdin development board with the 10.1 inch cap screen.

I am following the instructions here:

I did get the torizon screen shown plus I got the grey screen (without the bash terminal) as well, however, I need to demonstrate some graphics on it and need to run a QT container.

When I run the commands, I get the following error. Please can you let me know what is missing here, because I am basically expecting to run some moving graphics on the LVDS screen.

docker run -e ACCEPT_FSL_EULA=1 --rm -it --name=qt5 -v /tmp:/tmp -v /dev/dri:/dev/dri -v /dev/galcore:/dev/galcore --device-cgroup-rule=‘c 199:* rmw’ --device-cgroup-rule=‘c 226:* rmw’ torizon/qt5-wayland-examples-vivante:$CT_TAG_QT5_WAYLAND_EXAMPLES_VIVANTE bash
Unable to find image ‘torizon/qt5-wayland-examples-vivante:2’ locally
2: Pulling from torizon/qt5-wayland-examples-vivante
b5d25b35c1db: Pull complete
20d4f1677cac: Pull complete
3f905f20d91b: Pull complete
e3c635173928: Pull complete
97566cd3f6f6: Pull complete
59b9507c072c: Pull complete
d4cc19b8605f: Pull complete
f4c51aaf167c: Pull complete
6c416ab46912: Pull complete
8d18b1465c69: Pull complete
980224b336b1: Pull complete
6b9800cd213a: Pull complete
3a6718c25d55: Pull complete
3fd9b33098a2: Pull complete
79738df04aab: Pull complete
3b2303b36a9d: Pull complete
6aa16b4d160a: Pull complete
522b3e47b7d6: Pull complete
0ceb7c0e3c9c: Pull complete
2d7b1a0a05a1: Pull complete
5c1167e4c235: Pull complete
91729e4e0f7b: Pull complete
db84a7b77844: Pull complete
Digest: sha256:4b288e3ee2283c8395a462b423250ff0359ceba3fd846fb30e0eb6e5186722b1
Status: Downloaded newer image for torizon/qt5-wayland-examples-vivante:2
root@1da693ae7e73:/# /usr/lib/aarch64-linux-gnu/qt5/examples/opengl/cube/cube &
[1] 6
root@1da693ae7e73:/# Failed to create wl_display (No such file or directory)
qt.qpa.plugin: Could not load the Qt platform plugin “wayland” in “” even though it was found.
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

Available platform plugins are: eglfs, linuxfb, minimal, minimalegl, offscreen, vnc, wayland-egl, wayland, wayland-xcomposite-egl, wayland-xcomposite-glx, xcb.

Hi @SJ_BHD ,

Which version of TorizonCore are you using?

I assume the gray screen you’re referring to is Weston. Can you post the docker run command you’re using to run it before the Qt container?

root@1da693ae7e73:/# Failed to create wl_display (No such file or directory)
qt.qpa.plugin: Could not load the Qt platform plugin “wayland” in “” even though it was found.
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

This error can mean that in the application container some environment variables used to find the graphical server are not setup correctly.

These should be properly configured in our graphical containers, so it is strange that you’re running into this message. Inside the Qt examples container, can you verify with printenv that the following variables have these values?

  • WAYLAND_DISPLAY=wayland-0
  • QT_QPA_PLATFORM=wayland
  • XDG_RUNTIME_DIR=/tmp/1000-runtime-dir

Best regards,
Lucas Akira

Hello @lucas_a.tx ,

Please see details below. I also tried download the latest image from docker and face the same issue.

torizon@verdin-imx8mp-07154617:~$ docker run -e ACCEPT_FSL_EULA=1 --rm -it --name=qt5 -v /tmp:/tmp -v /dev/dri:/dev/dri -v /dev/galcore:/dev/galcore --device-cgroup-rule=‘c 199:* rmw’ --device-cgroup-rule=‘c 226:* rmw’ torizon/qt5-wayland-examples-vivante:3.0.12-20230607 bash
root@d99d240b351b:/# printenv
QT_QPA_EGLFS_INTEGRATION=eglfs_kms
HOSTNAME=d99d240b351b
PWD=/
HOME=/root
QT_QPA_EGLFS_KMS_CONFIG=/etc/kms.conf
WAYLAND_DISPLAY=wayland-0
QT_QPA_PLATFORM=wayland
TERM=xterm
DISPLAY=:0
SHLVL=1
QT_QPA_EGLFS_KMS_ATOMIC=1
XDG_RUNTIME_DIR=/tmp/1000-runtime-dir
LC_ALL=C.UTF-8
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
WAYLAND_USER=torizon
ACCEPT_FSL_EULA=1
_=/usr/bin/printenv
root@d99d240b351b:/# ^C
root@d99d240b351b:/# exit
exit
torizon@verdin-imx8mp-07154617:~$ uname -r
5.4.193-5.7.0+git.f78299297185
torizon@verdin-imx8mp-07154617:~$ uname -a
Linux verdin-imx8mp-07154617 5.4.193-5.7.0+git.f78299297185 #1-TorizonCore SMP PREEMPT Mon Jul 11 14:42:03 UTC 2022 aarch64 aarch64 aarch64 GNU/Linux
torizon@verdin-imx8mp-07154617:~$

Hi @SJ_BHD ,

Thank you for the information. The environment variables look correct.

Can you also inform the docker run command you used for the Weston container? Because I followed the instructions on the Qt article you referenced and I couldn’t reproduce your problem on my side using the Verdin iMX8M Plus on the same TorizonCore version (5.7.0): The example app works as intended.

Best regards,
Lucas Akira

Hello @lucas_a.tx ,

I followed the instructions at this link:

This allowed me to run the QT graphical container. Thanks.

Glad your problem was solved!

Best regards,
Lucas Akira