Author Topic: Restart In Attract Mode  (Read 15258 times)

erenner

  • Newbie
  • *
  • Posts: 3
    • View Profile
Restart In Attract Mode
« on: January 26, 2017, 06:19:08 PM »
Hello Everyone!

I am new to all of this.  I just installed Attract Mode on my Raspberry Pi 3 with Retropie 4.1.11.  I did all the updates.  However, I do not have the option in the Retropie menu to "Restart In Attract Mode".  I installed Attract Mode from the built-in experimental packages and did the updates.  I am not sure how to get my Pi to automatically boot into Attract Mode instead of Emulation Station.  Can someone help me out?

Thanks!

Matt68061

  • Full Member
  • ***
  • Posts: 26
    • View Profile
Re: Restart In Attract Mode
« Reply #1 on: January 26, 2017, 07:35:36 PM »
Just curious, did you follow the you tube tutorial from ETAPRIME. (Its like a 29 minute vid...using Floobs image)
I did this a few weeks ago and it worked perfectly. If you havent seen that I suggest checking it out.  It is pretty thorough.  If you did...I would possibly redo the steps with installing the latest updates to Retropie and Attract mode.  Did you reboot after installing them?

I have done some fine tuning to set up my system how I want it...very much trial and error and alot of searching and asking questions.  The folks here are great and very helpful. Just keep at it. It will come.


erenner

  • Newbie
  • *
  • Posts: 3
    • View Profile
Re: Restart In Attract Mode
« Reply #2 on: January 26, 2017, 08:07:11 PM »
I have watched some of ETA's vids.  However, I installed Attract Mode from the experimental packages.  It was not a pre-built image that I "burned" to an SD card.

erenner

  • Newbie
  • *
  • Posts: 3
    • View Profile
Re: Restart In Attract Mode
« Reply #3 on: January 26, 2017, 08:36:23 PM »
I am going through floobs video now.

Matt68061

  • Full Member
  • ***
  • Posts: 26
    • View Profile
Re: Restart In Attract Mode
« Reply #4 on: January 26, 2017, 10:03:27 PM »
Yeah, I tried that at first and while it worked I was constantly chasing down one thing after another.  I do really try to figure things out myself but finally caved and just downloaded his image and am very glad I did.  It just works

akafox

  • Hero Member
  • *****
  • Posts: 906
    • View Profile
Re: Restart In Attract Mode
« Reply #5 on: January 28, 2017, 03:44:20 PM »
That option is part of the attract mode image. You won't find that on the retropie image even if you install it from the experimental side..

Only thing I would know to do is pull the script from the attractmode image and add it into the retropie menu.

give me a day I'll write you up a "how-to"
People want life easy..then complain about it

progets

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1100
    • View Profile
Re: Restart In Attract Mode
« Reply #6 on: January 29, 2017, 03:24:44 AM »
Here's how to build and execute a script that will give you the options to change the boot from both EmulationStation and Attract-Mode. It will also allow you to run the RetroPie Setup menu items from Attract-Mode without having to go into EmulationStation.

Only use this if you are using a RetroPie image from the RetroPie website. It's also a good idea to backup your SD card before attempting this.

create a file on your pi command line
Code: [Select]
nano menu.sh
paste this text into the file and save it
Code: [Select]
mkdir /home/pi/RetroPie/roms/setup
cat >> /home/pi/RetroPie/roms/setup/EmulationStation.sh << EOF
clear
echo "Switching default boot system to EmulationStation and rebooting"
echo ""
sed -i 's/attract/emulationstation/g' /opt/retropie/configs/all/autostart.sh
sudo reboot
EOF
cat >> /home/pi/RetroPie/retropiemenu/Attract-Mode.sh << EOF
echo "Switching default boot system to Attract-Mode and rebooting"
echo ""
sed -i 's/emulationstation/attract/g' /opt/retropie/configs/all/autostart.sh
sudo reboot
EOF
chmod +x /home/pi/RetroPie/retropiemenu/Attract-Mode.sh
echo "clear;echo loading Audio Settings Configuration;"sudo /home/pi/RetroPie-Setup/retropie_packages.sh retropiemenu launch /home/pi/RetroPie/retropiemenu/audiosettings.rp >> "/home/pi/RetroPie/roms/setup/Audio Settings.sh"
echo "clear;echo loading Bluetooth Configuration;"sudo /home/pi/RetroPie-Setup/retropie_packages.sh retropiemenu launch /home/pi/RetroPie/retropiemenu/bluetooth.rp >> /home/pi/RetroPie/roms/setup/Bluetooth.sh
echo "clear;echo loading Configuration Editor;"sudo /home/pi/RetroPie-Setup/retropie_packages.sh retropiemenu launch /home/pi/RetroPie/retropiemenu/configedit.rp >> "/home/pi/RetroPie/roms/setup/Configuration Editor.sh"
echo "clear;echo loading WiFi Configuration;"sudo /home/pi/RetroPie-Setup/retropie_packages.sh retropiemenu launch /home/pi/RetroPie/retropiemenu/wifi.rp >> "/home/pi/RetroPie/roms/setup/Configure Wifi.sh"
echo "clear;echo loading File Manager;"sudo /home/pi/RetroPie-Setup/retropie_packages.sh retropiemenu launch /home/pi/RetroPie/retropiemenu/filemanager.rp >> "/home/pi/RetroPie/roms/setup/File Manager.sh"
echo "clear;echo loading Raspberry Pi Configuration;"sudo /home/pi/RetroPie-Setup/retropie_packages.sh retropiemenu launch /home/pi/RetroPie/retropiemenu/raspiconfig.rp >> "/home/pi/RetroPie/roms/setup/Raspberry Pie Setup.sh"
echo "clear;echo rebooting;"sudo reboot >> /home/pi/RetroPie/roms/setup/Reboot.sh
echo "clear;echo loading RetroArch Configuration;"sudo /home/pi/RetroPie-Setup/retropie_packages.sh retropiemenu launch /home/pi/RetroPie/retropiemenu/retroarch.rp >> "/home/pi/RetroPie/roms/setup/Retroarch Setup.sh"
echo "clear;echo loading RetroArch Netplay Configuration;"sudo /home/pi/RetroPie-Setup/retropie_packages.sh retropiemenu launch /home/pi/RetroPie/retropiemenu/retronetplay.rp >> "/home/pi/RetroPie/roms/setup/Retroarch Netplay.sh"
echo "clear;echo loading RetroPie Configuration;"sudo /home/pi/RetroPie-Setup/retropie_packages.sh retropiemenu launch /home/pi/RetroPie/retropiemenu/rpsetup.rp >> "/home/pi/RetroPie/roms/setup/RetroPie Setup.sh"
echo "clear;echo loading RunCommand Configuration;"sudo /home/pi/RetroPie-Setup/retropie_packages.sh retropiemenu launch /home/pi/RetroPie/retropiemenu/runcommand.rp >> /home/pi/RetroPie/roms/setup/RunCommand.sh
echo "clear;echo finding IP Address;"sudo /home/pi/RetroPie-Setup/retropie_packages.sh retropiemenu launch /home/pi/RetroPie/retropiemenu/showip.rp >> "/home/pi/RetroPie/roms/setup/Show IP Address.sh"
echo "clear;echo powering off;"sudo poweroff >> /home/pi/RetroPie/roms/setup/Shutdown.sh
echo "clear;echo loading Splash Screen Configuration;"sudo /home/pi/RetroPie-Setup/retropie_packages.sh retropiemenu launch /home/pi/RetroPie/retropiemenu/splashscreen.rp >> "/home/pi/RetroPie/roms/setup/Splash Screen.sh"
sudo sh -c "echo '[attractmode]' >>  /etc/samba/smb.conf"
sudo sh -c "echo 'comment = attractmode' >>  /etc/samba/smb.conf"
sudo sh -c "echo 'path = \"/home/pi/.attract\"' >>  /etc/samba/smb.conf"
sudo sh -c "echo 'writeable = yes' >>  /etc/samba/smb.conf"
sudo sh -c "echo 'guest ok = yes' >>  /etc/samba/smb.conf"
sudo sh -c "echo 'create mask = 0644' >>  /etc/samba/smb.conf"
sudo sh -c "echo 'directory mask = 0755' >>  /etc/samba/smb.conf"
sudo sh -c "echo 'force user = pi' >>  /etc/samba/smb.conf"
mkdir /home/pi/RetroPie/roms/setup/box
mkdir /home/pi/RetroPie/roms/setup/cart
mkdir /home/pi/RetroPie/roms/setup/box
mkdir /home/pi/RetroPie/roms/setup/marquee
mkdir /home/pi/RetroPie/roms/setup/snap
mkdir /home/pi/RetroPie/roms/setup/video
mkdir /home/pi/RetroPie/roms/setup/wheel
cp /home/pi/RetroPie/retropiemenu/icons/audiosettings.png "/home/pi/RetroPie/roms/setup/snap/Audio Settings.png"
cp /home/pi/RetroPie/retropiemenu/icons/bluetooth.png /home/pi/RetroPie/roms/setup/snap/Bluetooth.png
cp /home/pi/RetroPie/retropiemenu/icons/configedit.png "/home/pi/RetroPie/roms/setup/snap/Configuration Editor.png"
cp /home/pi/RetroPie/retropiemenu/icons/wifi.png "/home/pi/RetroPie/roms/setup/snap/Configure Wifi.png"
cp /home/pi/RetroPie/retropiemenu/icons/filemanager.png "/home/pi/RetroPie/roms/setup/snap/File Manager.png"
cp /home/pi/RetroPie/retropiemenu/icons/raspiconfig.png "/home/pi/RetroPie/roms/setup/snap/Raspberry Pie Setup.png"
cp /home/pi/RetroPie/retropiemenu/icons/retroarch.png "/home/pi/RetroPie/roms/setup/snap/Retroarch Setup.png"
cp /home/pi/RetroPie/retropiemenu/icons/retronetplay.png "/home/pi/RetroPie/roms/setup/snap/Retroarch Netplay.png"
cp /home/pi/RetroPie/retropiemenu/icons/rpsetup.png "/home/pi/RetroPie/roms/setup/snap/RetroPie Setup.png"
cp /home/pi/RetroPie/retropiemenu/icons/runcommand.png /home/pi/RetroPie/roms/setup/snap/RunCommand.png
cp /home/pi/RetroPie/retropiemenu/icons/showip.png "/home/pi/RetroPie/roms/setup/snap/Show IP Address.png"
cp /home/pi/RetroPie/retropiemenu/icons/splashscreen.png "/home/pi/RetroPie/roms/setup/snap/Splash Screen.png"
chmod +x /home/pi/RetroPie/roms/setup/*.sh
wget http://attractmode.org/images/logo.png
mv logo.png /home/pi/RetroPie/retropiemenu/icons/Attract-Mode.png
wget https://assets.gitlab-static.net/uploads/-/system/project/avatar/2391891/es_raw.png
mv es_raw.png /home/pi/RetroPie/roms/setup/snap/EmulationStation.png
wget https://apprecs.org/gp/images/app-icons/300/0e/com.greatbytes.fastreboot.jpg
mv com.greatbytes.fastreboot.jpg /home/pi/RetroPie/roms/setup/snap/Reboot.png
wget http://chittagongit.com//images/switch-off-icon/switch-off-icon-28.jpg
mv switch-off-icon-28.jpg /home/pi/RetroPie/roms/setup/snap/Shutdown.png
cat >> /home/pi/.attract/emulators/Setup.cfg << EOF
# Generated by Attract-Mode v2.5.1
#
executable           /bin/bash
args                 "[romfilename]"
rompath              /home/pi/RetroPie/roms/setup
romext               .sh
system               Setup
artwork    box       /home/pi/RetroPie/roms/setup/box
artwork    cart      /home/pi/RetroPie/roms/setup/cart
artwork    flyer     /home/pi/RetroPie/roms/setup/box
artwork    marquee   /home/pi/RetroPie/roms/setup/marquee
artwork    snap      /home/pi/RetroPie/roms/setup/video;/home/pi/RetroPie/roms/setup/snap
artwork    wheel     /home/pi/RetroPie/roms/setup/wheel
EOF
sed -i '/\<sound\>/i \display Setup' /home/pi/.attract/attract.cfg
sed -i '/\<sound\>/i \        layout               Basic' /home/pi/.attract/attract.cfg
sed -i '/\<sound\>/i \        romlist              Setup' /home/pi/.attract/attract.cfg
sed -i '/\<sound\>/i \        in_cycle             yes' /home/pi/.attract/attract.cfg
sed -i '/\<sound\>/i \        in_menu              yes' /home/pi/.attract/attract.cfg
sed -i '/\<sound\>/i \        filter               all' /home/pi/.attract/attract.cfg
sed -i '/\<sound\>/i \ ' /home/pi/.attract/attract.cfg
sed -i 's/window_mode          default/window_mode          fullscreen/g' /home/pi/.attract/attract.cfg
attract -b Setup
sed -i '/<\<gameList\>>/a \        </game>' /opt/retropie/configs/all/emulationstation/gamelists/retropie/gamelist.xml
sed -i '/<\<gameList\>>/a \                <image>./icons/Attract-Mode.png</image>' /opt/retropie/configs/all/emulationstation/gamelists/retropie/gamelist.xml
sed -i '/<\<gameList\>>/a \                <desc>Change system boot to the Attract-Mode frontend and reboot.</desc>' /opt/retropie/configs/all/emulationstation/gamelists/retropie/gamelist.xml
sed -i '/<\<gameList\>>/a \                <name>Attract-Mode</name>' /opt/retropie/configs/all/emulationstation/gamelists/retropie/gamelist.xml
sed -i '/<\<gameList\>>/a \                <path>./Attract-Mode.sh</path>' /opt/retropie/configs/all/emulationstation/gamelists/retropie/gamelist.xml
sed -i '/<\<gameList\>>/a \        <game>' /opt/retropie/configs/all/emulationstation/gamelists/retropie/gamelist.xml
sudo reboot

press Ctrl+x to exit and choose "Y" to save it and then press Enter.

on the command line type
Code: [Select]
chmod +x menu.sh

on the command line type
Code: [Select]
./menu.sh

Your Pi should reboot and give you the menus you want.

You can find the Attract-Mode scripts and artwork created by the this script in /home/pi/RetroPie/roms/setup.


Update - I have added sharing the "~/.attract" folder over samba to this script to making accessing AttractMode files easier. I have tested this script with RetroPie builds using Jesse and Stretch.
« Last Edit: December 04, 2018, 10:29:15 PM by progets »

DaOld Man

  • Newbie
  • *
  • Posts: 8
  • Currently running Attract Mode on RPi2 and RPi3
    • View Profile
Re: Restart In Attract Mode
« Reply #7 on: February 07, 2017, 06:11:14 AM »
Great work!
I added the menu items I wanted to the Attract Mode Setup screen (emulator).
When I select an item, the item runs just fine but when I exit the item back to Attract Mode, strange things happen, such as emulator setup screen appearing.
It kinda looks like Attract Mode is remembering the keyboard presses while in the selected item, then running the presses when you exit back to Attract Mode.

progets

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1100
    • View Profile
Re: Restart In Attract Mode
« Reply #8 on: February 07, 2017, 10:45:01 AM »
Great work!
I added the menu items I wanted to the Attract Mode Setup screen (emulator).
When I select an item, the item runs just fine but when I exit the item back to Attract Mode, strange things happen, such as emulator setup screen appearing.
It kinda looks like Attract Mode is remembering the keyboard presses while in the selected item, then running the presses when you exit back to Attract Mode.

F.A.Q. #4 http://forum.attractmode.org/index.php?topic=1249.0