AlaMode: Getting started

Overview  Getting started  How to Buy,  DownloadsUser Guide with examples

Hardware Setup

You should plug your AlaMode into your Raspberry Pi with the power off. It plugs onto the GPIO port to stack perfectly on top of the Raspberry Pi. Because there are contacts in the area over the ethernet connector, you should first apply the supplied rubber bumper to the top of the ethernet connector to prevent shorting between the boards.

Powering the AlaMode

AlaMode can be powered either from the Raspberry Pi, or via it’s own Micro-usb power jack (This isn’t an actual USB interface, but any USB power supply, such as a phone charger can be used to power the AlaMode). The Raspberry Pi’s supply can’t provide very much power to GPIO plates, so you should use the internal power mode only for low power applications. Many shields will draw too much power and cause the Raspberry Pi to crash if you don’t set the external power option. In general, external power is preferred, however, for Blink, and simple low power applications you can use internal power.

To power AlaMode from the Pi, set Jumper P-16 (labeled 5V_LINK, next to the micro-SD slot) to the ON position (shorting the middle pin and the one farthest away from the micro-SD holder). To use external power, shift the jumper towards the micro-SD slot. This is the position that ships from the factory.

[Picture coming soon]

Software setup

Download the latest raspbian (these instructions are for that version.)

http://downloads.raspberrypi.org/raspbian_latest

It also works on noobs but only if you select the raspbian option.

After running through the setup (raspi-config) which runs automatically the first time do a:

$ sudo apt-get update
$ sudo apt-get install arduino

You used to have to get the avrdude and gcc packages separately and install them in an unzipped version of arduino, but there’s now an up-to-date package. This works out of the box with FTDI Arduinos, but Uno’s /dev/ttyACM0 and the Raspberry Pi /dev/tty/AMA0 aren’t recognized by the Arduino IDE. To do that we create some “udev rules” that create symbolic links to those devices that are named /dev/ttyS1 (uo) and /dev/ttyS0 (alamode) respectively.

I created a setup script to do the hard work for you (note the $ represents the command prompt, don’t type that!):

$wget http://git.io/alamode-setup

$ tar -xvzf alamode-setup.tar.gz

$ cd alamode-setup[/code]

next run:

$ sudo ./setup

which disables logging and getty on the internal serial port (so you can use it to program alamode), sets up the /dev/tty links, and installs a modified avrdude that has a new programmer type, -c alamode. This should be completely safe, as I only and (I think properly) added a new programmer type, but I haven’t tested it thoroughly on other programmer types. It also sets up the board type for alamode in the Arduino IDE.

reboot to get rid of the logging and getty.

Here you probably don’t have to reboot, just

$ sudo udevadm trigger

If you want Bonjour, which will allow you to refer to your raspberry Pi on the local network as raspberrypi.local

$ sudo apt-get update
$ sudo apt-get install libnss-mdns