Further configuration of the Raspberry Pi will take place over the network using SSH, not the keyboard and mouse.
- The SSH server should already be enabled on the Raspberry Pi — this was done during the initial raspi-config setup.
- On Mac or Linux systems, you can use a Terminal or xterm window.
- For Windows systems, you can download PuTTY.
The terminal command to access the system would be:
ssh [email protected] (or whatever hostname was configured) if using Netatalk
or:
ssh [email protected] (or whatever the system’s actual numeric IP address is)
You’ll be prompted for a password — use the password that you set up in raspi-config, or “raspberry” if you left the default. Additionally, the first time connecting you may be prompted regarding a host key for security…enter Y (or click Yes) when prompted.
Once logged in, type the following at the command prompt:
sudo apt-get update
This updates the list of available software packages, and takes a couple of minutes (just do the “update,” not “upgrade” — the latter can sometimes take hours!)
Several prerequisite software packages need to be installed, using different techniques.
First is a collection of code libraries, using the apt-get package manager:
sudo apt-get install git i2c-tools python-pexpect python-smbus libavfilter-dev libavformat-dev libcurl4-gnutls-dev libgcrypt-dev libjson-c-dev libao-dev
This takes a little while; there’s about 100 megabytes of stuff to download and install.
Now use git and wget to install the rest. There’s our LCD radio UI, then a collection of Adafruit libraries for Raspberry Pi, and finally pianobar, a terminal-based Pandora client for Raspberry Pi. Do not use the apt-get version of this, it’s out of date!
cd git clone -b legacy https://github.com/adafruit/Adafruit-Raspberry-Pi-Python-Code git clone https://github.com/adafruit/Python-WiFi-Radio wget https://github.com/PromyLOPh/pianobar/archive/e945578ab22912049f1e547ce7b25b01089f7590.zip unzip e945578ab22912049f1e547ce7b25b01089f7590.zip
Note the “-b legacy” on the first “git clone” line. It’s required there. But not on anything else.
Now some configuration…
First, link some of the Adafruit libraries into the radio software directory:
cd Python-WiFi-Radio ln -s ../Adafruit-Raspberry-Pi-Python-Code/Adafruit_CharLCDPlate/*.py .
(Note: there’s a space before the last period above. Don’t miss it. Copy and paste this exact line, if possible.)
Next, we’ll compile pianobar from source code:
cd ../pianobar-e945578ab22912049f1e547ce7b25b01089f7590 make
You might get a long list of compiler warnings. That’s fine, as long as the build finishes. Compiler errors, on the other hand, will stop the build process. You might be missing a library from the apt-get sequence above, or something in the software may have changed since these instructions were written, in which case post in the Adafruit Forums for assistance.
Once compiled, install using:
sudo cp pianobar /usr/local/bin
Don’t worry about configuring this software yet; we’ll proceed there later. Just use the steps above to get it installed for now.
Page last edited March 08, 2024
Text editor powered by tinymce.