Unable to start Totalcross HelloWorld App on IMX6ULL

I built a custom Yocto image using the tdx-wayland distribution with the following graphical stack in my image:

  1. weston
  2. weston-init
  3. weston-xwayland
  4. packagegroup-tdx-graphical

I then cloned the HelloWorld project on my computer from: embedded-samples/hello-world at main · TotalCross/embedded-samples · GitHub

I am able to compile and run this code on my linux computer; However when I scp the linux_arm target onto my imx6ull I am getting the following error:

root@colibri-imx6ull:/home/root/HelloWorld# Testing video drivers...
SDL_VIDEODRIVER available: x11 wayland dummy
SDL_VIDEODRIVER selected : x11
SDL_DisplayMode #0: current display mode is 800x480x0
X connection to :0.0 broken (explicit kill or server shutdown).

I also tried running the wayland-app-launch.sh script which did not help.

What am I missing ?

I have also created a custom user in the yocto image and when I try to ssh with the custom user I get the following error:

colibri-imx6ull:~/linux_arm$ ./HelloWorld 
Testing video drivers...
No protocol specified
SDL_VIDEODRIVER available: x11 wayland dummy
No protocol specified
SDL_Init(): No available video device
Exiting: 107

Hi @nmohan86,

We’ve had success running XWayland commands from the terminal with scripts similar to the following:

if test -z "$XDG_RUNTIME_DIR"; then
    export XDG_RUNTIME_DIR=/run/user/`id -u`
    if ! test -d "$XDG_RUNTIME_DIR"; then
        mkdir --parents $XDG_RUNTIME_DIR
        chmod 0700 $XDG_RUNTIME_DIR
# wait for weston
while [ ! -e  $XDG_RUNTIME_DIR/wayland-0 ] ; do sleep 0.1; done
sleep 1
export DISPLAY=:0.0
/path/to/the/application &

Please give that a try and let us know if it works for you.

Additionally, when you get everything working and are ready to run it automatically at boot, please see this link for details on the service script needed.


I spoke with people from TotalCross and they suggested if you have further issues to create an issue over on their github.


I was able to resolve the issue. I needed to add the gpicview recipe to the Yocto image I built.

Excellent. Thanks for reporting back.