Classes - Beard

You are here: start » robot_soccer » 2014 » minnowboard


|

Meta

Starting out with the Minnowboard

Getting a Working Image

To begin working with your Minnowboard you will need to update the Angstrom image. The one that came with the board is about 2 years old and doesn't have all of the kernel functionality that we need in order to use the Wifi Adaptors. Here is a link to the updated SDcard image as well as the link to the Forum Topic that discusses this updated image.
Forum on Image
SDcard Image

Koen's latest builds! :D
Useful Angstrom Link?

Here is a link to a tutorial on how to copy the SDcard image onto the SDcard that is used for the board. Note that the image that the tutorial uses is old so just substitute the updated image that you just downloaded.
Getting Your Image onto the SDcard

Alternatively, you can format a USB drive and boot from it instead of the SD Card.
Installing Angstrom on a Hard Disk
Download the image for a flash drive below (3.9ish Gb):
Hard Disk Image

Here is the script used in the eLinux article:
Script to Write to Flash Drive
Ubuntu uses “dash” for its shell, so if this script gives you trouble change the first line, the shebang line, to be “#!/bin/bash” instead.

Booting Angstrom for the First Time

Now that you have a fresh Angstrom Image on your board its time to start it up! Unfortunately there are a few things that you will need to do in order to get X-windows to function properly. The first thing you will need to do is connect via serial link to the board over the miniUSB interface. Here are the steps you will need to take.

  1. Make sure the Minnowboard is connected properly and that power is on.
  2. The serial port is very, very touchy. If you abruptly end the serial connection it gets all gummed up and the board needs to be reset. So the following commands must be used to start and end sessions, or you're going to have a bad day.
  3. Start a sesson with:
    sudo screen /dev/ttyUSB0 115200,ctsrts
  • Screen is a really cool command with lots of uses.
    • To stop the serial connection from reading the keyboard you press “ctrl + a”.
    • In order to end a session correctly you need to:
      • “ctrl + a”, then 'k' to kill, and answer with 'y'
    • Alternatively you can use:
      • “ctrl + a”, then 'd' to detach from the session
      • This leaves the session open so you can reattach to it at a later time with -r
  1. Now that you have a session open, you should get a login prompt. Just enter “root” for the login to get to a terminal prompt. You will now need to edit one file in order to get gui functionality. Run the following commands to edit the file.
  • cd /etc/X11
    vim xorg.conf
  • In this file you will need to make 3 changes. In the “Screen” section you will need to add the following line after 'SubSection “Display”'
    • Modes  "1280x1024"
    • Where the resolution is that of the monitor you are connecting the minnow to.
  • Then Scroll down to the “# Primary display” Section.
  • Here you need to make sure that you cahnge the Avail and NotAvail lines as follows:
    • Option     "ALL/1/Port/2/General/EdidAvail"      "2"
      Option     "ALL/1/Port/2/General/EdidNotAvail"   "1"
  1. Now to install the proper wifi drivers and configure it for the right network
  • Run the following to install support for the white Atheros adapter:
    • opkg install linux-firmware-ath9k
  • Now edit this file to configure it for your network: /var/lib/connman/wifi.config
  • [service_home]
    Type = wifi
    Name = "my ssid name here"
    Security = "my security here" e.g. wpa2-psk
    Passphrase  = "this is a passphrase"

Linux

Terminal Shortcuts

  • Ctrl+L to clear terminal
  • Ctrl+U to clear up to the beginning
  • Ctrl+Y recalls line cleared by Ctrl+U
  • Ctrl+K deletes all after cursor
  • Ctrl+A or Home to go to beginning of line
  • Ctrl+C to cancel line
  • Ctrl+Shift+(C|V) or (Ctrl|Shift)+Insert to copy and paste within terminal

Virtual Terminals

A virtual terminal (VT) is a basic text console supported in almost every single linux distro.
In case of GUI session failures or distros that have no GUI, a VT can serve as a great backup.
Whether you're in Ubuntu or Angstrom you can simply press Ctrl+Alt+(F1-F12) to switch to a different display or VT.
Distros like Ubuntu have 6 VTs (F1-F6) and 6 GUI displays (F7-F12).
Angstrom defaults to F2 for it's GUI and F1,F2-F6 serve as VTs.

Startup Scripts

This still needs to be hammered out.
Some links describing what is done on other distros to implement startup scripts:
http://nixcraft.com/showthread.php/956-Script-file-to-be-run-when-linux-boot
http://www.cyberciti.biz/tips/linux-how-to-run-a-command-when-boots-up.html