[Documentation] [TitleIndex] [WordIndex

(!) Please ask about problems and questions regarding this tutorial on answers.ros.org. Don't forget to include in your question the link to this page, the versions of your OS & ROS, and also add appropriate tags.

Wifi Network Setup

Description: Instructions for setting up a wifi link to aid in development.

Tutorial Level: INTERMEDIATE

Next Tutorial: Tether Network Setup

If you are going to use the Pi's Ethernet port for the tether connection to the surface, we recommend adding a miniature wifi dongle and setting up wifi. This will enable easy development and will leave your Ethernet port free for a direct connection to a surface computer (see below.) First, install the wpasupplicant package if you haven't already:

sudo apt-get update
sudo apt-get install wpasupplicant

Then write your network connection details to /etc/wpa_supplicant/wpa_supplicant.conf. It should look something like this:

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

network={
    ssid="YourWifiNetworkName"
    proto=RSN
    key_mgmt=WPA-PSK
    pairwise=CCMP TKIP
    group=CCMP TKIP
    psk="YourWifiNetworkPassword"
}

Next, configure your wireless adapter by adding or modifying the settings in /etc/network/interfaces:

allow-hotplug wlan0
iface wlan0 inet manual
wpa-roam /etc/wpa_supplicant/wpa_supplicant.conf
iface wlan0 inet dhcp
auto wlan0

Finally, restart your network interface by restarting the computer or the networking daemon and test out your new connection!

sudo /etc/init.d/networking restart
sudo ifup wlan0
ping -I wlan0 google.com

For more information, check out this guide.


2019-06-15 12:31