Author Topic: ODROID XU4 - gui environment installed but Failed to open X11 display error  (Read 5808 times)

rwebb616

  • Jr. Member
  • **
  • Posts: 24
    • View Profile
So how does one set up attract to run at startup without starting an entire desktop environment.  I have it installed but basically I want attract mode to come up at boot and not have to launch it from the desktop.

Right now I have changed my default systemctl target to multi-user so it boots to a shell login with no display manager. 

I manually compiled attract mode using the USE_GLES=1 flag and have not done the make install yet. I was just trying to get the executable to run and it's giving me this error:
Failed to open X11 display: make sure the DISPLAY environment variable is set correctly.
Aborted

It would be really good if there were some documentation on this.  It seems like a basic thing that most people would like to know how to accomplish.

Thanks
Rich

kent79

  • Hero Member
  • *****
  • Posts: 842
    • View Profile
First of all, I have no experience to do that. But I have idea, you may try.

Following as below guide to install Retropie in ODROID XU4 and then install Attract Mode. It should be OK.

https://retropie.org.uk/docs/Odroid-XU3-XU4/

rwebb616

  • Jr. Member
  • **
  • Posts: 24
    • View Profile
Yes, I thought of doing that too - was just getting started on it.  In the RetroPie setup script though under experimental Attract mode is listed as not available.  I'm not sure if I install manually if it will put everything in the place it should be for Retropie.

Rich

rwebb616

  • Jr. Member
  • **
  • Posts: 24
    • View Profile
Ok - installed RetroPie now and Attract mode will not run even in X now.  It gives me an error in the terminal window saying something about can't display texture or something.  At first I got a shared library error so I recompiled attract mode.  It compiled successfully but it just won't run under X11

Any help? Please? :)

Rich

kent79

  • Hero Member
  • *****
  • Posts: 842
    • View Profile
http://forum.attractmode.org/index.php?topic=2275.msg15386#msg15386
Please try to follow #8 Retropie Setup & Install Attract Mode

Calvin

  • Newbie
  • *
  • Posts: 8
    • View Profile
Hi, I was trying to achieve the same thing (running outside X11) the last few days and I finally got it working. There really is a lack of documentation on that topic.

The issue you are having is probably due to the sfml installation you are using. The steps I took to have it run outside X11 were basically:

1) Compile and install sfml-pi (DRM version) Instructions: https://github.com/mickelson/sfml-pi
2) sudo make install to install your newly compiled sfml-pi
3) Compile and install attract as you did with flag USE_DRM=1

This should be enough to run attract straight from the console. I have tested this on Ubuntu Server.

If you are experiencing any issues feel free to ask as I went through this procedure recently I might be able to help. (Although I am a newbie with Linux)

EDIT: I think all your emulators have to also support KMS/DRM. I am using Retroarch for this. Instructions: https://docs.libretro.com/guides/kms-mode/
« Last Edit: October 28, 2021, 12:37:21 AM by Calvin »

rwebb616

  • Jr. Member
  • **
  • Posts: 24
    • View Profile
http://forum.attractmode.org/index.php?topic=2275.msg15386#msg15386
Please try to follow #8 Retropie Setup & Install Attract Mode

Thanks for that - but on the Odroid this does not work - Attract is listed as unavailable in the retropie experimental packages.  Works fine on the Pi though.

Rich

rwebb616

  • Jr. Member
  • **
  • Posts: 24
    • View Profile
Hi, I was trying to achieve the same thing (running outside X11) the last few days and I finally got it working. There really is a lack of documentation on that topic.

Is this for the odroid?  I'm guessing sfml-pi really doesn't mean only for Rpi ?

Rich

Calvin

  • Newbie
  • *
  • Posts: 8
    • View Profile
I don't know about odroid. As long as you can compile you should be fine. My Ubuntu Server runs on a regular desktop PC not a Raspberry.
Quote
Is this for the odroid?  I'm guessing sfml-pi really doesn't mean only for Rpi
Exactly it is not only for Rpi. This had me confused as well.

rwebb616

  • Jr. Member
  • **
  • Posts: 24
    • View Profile
Ok well I just wrote a fresh sd card with 18.04 and ran all the updates.  I'm not sure if I should install RetroPie first or work on getting Attract Mode running under the console first.  My 18.04 is a minimal install so no GUI installed at all. 

It would be really cool if there were someone that had an Odroid-XU4 that wanted to work with me to get a stable attract mode image.. or at least a guide on how to set one up using Attract Mode and RetroPie. 

Calvin - feel like investing in an Odroid?  about $71 on Amazon. :)
Rich

rwebb616

  • Jr. Member
  • **
  • Posts: 24
    • View Profile
Ok got it all compiled - will not run - getting errors about failing to set mode:

Failed to set mode: Unknown error 524
Aborted

« Last Edit: October 28, 2021, 02:29:24 PM by rwebb616 »

rwebb616

  • Jr. Member
  • **
  • Posts: 24
    • View Profile
Tried to run again and got another error about the pixel format modifier :

Code: [Select]
Attract-Mode v2.6.1 (Linux, SFML 2.5.1 +FontConfig +SWF)
avcodec 57.107.100 / avformat 57.83.100 / swscale 4.8.100 / avutil 55.78.100 / swresample 2.9.100

Config file not found: /home/arcade/.attract/attract.cfg
 - Constructed 1 filters in 0 ms (1 comparisons)
[ 3311.078905] [drm:exymos_plane_atomic_check] *ERROR* unsupported pixel format modifier
Failed to set mode: Unknown error 524
Aborted
arcade@odroid:~$

Calvin

  • Newbie
  • *
  • Posts: 8
    • View Profile
Bummer, but hey, some progress at least :). Sadly I do not know much about Odroid. Honestly, your thread was the first time I heard about it. It is an arm board, isn't it? And you are running Ubuntu.

Maybe it would help if I tried to get it running on my Pi4 running Ubuntu server or smth?

The config file not found error you can ignore. After you get it starting correctly it will create a config file. I did not experience this pixel modifier error however, things that I would try:

1) sudo attract (if there even is something like sudo on your os)
2) If you didn't already, compile smfl-pi and attractmode with the openGLes flags in addition to DRM. I think ES is for embedded systems, which your odroid should be.

Edit: you also have to use the USE_GLES=1 option when running sudo make install.

« Last Edit: October 28, 2021, 03:07:26 PM by Calvin »

rwebb616

  • Jr. Member
  • **
  • Posts: 24
    • View Profile
Yes I did see that as an option - I'll go back and try that.  I wondered.. didn't know what ES stood for but that makes sense. I'll give that a try a little later and post back my results.. I think the last time I did it, I used that option.

Rich

rwebb616

  • Jr. Member
  • **
  • Posts: 24
    • View Profile
Tried that and it couldn't find something - I am pretty sure I have the GLES libraries installed:

Looks kind of like a path thing but I don't know if there are any GLES includes... didn't see anything under the include directory.

I tried posting the output but I get an internal server error when I try to post it on the forum.  Basically it says

CMake Error at /usr/share/cmake-3.10/Modules/FindPackageHandleStandardArgs.cmake:137 (message):
  Could NOT find GLES (missing: GLES_INCLUDE_DIR)

Looks kind of like a path thing but I don't know if there are any GLES includes... didn't see anything under the include directory.

Rich
« Last Edit: October 28, 2021, 04:44:02 PM by rwebb616 »