Hi All,
I have the following hardware:
- MCIMX6ULL-EVK Evaluation kit
- NXP LCD8000-43T LCD Display
I have followed the linux Yocto build instructions from: L4.9.88_2.0.0_LINUX_DOCS
My ultimate goal is to get a web browser running and displaying on the LCD display. At the moment I would settle for _any_ GUI application displaying at all.
As I understand it, for the i.MX6ULL the following is true:
- No vivante GPU, only G2D
- Therefore no QT support since no GPU
I see that Wayland / Weston supports G2D so I am attempting to build this image to get something working.
i.MX_Reference_Manual.pdf, Rev.L4.9.88_2.0.0-ga, 05/2018 page 164
$ MACHINE=imx6ull14x14evk DISTRO=fsl-imx-xwayland source fsl-setup-release.sh -b build-
wayland
bitbake fsl-image-gui
On boot I can see the u-boot splash screen, and the open-embedded loading screen (from psplash I think). Finally the screen will show a cursor. So I know that some graphics capability is there.
If I then issue:
cat /dev/urandom > /dev/fb0
I get noise on the screen.
My next step is to try to start Weston.
Following the document i.MX_Reference_Manual.pdf, page 165
export FB_MULTI_BUFFER=1
I have then tried the following:
Command:
weston --tty=1 --device=/dev/fb0 --use-g2d=1 &
Response
[14:39:47.015] weston 3.0.0
http://wayland.freedesktop.org
Bug reports to: https://bugs.freedesktop.org/enter_bug.cgi?product=Wayland&component=weston&version=3.0.0
Build: 3.0.0-208-g5b77bec4-dirty desktop-shell: Disable idle timeout [YOCIMX-2463] (2018-04-27 12:52:23 -0500)
[14:39:47.016] Command line: weston --tty=1 --device=/dev/fb0 --use-g2d=1
[14:39:47.016] OS: Linux, 4.9.88-imx_4.9.88_2.0.0_ga+g5e23f9d61147, #1 SMP PREEMPT Fri Dec 14 15:18:23 GMT 2018, armv7l
[14:39:47.017] Using config file '/etc/xdg/weston/weston.ini'
[14:39:47.018] Output repaint window is 16 ms maximum.
[14:39:47.018] Loading module '/usr/lib/libweston-3/drm-backend.so'
[14:39:47.018] Failed to load module: /usr/lib/libweston-3/drm-backend.so: cannot open shared object file: No such file or directory
[14:39:47.019] fatal: failed to create compositor backend
From this thread it seems that there is no drm-backend.so backend support on i.MX6.
I can see the following files however:
root@imx6ull14x14evk:~# ls -1 /usr/lib/libweston-3/
fbdev-backend.so
gl-renderer.so
wayland-backend.so
x11-backend.so
xwayland.so
So I tried the following:
Command:
weston --tty=1 --device=/dev/fb0 --use-g2d=1 -use-gl=0 --backend=fbdev-backend.so &
Response
root@imx6ull14x14evk:~# Date: 2018-12-14 UTC
[14:47:02.293] weston 3.0.0
http://wayland.freedesktop.org
Bug reports to: https://bugs.freedesktop.org/enter_bug.cgi?product=Wayland&component=weston&version=3.0.0
Build: 3.0.0-208-g5b77bec4-dirty desktop-shell: Disable idle timeout [YOCIMX-2463] (2018-04-27 12:52:23 -0500)
[14:47:02.294] Command line: weston --tty=1 --device=/dev/fb0 --use-g2d=1 -use-gl=0 --backend=fbdev-backend.so
[14:47:02.294] OS: Linux, 4.9.88-imx_4.9.88_2.0.0_ga+g5e23f9d61147, #1 SMP PREEMPT Fri Dec 14 15:18:23 GMT 2018, armv7l
[14:47:02.296] Using config file '/etc/xdg/weston/weston.ini'
[14:47:02.297] Output repaint window is 16 ms maximum.
[14:47:02.310] Loading module '/usr/lib/libweston-3/fbdev-backend.so'
[14:47:02.335] Failed to load module: /usr/lib/libweston-3/fbdev-backend.so: undefined symbol: fbDestroyDisplay
[14:47:02.335] fatal: failed to create compositor backend
Command:
weston --tty=1 --device=/dev/fb0 --use-g2d=1 -use-gl=0 --backend=wayland-backend.so &
Response:
root@imx6ull14x14evk:~# Date: 2018-12-14 UTC
[14:50:13.569] weston 3.0.0
http://wayland.freedesktop.org
Bug reports to: https://bugs.freedesktop.org/enter_bug.cgi?product=Wayland&component=weston&version=3.0.0
Build: 3.0.0-208-g5b77bec4-dirty desktop-shell: Disable idle timeout [YOCIMX-2463] (2018-04-27 12:52:23 -0500)
[14:50:13.570] Command line: weston --tty=1 --device=/dev/fb0 --use-g2d=1 -use-gl=0 --backend=wayland-backend.so
[14:50:13.570] OS: Linux, 4.9.88-imx_4.9.88_2.0.0_ga+g5e23f9d61147, #1 SMP PREEMPT Fri Dec 14 15:18:23 GMT 2018, armv7l
[14:50:13.571] Using config file '/etc/xdg/weston/weston.ini'
[14:50:13.572] Output repaint window is 16 ms maximum.
[14:50:13.573] Loading module '/usr/lib/libweston-3/wayland-backend.so'
[14:50:13.632] Error: Failed to connect to parent Wayland compositor: No such file or directory
display option: (none), WAYLAND_DISPLAY=(not set)
[14:50:13.632] fatal: failed to create compositor backend
So my question is:
What am I doing wrong - is there a set of instructions I am missing to get Wayland / Weston running on the i.MX6ULL?
Update 1:
If I try the same on the L4.9.88_2.0.0_images_MX6UL7D example images, I get the same things, however I do see the following:
First to get the image to boot on the imx6ull, in u-boot, set the dtb to the correct one for the imx6ull (Note the extra lower-case L):
=> setenv fdt_file imx6ull-14x14-evk.dtb
=> saveenv
Saving Environment to MMC...
Writing to MMC(1)... done
Then on boot I see:
[ OK ] Started Terminate Psplash Boot Screen.
[ OK ] Started Permit User Sessions.
Starting Weston Wayland Compositor (on tty7)...
[ OK ] Started Serial Getty on ttymxc0.
[ OK ] Started Getty on tty1.
[ OK ] Reached target Login Prompts.
[ OK ] Reached target Sound Card.
[ OK ] Started Weston Wayland Compositor (on tty7).
[ OK ] Started Kernel Logging Service.
[ OK ] Created slice User Slice of root.
[ OK ] Started Session c1 of user root.
Starting User Manager for UID 0...
[ OK ] Reached target Multi-User System.
Starting Update UTMP about System Runlevel Changes...
[ OK ] Started Update UTMP about System Runlevel Changes.
[ OK ] Started User Manager for UID 0.
NXP i.MX Release Distro 4.9.88-2.0.0 imx6ul7d ttymxc0
imx6ul7d login:
I also found the following advice in the i.MX_Graphics_User's_Guide_Linux.pdf, Rev. 0, 05/2018, Page 70
[Chapter 9 G2D compositor on Weston]
edit the file /etc/default/weston as follows:
#!/bin/sh
OPTARGS="--xwayland --use-g2d=1"
GPU_VIV_EXT_RESOLVE=0
restart weston:
systemctl restart weston
I see the screen flicker here, so maybe weston is running...
Run an example app:
export GPU_VIV_EXT_RESOLVE=0
weston-simple-egl
but this crashes and I get the following error:
weston-simple-egl: ../git/clients/simple-egl.c:901: main: Assertion `display.display' failed.
Aborted (core dumped)
I feel like I am close, but I think it should be easier than this...
Thanks,
Brian.