RetroPie forum home
    • Recent
    • Tags
    • Popular
    • Home
    • Docs
    • Register
    • Login
    Please do not post a support request without first reading and following the advice in https://retropie.org.uk/forum/topic/3/read-this-first

    Autostart function not working

    Scheduled Pinned Locked Moved Help and Support
    autostart helpautostartrom directory
    51 Posts 5 Posters 4.6k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • mituM
      mitu Global Moderator
      last edited by

      As I advised you in the other topic, you need to add the runcommand before the emulationstation #auto line in order to have your ROM started before the Emulationstation front-end.
      But I was under the impression this works - my advice to open a new topic was for the follow-up question: how do you exit from the 1st auto-started Rom to get the Emulationstation ?

      1 Reply Last reply Reply Quote 0
      • ClydeC
        Clyde @Razak
        last edited by Clyde

        @Razak I second @BJRetro's question, because the output of mount | grep /dev doesn't show any usb drive mounted in the directory tree (it should show something like /dev/sda1 on /media/usb0).

        And as I and others here wondered, having your roms in /root/... is very unusual, since that is the home directory of the admin user root. The user pi who runs Emulation Station and the emulators in a standard RetroPie setup normally doesn't have access to this directory and its subdirectories, so it's generally not a good place for your roms.

        Thus, I want to add a question to @mitu's and @BJRetro 's: How exactly did you install the roms in your system? I suspect that you somehow managed to install them as root in that user's home directory instead of the home of pi.

        1 Reply Last reply Reply Quote 0
        • RazakR
          Razak
          last edited by

          Thanks all for your thorough advice. I'm just trying to be as clear and respectful of the forum rules as possible.

          @BJRetro Yes, I believe the ROM is running off of the USB stick, though I may be mistaken and may not be understanding everything correctly. As you can tell, I'm a total beginner on this.

          I followed these steps to get the ROM to the Pi:
          "(ensure that your USB is formatted to FAT32)
          first create a folder called retropie on your USB stick
          plug it into the pi and wait for it to finish blinking
          pull the USB out and plug it into a computer
          add the roms to their respective folders (in the retropie/roms folder)
          plug it back into the raspberry pi
          wait for it to finish blinking
          you can now remove the USB stick.
          refresh emulationstation by pressing F4, or choosing quit from the start menu"

          I named the USB stick 'root' , so I don't think it's actually in the /root folder of the Pi. But, yes @Clyde it is strange that the thumb-drive is not showing up on /dev/sda1. When I power on, I've noticed I get a Failed message during the boot-up sequence. Looks something like this:
          "failed to start @usbmount"

          Hi @mitu Yes, it originally was working, but since I couldn't disable the autostart function using F4, ESC, etc. I re-flashed everything and started from scratch, since I have a feeling that my issue may be related to how I'm formulating the runcommand script, i.e. where the ROM is located and what emulator it is calling (I think I should be invoking stella, not 'atari2600' as I had been.

          Again, thanks all for your help. This forum is an invaluable resource.

          1 Reply Last reply Reply Quote 0
          • mituM
            mitu Global Moderator
            last edited by

            What you're describing is the using the USB to transfer ROMs from your PC to the Pi system. So if you copied a ROM in the atari2600 sub-folder on the USB stick, then it should have been transferred to the corresponding folder under /home/pi/RetroPie/roms/atari2600.

            First thing you need to do is to see if the ROM works if you start it from Emulationstation - the front-end you're seeing after RetroPie starts - and to make sure you can exit the emulator. The name of the emulator is shown on the Runcommand launch screen - https://retropie.org.uk/docs/Runcommand/ - but I think for the Atari 2600 it's lr-stella2014.

            RazakR 1 Reply Last reply Reply Quote 0
            • RazakR
              Razak @mitu
              last edited by

              @mitu The ROM works on the retropie/emulationstation front-end but I can't exit the game using the configured hotkey, F4, ESC, Alt+F4, etc. Would you deduce that it is a mapping issue?
              Should I just remap the whole thing?

              Just saw that the emulator name is indeed, lr-stella2014. Should the autorun script then read:

              /opt/retropie/supplementary/runcommand/runcommand.sh 0 _SYS_ lr-stella2014 /home/pi/RetroPie/roms/atari2600/Yar_rev.bin
              
              mituM 1 Reply Last reply Reply Quote 0
              • mituM
                mitu Global Moderator @Razak
                last edited by

                @Razak said in Autostart function not working:

                Should I just remap the whole thing?

                Have you tried Start + Select buttons on your gamepad (if you have one with these buttons) ?

                The command should be as before, with just the path of the ROM changed:

                /opt/retropie/supplementary/runcommand/runcommand.sh 0 _SYS_ atari2600 /home/pi/RetroPie/roms/atari2600/Yar_rev.bin
                
                RazakR 1 Reply Last reply Reply Quote 0
                • RazakR
                  Razak @mitu
                  last edited by

                  @mitu My joystick/gamepad does not have Start + Select mapped to it. I tried the Start+Select keys on the keyboard and I still can't quit out of the game.

                  1 Reply Last reply Reply Quote 0
                  • mituM
                    mitu Global Moderator
                    last edited by

                    In this case I suggest you install the alternate Atari 2600 emulator (stella) and try to use it with both a keyboard and the Atari controller.

                    RazakR 1 Reply Last reply Reply Quote 0
                    • RazakR
                      Razak @mitu
                      last edited by

                      @mitu Thanks! Are there any instructions out there for this?

                      Did you mean install Stella within the Retropie/emulationstation system or independent of it?

                      mituM 1 Reply Last reply Reply Quote 0
                      • mituM
                        mitu Global Moderator @Razak
                        last edited by

                        @Razak You can install additional emulators from the RetroPie setup menu - https://retropie.org.uk/docs/Updating-RetroPie/#using-the-retropie-setup-script - stella should be in the optional packages. Once installed, you can ue the Runcommand launch menu to change the emulator when the game starts.

                        RazakR 1 Reply Last reply Reply Quote 0
                        • RazakR
                          Razak @mitu
                          last edited by

                          @mitu Gotcha. When I tried to install from source, I got the following error:

                          Error running 'tar -xv -J -c /home/pi/Retropie-Setup/tmp/build/stella--strip-components 1' returned 2'

                          When I go into Package help, I get this message:

                          copy your Atari 2600 ROM to /home/pi/RetroPie/roms/atari2600

                          How do I do that? Through the RetroPie setup or someplace else?

                          mituM 1 Reply Last reply Reply Quote 0
                          • mituM
                            mitu Global Moderator @Razak
                            last edited by mitu

                            @Razak said in Autostart function not working:

                            Error running 'tar -xv -J -c /home/pi/Retropie-Setup/tmp/build/stella--strip-components 1' returned 2'

                            Hm, I'll check if there's an error with the package.

                            When I go into Package help, I get this message:
                            copy your Atari 2600 ROM to /home/pi/RetroPie/roms/atari2600
                            How do I do that? Through the RetroPie setup or someplace else?

                            Transferring ROMs is explained the the getting started Docs. The folder /home/pi/RetroPie/roms/atari2600 is shares in the network (Samba shares, as explained in the doc) as \\retropie\roms\atari2600.

                            EDIT: it doesn't seem to be an error with the package source - is your PI system connected to the internet/network ?

                            RazakR 1 Reply Last reply Reply Quote 0
                            • RazakR
                              Razak @mitu
                              last edited by

                              @mitu D'oh, the pi is not connected to internet. I don't want it to be connected to wi-fi... but I guess it's okay temporarily for installing Stella?

                              ClydeC 1 Reply Last reply Reply Quote 0
                              • ClydeC
                                Clyde @Razak
                                last edited by

                                @Razak It depends on whether your Pi is behind a router with a firewall, then it should be safe without further measures. If the Pi is directly connected to the Internet (e.g. with a modem without a firewall), you should change the password for the user Pi to a safe one (three links) with the command passwd in Retropie's command shell that you land in if you press F4 in Emulation Station. You exit the shell and return to ES with the command exit.

                                1 Reply Last reply Reply Quote 0
                                • RazakR
                                  Razak
                                  last edited by

                                  Hi @mitu @Clyde

                                  So I verified in the file manager that my ROM is in the /home/pi/RetroPie/roms/atari2600 folder, and I'm now connected to a wifi network.

                                  When I go into Retropie -setup, and attempt to install Stella from source, I'm still getting the following error:
                                  Error running 'tar -xv -J -c /home/pi/Retropie-Setup/tmp/build/stella--strip-components 1' returned 2'

                                  Then, it tells me to check the logs at
                                  /home/pi/retropie-setup/logs/rps_2019_04_20_002846.log.gz

                                  When I go there through the file manager, I get this:


                                  *Installing dependencies for 'stella' : Atari2600 emulator STELLA
                                  /home/pi/RetroPie-Setup/tmp/build/stella /home/pi

                                  Getting sources for 'stella' : Atari26000 emulator STELLA

                                  xz: (stdin): file format not recognized
                                  tar: Child returned status 1
                                  tar: Error is not recoverable: exiting now
                                  /home/pi
                                  Error running 'tar -xv -J -C /home/pi/RetroPie-Setup/tmp/build/stella --strip-components 1' -returned 2*

                                  Any thoughts on what may be happening?

                                  mituM 1 Reply Last reply Reply Quote 0
                                  • mituM
                                    mitu Global Moderator @Razak
                                    last edited by

                                    @Razak said in Autostart function not working:

                                    Any thoughts on what may be happening?

                                    The error indicates that the emulator's archive is corrupted and you're still not connected to the internet to download. You can check by exiting Emulationstation, and typing at the command line

                                    ping retropie.org.uk
                                    

                                    If you get a reply, then it means you're connected, otherwise you may be just connected to Wifi, but without internet access.

                                    1 Reply Last reply Reply Quote 0
                                    • RazakR
                                      Razak
                                      last edited by

                                      @mitu The emulator archive meaning the ROM?

                                      I pinged the retropie site and got no response. :(

                                      Is there a way of installing Stella as an optional package that does not necessitate that I get on the internet?

                                      I'm attempting to jump on a public wifi network and it's giving me the error describe above, while my other option is to get on a network that requires I authenticate myself using a username and password.

                                      ClydeC 1 Reply Last reply Reply Quote 0
                                      • mituM
                                        mitu Global Moderator
                                        last edited by

                                        The emulator archive meaning the ROM?

                                        No, I mean file containing the emulator, packed and compressed (archive), which should be downloaded from either the RetroPie site, if you're using a binary installation.

                                        Is there a way of installing Stella as an optional package that does not necessitate that I get on the internet?

                                        No, you need to connect to the internet.

                                        1 Reply Last reply Reply Quote 0
                                        • ClydeC
                                          Clyde @Razak
                                          last edited by Clyde

                                          @Razak said in Autostart function not working:

                                          I'm attempting to jump on a public wifi network and it's giving me the error describe above, while my other option is to get on a network that requires I authenticate myself using a username and password.

                                          The easiest way would be to connect your Pi with an Ethernet cable to an internet router with a built-in firewall. Then you should be able to install any packages you want. Is that an option?

                                          If not, please explain in detail how your "attepting to jump on a public wifi network", why that doesn't work (errors in detail, please), and what other network you're trying to connect to that asks for authentication.

                                          Finally, please put any quoted output in a code block like @mitu did with the ping command. See https://commonmark.org/help/ on how to do that in this forum.

                                          It's much more readible this way. ;)
                                          
                                          RazakR 1 Reply Last reply Reply Quote 0
                                          • RazakR
                                            Razak @Clyde
                                            last edited by

                                            @Clyde

                                            I was wondering how to do block quotes on here. Thank you for clearing this up for me and providing a link! :)

                                            Okay, so I connected the pi to the Internet using an Ethernet cable and was able to download Stella as an optional package. It now says 'installed' next Stella. Great.

                                            Should I now go to autostart or runcommand on the Retropie-Setup script menu?

                                            And if I manually edit the runcommand script, should it now read like so:

                                            /opt/retropie/supplementary/runcommand/runcommand.sh 0 _SYS_ lr-stella /home/pi/RetroPie/roms/atari2600/Yar_rev.bin
                                            emuluationstation #auto
                                            
                                            mituM 1 Reply Last reply Reply Quote 0
                                            • First post
                                              Last post

                                            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.