Restart attactmode via command line (or reload attract.cfg)
-
Hi,
sounds easy but isnt.
How can i restart attractmode and only attractmode (so without rebooting my raspberry) via bash commandline?
Just restart.in autostart.sh the command is 'startx' and no more 'attract'.
when i try
pi@retropie:~ $ pkill attract pi@retropie:~ $ attract
it gives me the error
Failed to open X11 display; make sure the DISPLAY environment variable is set correctly
also, if i run
./runattract
it gives me
Error: Couldn't connect to XServer passing null display xterm: Xt error: Can't open display: xterm: DISPLAY is not set Xorg: no process found
I can also avoid to restart attractmode if there is a way to reload attract.cfg after I edit it via script
Thanks
-
attractmode
doesn't need an X server to run on a Pi and it's not configured as such in RetroPie. I'm also not aware of anyrunattract
script - is this something you created or it's from the image you're using ? -
@mitu in the new version of retropie for raspberry pi 4 attractmode uses X server.
Here more details how it works
https://pastebin.com/mAmEERyG -
@superdan said in Restart attactmode via command line (or reload attract.cfg):
@mitu in the new version of retropie for raspberry pi 4 attractmode uses X server.
The package included in RetroPie-Setup doesn't use any X server and it works just like EmulationStation. Not sure where those instructions are coming from (and when they were written), but they're obsoleted by the package included in RetroPie.
-
@mitu thanks foru tour answer, in fact i compiled manually attractmode when 'attractmode' was not available in retropie downloads script for raspberry pi 4 but anyway it's working like a charm.
So i guess if is there a way
Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.
Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.