RetroPie + Attract Mode last nagging issue...
-
@mojoatomic Thanks for the black.png (which I've downloaded) and for the explanation which makes sense. That's very helpful and I will have a go with my Retropie shortly changing the config.txt etc. (It's also great to find someone else who uses Attract Mode too on the forum).
I wonder if something similar could be done with any bash script. With 99% of the emulator configurations I'm using, I'm using runcommand together with a launching.png and the console text hides behind the image automatically. However, I've got 1 or 2 configurations that are bash scripts so don't use runcommand and it's been difficult to find a way to hide all of the console text before a game loads. I'm not sure if that's similar to what you're experiencing. Do you think there might be a way to hide the console text behind black.png when launching games, not just when switching on Retropie?
-
@spud11 That's a great question, and one I've tried as well. So far though, it's been a chicken or the egg thing... have to find a way to do it before the console receives focus. Got to be a way.. but in any case, not a deal breaker.
-
Ok I see your point now. I was able to get mine down to just a brief second but it is there long enough to see it..not sure how to hide it completely.
-
Runcommand.sh is just a bash script and it is basically silent which means there must be some command in that script that silences any text or places it in the background behind the picture which is in the foreground.
I noticed with a few of my Attract Mode bash scripts in Attract Mode Setup that use the echo command heavily that whatever is echoed will show but none of the background command stuff will show at all. Perhaps the echo command could be used to silence text eg echo " " .
Or maybe changing the text colour of any terminal output to black would work.
-
Edit the autostart.sh script found in /opt/retropie/configs/all - comment out the attract command and paste this in the file then save.
setterm -cursor off
stty -echo
clear
attract 2>&1 | grep -o $'\033[2J'Create these two files in the /opt/retropie/configs/all directory:
Then sudo nano runcommand-onstart.sh and paste printf "\033[H\033[2J" into the fileAlso, sudo nano runcommand-onend.sh and paste printf "\033[H\033[2J" into the file
sudo reboot - all text gone. Be warned, this will also remove all console text, even the commands you type on the command line from view - they'll still work, you just won't see any output. I like SSHing into the Pi better anyway.
Problem solved, issue gone
-
@mojoatomic said in RetroPie + Attract Mode last nagging issue...:
printf "\033[H\033[2J"
Hi mojoatomic. Thanks for sticking with this.
I've added the commands to each file. However, it winds up at the terminal with the following error:
grep: Unmatched [ or [^
And as a result doesn't make it into Attract Mode.
I copied and pasted your text so it should work.
autostart.sh
now looks like this:# Original # emulationstation #auto # stty -echo;attract &> /dev/null; stty echo # attract > /dev/null 2>&1 # attract setterm -cursor off stty -echo clear attract 2>&1 | grep -o $'\033[2J'
runcommand-onstart.sh
has this at the start:printf "\033[H\033[2J"
runcommand-onend.sh
now looks like this:#!/bin/sh printf "\033[H\033[2J" sudo killall > /dev/null 2>&1 xboxdrv ### Remove " > /dev/null 2>&1 " from line to see information when xboxdrv ends
-
Sorry, typo on my part...
both the runcommand-onstart.sh and runcommand-onend.sh files should haveprintf "\033\033[2J"
and nothing else in them, then be sure to reboot. My typo was a weird slip of a control character.
-
Here's how it looks now - I'm totally happy with this.
-
@mojoatomic Oddly, I'm still getting the same error using
printf "\033\033[2J"
in both runcommand files. Granted myruncommand-onstart
is fairly long as it's got numerous xboxdrv commands, but I wouldn't have expected any problems.Is the last line of the
autostart.sh
code correct, beingattract 2>&1 | grep -o $'\033[2J'
? -
Best advice here is to make your troubleshooting as simple as possible. I would recommend "sudo cp autostart.sh autostart.sh.original, and the same with the "onstart" and "onend" files - that way you can climb back down the tree if you get into trouble.
Next, clear out those files and populate them per the instructions; there's just not a chance of it not working then. I'll attach my working ones to this post and you can just drop them in for a test if it will help.
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.