WL:Wifi Configuration

From gc-linux

Jump to: navigation, search

Contents

Introduction

Our port of the Linux kernel to the Nintendo Wii supports the internal wireless LAN daughter card when booted via BootMii.

The following sections describe the necessary steps to configure a wifi connection on Debian-based distributions (like whiite-linux).

Firmware

Preparing the firmware files

The Nintendo Wii WLAN card requires a system provided firmware to operate.

The team leaded by Francesco Gringoli and Lorenzo Nava from the Universita' degli Studi di Brescia has developed a custom firmware compatible with the Nintendo Wii WLAN card and distributed under the GNU General Public License. To build the firmware image files one needs the assembler from the b43-tools developed by Michael Buesch, the maintainer of the Linux kernel b43 driver.

The firmware files can be easily built using a Linux PC and following these steps, or alternatively you can download a pre-built tarball.

1. Create and switch to a working directory.

$ mkdir workdir && cd workdir

2. Clone the b43-tools repository via git.

$ git clone http://git.bu3sch.de/git/b43-tools.git

3. Change to the assembler directory within b43-tools and build the assembler.

$ cd b43-tools/assembler
$ make

4. Add the directory where the assembler tool resides to the PATH and return to the working directory.

$ export PATH=$PATH:$(pwd)
$ cd ../..

5. Download and uncompress the OpenFWWF v5.2 firmware tarball.

$ wget http://www.ing.unibs.it/openfwwf/firmware/openfwwf-5.2.tar.gz
$ tar xzvf openfwwf-5.2.tar.gz

6. Switch to the OpenFWWF firmware directory, build the firmware image files and return back to the working directory.

$ cd openfwwf-5.2/
$ make
$ cd ..

7. Prepare a tarball with the firmware image files.

$ mkdir -p lib/firmware/b43-open
$ install -m 0644 -t lib/firmware/b43-open openfwwf-5.2/b0g0bsinitvals5.fw openfwwf-5.2/b0g0initvals5.fw openfwwf-5.2/ucode5.fw
$ tar czvf openfwwf-5.2-bin.tar.gz lib/firmware/b43-open

Installing the firmware files

1. Copy the tarball with the firmware files from your PC to your Nintendo Wii.

You can do this using several methods:

  • via the network (if you have a USB ethernet adapter)
  • via a SD card
  • via a USB storage device

In this example, the tarball is copied using ssh via the network (kids, don't allow root to ssh in...!):

$ scp openfwwf-5.2-bin.tar.gz root@192.168.1.58:

2. Logon to your Nintendo Wii running gc-linux, change to the root directory and uncompress the tarball with the firmware image files.

whiite:~# cd /
whiite:/# tar xzvf /root/openfwwf-5.2-bin.tar.gz

Debian packages

You need the following userland packages in Debian to configure and operate the Nintendo Wii WLAN card:

  • wireless-tools
  • wpasupplicant (if you use WPA/WPA2 security)
  • udev (needed to service firmware image requests from the driver)

You can issue the following commands as root from your Nintendo Wii to install those packages:

whiite:~# apt-get update
whiite:~# apt-get install udev wireless-tools wpasupplicant

Debian configuration

The configuration settings and security parameters of your Wireless LAN can be specified in the /etc/network/interfaces file under Debian.

Here you can find some configuration snippets to setup your Nintendo Wii WLAN card for different security configurations.

For additional information, please refer to Debian Wiki.

WPA2

DHCP

whiite:~# vi /etc/network/interfaces

auto wlan0
iface wlan0 inet dhcp
        wpa-ssid YOUR_SSID_GOES_HERE
        wpa-psk YOUR_SECRET_GOES_HERE
        wpa-key-mgmt WPA-PSK
        wpa-pairwise TKIP CCMP
        wpa-group TKIP CCMP
        wpa-proto WPA RSN
        wpa-ap-scan 1
        wpa-scan-ssid 1


Static IP

whiite:~# vi /etc/network/interfaces

auto wlan0
iface wlan0 inet static
        wpa-ssid YOUR_SSID_GOES_HERE
        wpa-psk YOUR_SECRET_GOES_HERE
        wpa-key-mgmt WPA-PSK
        wpa-pairwise TKIP CCMP
        wpa-group TKIP CCMP
        wpa-proto WPA RSN
        wpa-ap-scan 1
        wpa-scan-ssid 1
        address YOUR_IP_GOES_HERE
        netmask YOUR_NETMASK_GOES_HERE
        gateway YOUR_GATEWAY_GOES_HERE

Note that you can also use a pre-computed 256-bit PSK as a secret instead of an ASCII passphrase.

To get a 256-bit PSK from an ASCII passphrase use the following command:

whiite:~# wpa_passphrase your_ssid your_ascii_passphrase

WEP (ASCII string key)

DHCP

whiite:~# vi /etc/network/interfaces

auto wlan0
iface wlan0 inet dhcp
        wireless-essid YOUR_SSID_GOES_HERE
        wireless-key s:YOUR_ASCII_SECRET_GOES_HERE

Static IP

whiite:~# vi /etc/network/interfaces

auto wlan0
iface wlan0 inet static
        wireless-essid YOUR_SSID_GOES_HERE
        wireless-key s:YOUR_ASCII_SECRET_GOES_HERE
        address YOUR_IP_GOES_HERE
        netmask YOUR_NETMASK_GOES_HERE
        gateway YOUR_GATEWAY_GOES_HERE

WEP (binary key)

DHCP

whiite:~# vi /etc/network/interfaces

auto wlan0
iface wlan0 inet dhcp
        wireless-essid YOUR_SSID_GOES_HERE
        wireless-key 0123-4567-89

Static IP

whiite:~# vi /etc/network/interfaces

auto wlan0
iface wlan0 inet static
        wireless-essid YOUR_SSID_GOES_HERE
        wireless-key 0123-4567-89
        address YOUR_IP_GOES_HERE
        netmask YOUR_NETMASK_GOES_HERE
        gateway YOUR_GATEWAY_GOES_HERE

Open

DHCP

whiite:~# vi /etc/network/interfaces

auto wlan0
iface wlan0 inet dhcp
        wireless-essid YOUR_SSID_GOES_HERE

Static IP

whiite:~# vi /etc/network/interfaces

auto wlan0
iface wlan0 inet static
        wireless-essid YOUR_SSID_GOES_HERE
        address YOUR_IP_GOES_HERE
        netmask YOUR_NETMASK_GOES_HERE
        gateway YOUR_GATEWAY_GOES_HERE

Debian operation

The interface associated to your Nintendo Wii WLAN card can be activated and deactivated manually as shown here.

Issue the following command to manually enable the WLAN connection:

whiite:~# ifup wlan0

Issue the following command to manually disable the WLAN connection:

whiite:~# ifdown wlan0
Personal tools