Attract-Mode Support Forum
Attract-Mode Support => Scripting => Topic started by: Joelf on April 29, 2017, 12:27:06 PM
-
Hello, This is on a rasberri pi. I've received a bunch of scripts that do things like shutdown or open the audio settings, I nabbed them from a unified theme.
Here is an example of one of the scripts - this one brings up audio settings it's called audio settings.sh
#!/usr/bin/env bash
sudo /home/pi/RetroPie-Setup/retropie_packages.sh retropiemenu launch /home/pi/RetroPie/retropiemenu/audiosettings.rp
I created a romlist for them, and a CFG file.
rompath /home/pi/RetroPie/roms/Attract Mode Setup
romext .sh
system Attract Mode Setup
artwork flyer /home/pi/RetroPie/roms/Attract Mode Setup/flyer
artwork marquee /home/pi/RetroPie/roms/Attract Mode Setup/marquee
artwork snap /home/pi/RetroPie/roms/Attract Mode Setup/snap
artwork wheel /home/pi/RetroPie/roms/Attract Mode Setup/wheel
As you can see I put the scripts in the roms folder. I think there is something wrong with the CFG file. Whenever I click on a script, it throws an error:
*** Running:
Error executing:
And that's all it tells me. Can someone who has a bit more experience running script files through Attract Mode give me a hint in what's going wrong?
Thanks!
-
One thing that is working are all the snaps and wheel art from this folder.
-
Pi F.A.Q. # 9 http://forum.attractmode.org/index.php?topic=1249.0.
You don't have an executable or argument in your .cfg file.
executable /bin/bash
args "[romfilename]"
You also need to make your scripts executable.
sudo chmod +x "/home/pi/RetroPie/roms/Attract Mode Setup/*.sh"
-
So the chmod couldn't locate the directory, i thought it might be because of the space, I changed it to "setup", and updated the cfg file to point to that:
rompath /home/pi/RetroPie/roms/setup
system Attract Mode Setup
executable /bin/bash
args "[romfilename]"
artwork flyer /home/pi/RetroPie/roms/setup/flyer
artwork marquee /home/pi/RetroPie/roms/setup/marquee
artwork snap /home/pi/RetroPie/roms/setup/snap
artwork wheel /home/pi/RetroPie/roms/setup/wheel
I can CD into the directory, but I can't sudo chmod into it. it says
cannot access ‘/home/pi/RetroPie/roms/setup/*.sh’: No such file or directory
Although I just CD'd right into it. I figured it was a folder permission error, and I went into sftp program and changed the permissions on all the files and the folder to 777, not knowing how else to do this.
The box art, etc. shows up, so the romlist has found the proper folder.
When I run a script from the UI it says
Could not locate rom ... best guess "/home/pi/RetroPie/roms/setup/Run Command"
So weird. I notice it's not putting the .sh at the end of the best guess. Is something missing from the CFG still?
Thanks.
-
AH! got it . I accidentally removed
romext .sh