Leinninger.com

October 19th, 2016:
Upgrade Amibian and Enable WiFi

UPDATE 12/1/17: Amibian 1.4 (or newer) is available, has wifi support and the latest Jessie updates plus a ton of great new feature that make it easier to use than my instructions below!!!!

In my previous post I outlined the (many) steps involved in setting up a raspberry pi 3 in a pi-top laptop case as an Amiga laptop. Since, I can't leave well enough alone, I decided that I wanted to get wifi working and make sure my distribution was more up-to-date than the official Amibian distribution offered. Here are the steps I took to make this happen (at least the steps that I can remember):

It might be worthwhile to use Win32DiskImager (or equivalent) to make a backup of your SD card before trying this. I did and it gave me great peace of mind.

Update Your Pi

(Make sure your connected to a network with Ethernet. Each step will take a while to execute... that's normal.)

  1. "apt-get update"
  2. "apt-get upgrade"
  3. "apt-get dist-upgrade"
  4. "apt-get install rpi-update"
  5. "rpi-update"
Fix Automatic Login
  1. Login using the Amibian defaults: root/1234... or whatever you've changed them to
  2. Edit (see the previous article for file editing from the shell) /etc/systemd/system/getty.target.wants/getty@tty1.service as such:
    1. Change the "ExecStart=" line to: "ExecStart=-/sbin/agetty --autologin root %I"
    2. Change the "Restart=" line to: "Restart=no"
  3. Save and exit the editor
  4. "reboot"

Functionally, you should be back to where you were before starting the upgrade process: Your computer boots and automatically starts the Amiga Emulator. Note, however, that when you quit the emulator "exit" no longer restarts the emulator. Instead it exits the current terminal session. If you want to restart the emulator, just execute your startup script with "/bin/bash ~/.profile". If you accidentally type "exit" out of habit and want to get back into a terminal session, press alt-fn-F2 (or any other alt-function-key combination) to switch to a different terminal session.

Install The Wireless Stuff

These instructions assume that you're using a Raspberry Pi 3 with a built-in wifi interface. Other adapters might be able to leverage some of this info, but the firmware parts probably won't apply.

  1. Install the wireless tools package: "apt-get install wireless-tools"
  2. Install wpa supplicant for secured wireless networks: "apt-get install wpasupplicant"
  3. Configure your wireless connection:
    1. Create and edit a wireless network config file named "/etc/wpa_supplicant/wpa_supplicant.conf" that contains:
      ctrl_interface=/var/run/wpa_supplicant
              ctrl_interface_group=0
              update_config=1
      
              network={
                ssid="network_id"
                psk="password"
                proto=WPA
                key_mgmt=WPA-PSK
                pairwise=TKIP
                group=TKIP
                id_str="Nickname"
              }
    2. Change "network_id" and "password" to your access point's SSID and passphrase. Keep the quotes around the values in that file, though!
  4. Configure your wireless network interface:
    1. edit "/etc/network/interfaces"
    2. Change or add the wlan0 section to...
      auto wlan0
                  iface wlan0 inet dhcp
                  wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf
  5. Unplug your Ethernet and "reboot"
  6. When your computer restarts, Quit the emulator and test your wireless configuration from the shell with: "ifconfig -a". You should see something like:
    eth0      Link encap:Ethernet  HWaddr b8:27:eb:07:e5:49  
              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)
    
    lo        Link encap:Local Loopback  
              inet addr:127.0.0.1  Mask:255.0.0.0
              inet6 addr: ::1/128 Scope:Host
              UP LOOPBACK RUNNING  MTU:65536  Metric:1
              RX packets:8 errors:0 dropped:0 overruns:0 frame:0
              TX packets:8 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:1 
              RX bytes:1104 (1.0 KiB)  TX bytes:1104 (1.0 KiB)
    
    wlan0     Link encap:Ethernet  HWaddr b8:27:eb:52:b0:1c  
              inet addr:192.168.0.45  Bcast:192.168.0.255  Mask:255.255.255.0
              inet6 addr: fe80::ba27:ebff:fe52:b01c/64 Scope:Link
              UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
              RX packets:14966 errors:0 dropped:9 overruns:0 frame:0
              TX packets:1307 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:1000 
              RX bytes:1728707 (1.6 MiB)  TX bytes:171182 (167.1 KiB)
    With an IP address properly configured for wlan0.

There you have it! The official Amibian distribution will be updated soon, but I couldn't wait. If this all seems a little over your head, it might be worth waiting for a packaged solution such as theirs. Please comment with corrections, suggestions, and feedback! Happy Amiga-ing!

2 responses to “Upgrade Amibian and Enable WiFi”

  1. Duane says:

    Sorry about all of the formatting errors. wptexturize was converting things like double-hyphens (–) to ndashes. I fixed this with the Raw HTML plugin.

  2. […] Leinninger.com » Upgrade Amibian and Enable WiFi   […]

Leave a Reply

Your email address will not be published. Required fields are marked *

Devtroit