v.2024-08-25
Parent Page

autostart.sh

summary

This script determines what is launched on boot.
Attract Mode to start.
On Attract Mode Exit we can just launch Emulation Station.

location

/opt/retropie/configs/all/autostart.sh
OR
\\donkeykong\configs\all\autostart.sh
Recommend edit in nano to keep execute perms on file.

shell script

zstatus=$?

while true; do

 attract
 zstatus=$?
 echo $zstatus
 if [[ $zstatus -ne 0 ]]; then
   break;
 fi
 sleep 5

 emulationstation
 zstatus=$?
 echo $zstatus
 if [[ $zstatus -ne 0 ]]; then
   break;
 fi
 sleep 5

done