Custom "retropie_welcome" Info
-
Hi all.
I've been trying to change the retropie_welcome screen into something i find useful.This is the current setup:
But it's in heavy development still.
Due to how my Pie is set up, the Disk Space part takes a while to load, and i will look for better implementations:.Current Plans:
Get Installed vs Available RetroPie VersionsNotes:
To get the "Games Available" part i run the below code with autostart.sh## Get Amount of Games fgrep -c '</game>' /home/pi/.emulationstation/gamelists/*/gamelist.xml > /home/pi/RetroPie/systeminfo/totalgamestemp.txt grep -oP '(?<=:)[0-9]+' /home/pi/RetroPie/systeminfo/totalgamestemp.txt > /home/pi/RetroPie/systeminfo/totalgames.txt
Current Code: (v 0.9.1)
0) out+="${fggrn}$(date +"%A, %e %B %Y, %X")" ;; 1) out+="${fggrn}$(uname -srmo)" ;; 2) out+="${fgylw}............... ${fggrn}System Info${fgylw} ..............." ;; 3) out+="${fgred}RetroPie Version...: ${fgylw}$(cd /home/pi/RetroPie-Setup/ && git describe --tags --abbrev=0)" ;; 4) out+="${fgred}Disk Space.........: ${fgylw}$(df -Ph / | awk '$NF == "/" { print $4 }')${fgred}/${fgylw}$(df -Ph / | awk '$NF == "/" { print $2 }')" ;; 5) out+="${fgred}Uptime.............: ${fgylw}${UPTIME}" ;; 6) out+="${fgred}Games Available....: ${fgylw}$(awk '{sum=sum+$1} END {print sum}' /home/pi/RetroPie/systeminfo/totalgames.txt)" ;; 7) out+="${fgred}Configured Systems.: ${fgylw}$(find /home/pi/.emulationstation/gamelists/* -maxdepth 0 -type d | wc -l)" ;; 8) out+="${fgred}IP Address.........: ${fgylw}$(getIPAddress)" ;; 9) out+="${fgred}Temperature........: ${fgylw}CPU: ${cpuTempC}°C ${fgred}| ${fgylw}GPU: ${gpuTempC}°C" ;; 10) out+="${fgwht}The RetroPie Project, https://retropie.org.uk" ;; esac
-
echo $(find /home/pi/RetroPie/roms/ -type f 2> /dev/null | wc -l)
'nes/Super Mario Bros. (USA).zip' 'nes/Super Mario Bros. (USA).state' 'snes/Super Mario World (USA).7z' 'snes/Super Mario World (USA).srm' 'psx/Castlevania - Symphony of the Night (USA) (track 01).bin' 'psx/Castlevania - Symphony of the Night (USA) (track 02).bin' 'psx/Castlevania - Symphony of the Night (USA).cue' 'psx/Castlevania - Symphony of the Night (USA)_1.mcd'
..how many games do I have? How many does this report?
-
@sleve_mcdichael it would not report properly.
I have all my games mounted with rclone towards a gdrive, and i'm using other folders for extra storage. (Gamelists, States, bios,++)
I also do not have cue files for psx games.I will look at better ways to get this number correct. if possible :)
-
I have now added the following to the autostart.sh: (i use autostart-custom.sh)
## Get Amount of Games fgrep -c '</game>' /home/pi/.emulationstation/gamelists/*/gamelist.xml > /home/pi/RetroPie/systeminfo/totalgamestemp.txt grep -oP '(?<=:)[0-9]+' /home/pi/RetroPie/systeminfo/totalgamestemp.txt > /home/pi/RetroPie/systeminfo/totalgames.txt
This will get the amount of </game> tags in all .xmls under gamelists and save it in a temptxt
Then i grep only the numbers from each line and save those as totalgames.txt
Lastly i sum all these numbers with the .bashrcTotal Games changes in .bashrc
6) out+="${fgred}Games Available....: ${fgylw}$(awk '{sum=sum+$1} END {print sum}' /home/pi/RetroPie/systeminfo/totalgames.txt)"
Also made disk space checker faster by adding "/" after -Ph .
4) out+="${fgred}Disk Space.........: ${fgylw}$(df -Ph / | awk '$NF == "/" { print $4 }')${fgred}/${fgylw}$(df -Ph / | awk '$NF == "/" { print $2 }')"
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.