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

    Is it possible to save multiple wifi networks on retropie?

    Scheduled Pinned Locked Moved Help and Support
    wifiwifi configwifikey
    10 Posts 2 Posters 1.5k 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.
    • H
      HairDyeGuy
      last edited by

      Can retropie hold multiple wifi keys?
      I'm almost done building my handheld, and I wanted to know if retropie can remember wifi networks so if I go to my friend's place I could easily connect to the network.
      Currently I don't have usb access so connecting a keyboard each time I move would be a pain.
      If it's possible, is it an automatic save or do I need to do something manually?
      One final question I have is can I write multiple wifi details on wifikeyfile.txt so I could make retropie learn multiple networks at once? I mean something like this:

      ssid="NETWORK_1"
      psk="NETWORK_PASSWORD"
      ssid="NETWORK_2"
      psk="NETWORK_PASSWORD"
      ssid="NETWORK_3"
      psk="NETWORK_PASSWORD"
      

      Thanks in advance

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

        You can't write multiple entries in wifikeyfile.txt, but you can use the alternate Wi-Fi configuration file - as described in the docs.
        The wpa_supplicant.conf file accepts multiple entries, so if you want to configure multiple networks, just add them to the file and they'll be automatically configured in RetroPie:

        country=US
        ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
        update_config=1
        
        # RETROPIE CONFIG START
        network={
            ssid="NETWORK_1"
            psk="password_for_network1"
        }
        
        network={
            ssid="NETWORK_2"
            psk="password_for_network2"
        }
        # RETROPIE CONFIG END
        

        You only need to configure this once for each new Wi-Fi network, the Wi-Fi settings will be saved.

        H 1 Reply Last reply Reply Quote 0
        • H
          HairDyeGuy @mitu
          last edited by HairDyeGuy

          @mitu Awesome!
          I do so via editing the .txt file or via the command terminal?
          EDIT: I just realized that windows probably can't open .conf files which means I'll need the terminal.
          Is there a way to do copy paste from windows to the terminal? I ask because everything I found on Google didn't work

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

            @hairdyeguy said in Is it possible to save multiple wifi networks on retropie?:

            EDIT: I just realized that windows probably can't open .conf files which means I'll need the terminal.

            You can edit the .conf file with Notepad, even if the extension is .conf, it's still a simple text file. Make sure you save it with the .conf extension and not with .conf.txt.

            H 1 Reply Last reply Reply Quote 0
            • H
              HairDyeGuy @mitu
              last edited by

              @mitu Oh cool.
              Then I just copy and paste the template you sent one after another as many as the numbers of networks I want to add, fill in the details, and press save, right?
              (Also, is there a default setting? I know how to fill some of the fields, but the second one for example is gibberish to me

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

                @hairdyeguy said in Is it possible to save multiple wifi networks on retropie?:

                hen I just copy and paste the template you sent one after another as many as the numbers of networks I want to add, fill in the details, and press save, right?

                Yes, that's the gist of it.

                (Also, is there a default setting? I know how to fill some of the fields, but the second one for example is gibberish to me

                No, there's no default Wi-Fi network configured in RetroPie/Raspbian. The configuration fragment referenced in the doc page is all you need to configure the Wi-Fi - you just need to fill in the network name and the password to access it. I'm not sure what you mean by 'gibberish', can you be more specific ?

                H 1 Reply Last reply Reply Quote 0
                • H
                  HairDyeGuy @mitu
                  last edited by

                  @mitu What I meant to ask is is there a default "answer" to each field to put in case I don't know the answer. For example, I'm not sure if and what to write after update_config= or ctrl_interface= as opposed to country=

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

                    country needs to be set to your country code (see here for the official list). Everything else should left as-is, you just need to fill out the network name/password entries as needed.

                    H 1 Reply Last reply Reply Quote 0
                    • H
                      HairDyeGuy @mitu
                      last edited by

                      @mitu Awesome!
                      I did so and booted up the device. It didn't recognize the network until I used the wifikey file. Just to be clear, when you said boot partition, you meant the extra "drive" that appears on windows and can be accessed on windows, not the folder inside retropie, right?

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

                        @hairdyeguy said in Is it possible to save multiple wifi networks on retropie?:

                        Just to be clear, when you said boot partition, you meant the extra "drive" that appears on windows and can be accessed on windows, not the folder inside retropie, right?

                        Yes, that one.

                        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.