Script in autostart
-
Hi again friends.
Im trying to run an script when my retropie starts, my autostart.sh its like that:
while pgrep omxplayer >/dev/null; do sleep 1; done
(sleep 10; mpg123 -Z /home/pi/bgm/*.mp3 >/dev/null 2>&1) &
emulationstation #auto
myscript.shIf i run the script it works perfect in the command line but not doing nothing at start. Its something wrong? Its a script that erase a file, inside the script i have
rm -f (and the folder and file)
Im not at home so i cant remember full folderAny ideas? Thanks
-
@codafire Your script seems to be running after EmulationStation, so it won't run until EmulationStation is stopped/restarted.
-
@mitu ok i try to put it before emulationstation runs, basically the script erase an empty file that i use with an if conditional, i make an option that let me pause the music, if i activate it, the if creates an objects and while the file exists the music stop playing and if i push again the if erase the file and the music continues. i want that the raspberry erase that file if we have music paused so the music start on the startup and i can activate pause again in the menus.
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.