Homepage Forums RetroPie Project Everything else related to the RetroPie Project How to get WiFi on Raspberry Pi 2 with Retropie 3.0

Viewing 17 posts - 1 through 17 (of 17 total)
  • Author
    Posts
  • #93288
    lurch2408
    Participant

    I am running Retropie and Kodi on my Raspberry Pi 2 but want it to run off my WiFi instead of the Ethernet port. All how to guides are for the old GUI but since the stripped down image it doesn’t exist, any ideas?? It might be simple but I’m a complete newbie lol

    #93289
    herbfargus
    Member

    You can follow this video

    Or see the wiki:

    https://github.com/retropie/RetroPie-Setup/wiki/Setting-Up-Wifi

    #93290
    khayman
    Participant

    Not too difficult. From command line:
    sudo nano /etc/network/interfaces

    Near the bottom add the following lines:

    allow-hotplug wlan0
    auto wlan0
    
    iface wlan0 inet dhcp
       wpa-ssid "whatever your ssid is"
       wpa-psk "your network password"

    Ctrl-x to exit nano, it will ask you to save. Just hit Y and then enter to accept the filename. Reboot your pi using:
    sudo reboot

    What I also did that helps is tell raspberry pi to reconnect to my wifi in case I do something stupid like reboot my router. Here’s what I did.

    sudo nano ./wifi_checker.sh

    Inside good ol nano I used this script:

    #!/bin/bash
    
    if ! ifconfig wlan0 | grep -q "inet addr:" ; then
            ifup --force wlan0
            sleep 10
    fi
    

    Save and exit like you did before. Then:

    sudo chmod +x ./wifi_checker.sh

    Next you want to schedule that to run to check the status of your wifi connection. To that we go to crontab.

    sudo crontab -e

    Go to the bottom and enter the following line:

    */5 * * * * ~./wifi_checker.sh

    Exit and save and you should be good to go.

    #94086
    lakespiral
    Participant

    When I type sudo /etc/init.d/networking restart it says:
    [warn] Running /etc/ini.d/networking restart is deprecated because it may not re-enable some interfaces … (warning).
    [….] Reconfiguring network interfaces…RTNETLINK answers: Files exists
    Failed to bring up wlan0.
    done.

    #94101
    herbfargus
    Member

    Yeah that’s not a problem. Easiest thing to do is just sudo reboot. And then if you configured it right it will work just fine.

    #94102
    lakespiral
    Participant

    Well it doesn’t work. Tried with a bunch of different instructions.

    #94103
    khayman
    Participant

    Can you give the output of this (go ahead and rip out the SSID/PW if you want):

    cat /etc/network/interfaces

    Also what model wifi adapter do you have for RPi?

    #94107
    lakespiral
    Participant
    auto lo
    
    iface lo inet loopback
    iface eth0 inet dhcp
    
    allow-hotplug wlan0
    auto wlan0
    iface wlan0 inet static
    address 91.153.69.86
    netmask 255.255.255.0
    gateway 192.168.100.1
    wpa-ssid "*****"
    wpa-psk "*****"
    wireless-power off

    Netwjork PICO -WiFi-adapter.

    #94110
    khayman
    Participant

    I wouldn’t mess with static settings, personally. I’d let the router use DHCP to identify and configure it and then if you want you can just have the router assign it a static IP once you’ve got connectivity. Even easier, go into raspi-config and set it up to advertise itself on the network as “retropie”. Then when I’m home I can just ssh pi@retropie and be on there no problem.

    Also that’s a pretty generic name for a wifi adapter… do you have an actual model number? The lsusb command should list out what you’ve got plugged into USB. Might be helpful to make sure that it’s supported on RPi and that you don’t need any additional drivers or anything.

    #94166
    lakespiral
    Participant

    Ralink RT5370 Wireless Adapter. It came with a driver cd. Maybe I should install them somehow?

    #94170
    monochromatic
    Participant
    #94171
    lakespiral
    Participant

    I’ve tried that too. Doesn’t work.

    Edit: Seems that other people had had problems with the same dongle too: http://www.modmypi.com/blog/how-to-set-up-the-ralink-rt5370-wifi-dongle-on-raspian

    #94180
    khayman
    Participant

    Yeah, I’ve got two different models, one for each of my Pi’s and the way I described above worked for both of them out of the box with no additional software needed.

    Panda PAU06 (ordered from Amazon)
    And this one: https://www.adafruit.com/products/1012

    Good luck.

    #94307
    lurch2408
    Participant

    Thanks very much 4 the info worked 1st time, I’m now free lol

    #94405
    fhenning84
    Participant

    I looked on here until I found this guy with same prob only thing is when I try to restart wlan0 I get this:

    sudo ifup wlan0
    Internet Systems Consortium DHCP Client 4.2.2
    Copyright 2004-2011 Internet Systems Consortium.
    All rights reserved.
    For info, please visit https://www.isc.org/software/dhcp/
    
    Listening on LPF/wlan0/00:0f:60:03:ff:5d
    Sending on   LPF/wlan0/00:0f:60:03:ff:5d
    Sending on   Socket/fallback
    DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 3
    DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 3
    DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 4
    DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 5
    DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 8
    DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 7
    DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 13
    DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 16
    DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 2
    No DHCPOFFERS received.
    No working leases in persistent database - sleeping.
    

    I can see my device with lsusb:

     lsusb
    Bus 001 Device 002: ID 0424:9514 Standard Microsystems Corp.
    Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
    Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp.
    Bus 001 Device 004: ID 0079:0011 DragonRise Inc. Gamepad
    Bus 001 Device 005: ID 046d:c52b Logitech, Inc. Unifying Receiver
    Bus 001 Device 006: ID 148f:5370 Ralink Technology, Corp. RT5370 Wireless Adapter
    

    my /etc/networking/interfaces:

    auto wlan0
    allow-hotplug wlan0
    iface wlan0 inet dhcp
    wpa-ssid 'HOME-9196'
    wpa-psk 'xXxXxXxXxXxXx' #Not listing my wpa2 lol
    

    sudo nano /etc/wpa_supplicant/wpa_supplicant.conf:

    ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
    update_config=1
    network={
        ssid="HOME-9196"
        psk="xXxXxXxXxXxXx"
    }
    

    ifconfig:

    eth0      Link encap:Ethernet  HWaddr b8:27:eb:60:8a:a0
              inet addr:10.0.0.2  Bcast:10.0.0.255  Mask:255.255.255.0
              UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
              RX packets:3602 errors:0 dropped:0 overruns:0 frame:0
              TX packets:2596 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:1000
              RX bytes:237535 (231.9 KiB)  TX bytes:393604 (384.3 KiB)
    
    lo        Link encap:Local Loopback
              inet addr:127.0.0.1  Mask:255.0.0.0
              UP LOOPBACK RUNNING  MTU:65536  Metric:1
              RX packets:6 errors:0 dropped:0 overruns:0 frame:0
              TX packets:6 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:0
              RX bytes:300 (300.0 B)  TX bytes:300 (300.0 B)
    
    wlan0     Link encap:Ethernet  HWaddr 00:0f:60:03:ff:5d
              UP BROADCAST MULTICAST  MTU:1500  Metric:1
              RX packets:0 errors:0 dropped:0 overruns:0 frame:0
              TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:1000
              RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

    Any help would be appreciated =)
    Any advice?

    #94408
    khayman
    Participant

    I think it’s that Ralink 5370 adapter. Both you and lakespiral have it and are having issues when everything else seems normal. Also on that link that lakespiral posted people are still having issues even with the “fix”.

    #94410
    lakespiral
    Participant

    :(

Viewing 17 posts - 1 through 17 (of 17 total)
  • The forum ‘Everything else related to the RetroPie Project’ is closed to new topics and replies.