Scripts that I use on my Raspberry Pi #4

Sometimes you want that your Raspberry Pi connects many different wireless networks. To do this you just have to add file wpa_supplicant.conf to your memory card (You can do that example with notepad) and add this to it:

ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1

network={
    ssid="petrilopia_home"
    psk="password"
    id_str="home"
    priority=1
}

network={
    ssid="petrilopianet_mobile"
    psk="password"
    id_str="mobile"
    priority=2
}

network={
    ssid="petrilopianet_guest"
    psk="password"
    id_str="guest"
    priority=3
}

Of course change “ssid” to be your network SSID and “psk” to be password of that networks and “priority” is where you can change which network your Raspberry Pi tries to connect first which second and so on…

If you want to SSH be enabled when you start up your Raspberry Pi you can do it easily at the same time when you add that wpa_supplicant.conf file to your Raspberry Pi memory card but this time just create empty file called “ssh” without any extension like .txt or anything like that.

Leave a Reply

You can use these HTML tags

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

  

  

This site uses Akismet to reduce spam. Learn how your comment data is processed.