Raspberry Pi Installation Instructions For Dump1090 Mutability

The quickest and easiest way to set up a Raspberry Pi from scratch is to download the minimalist Raspbian Stretch Lite image, to copy that to your SD card and then configure it.  The following steps take you through that process.

If you’ve just got a new Raspberry Pi kit and it came with the NOOBs software we suggest wiping the card and replacing it with Raspbian Stretch Lite as you’ll only installing what you need and not wasting lots of space on things you don’t.  Details on how to do this can be found in step 1.

  1. Create a Raspbian Stretch Lite image on your SD card

Download your preferred version of the latest version of Raspbian Stretch Lite from here:

https://www.raspberrypi.org/downloads/raspbian/

There are two versions available.  The Desktop version includes all sorts of extra tools that you’ll only need if you’re going to use your Raspberry Pi for something else.  It’s also a bigger download.  The Stretch Lite version is a stripped back command line only version and is the one that is recommended especially if your Raspberry Pi is going to sit in an attic and do nothing but decode ADSB data.  It’s also much smaller and takes up less disk space. These instructions assume that you download Stretch Lite.

Insert your SD card into your PC and format it with:

https://www.sdcard.org/downloads/formatter_4/

Then copy the image that you downloaded to the SD card using Win32DiskImager (if using a PC).  Mac users – I’m afraid that I don’t know the name of an equivalent tool.  Can any Mac users point me in the direction of one ?

2. Preconfiguring Wifi

If you’re not going to use Wifi with your Raspberry Pi skip to the next step (3).

If you’re planning on using Wifi to connect to your Raspberry Pi then we can pre-configure it at this stage by going to this and copying the text into Notepad.  Change the value of Save this file as wpa_supplicant.conf in the boot folder on the drive that contains your new Raspberry Pi SD card.  On my laptop this appears as drive D: (yours may very well vary depending on the amount of harddrives installed or other sd cards plugged in your computer).

 

Make sure that when you save it that you change the ‘Save as type’ to ‘All files’ (and not Text files) otherwise the file will end being called wpa_supplicant.conf.txt.  This will NOT work.  If you accidentally end up with a file called wpa_supplicant.conf.txt right-click on it and select Rename, then delete the .txt portion.

3. Preconfiguring SSH

So that we can log in to the Raspberry Pi from another computer we need to enable SSH.  The easiest way to do this is to simply create an empty file in the boot folder on your Raspberry Pi SD card called ssh.txt.  Then right-click on the file, select ‘Rename’ and remove the .txt from the end.  When the Raspberry Pi starts up it will see a file called ssh and will enable SSH for us.

Once done, safely eject the SD card, remove the microSD card from the card holder and insert it into your Raspberry Pi.

4. Power on the Raspberry Pi

Power up the Raspberry Pi and give it around 30 seconds long in to your Wifi.  So that we can continue to configure it we’ll need to find out what its IP address is.  To find out what this is you’ll need to look in your routers ‘Connected Devices’ list to find it.  By default the Raspberry Pi will be called raspberrypi.  Make a note of this IP address because this is what we will use to connect to the Raspberry Pi in future.

If it’s not in the list, power it down and put the SD card back into your computer, open the /boot/wpa_supplicant.conf file with Notepad and check that you’ve correctly entered your Wifi name and password and correct them if required.

5. Connect to the Raspberry Pi using Putty

Before we can connect to the Raspberry Pi remotely we’ll need to install a free program called Putty.  This will allow us to log into the Raspberry Pi from another computer on the same network.  The advantage of doing it this way is that you can cut and paste all of the following commands into Putty by selecting them on here, doing Ctrl C to copy them and the right-clicking in the Putty window.

So let’s download the latest Putty from here:

http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html

and download the version suitable for your computer.  Then run it and, in the Host Name (or IP address) box put the following:

1
pi@192.168.1.X

where the 192.168.1.X is the IP address of your Raspberry Pi that you found earlier like so:

 

When prompted enter the password ‘raspberry’.

Once logged in, enter the command:

1
passwd

and you’ll be prompted to enter the current password and then enter a new password twice.  If you’re not sure what to use as a new password then use 360radar.  From now on you’ll need to enter the username pi and your new password to log in.

Now we need to configure the Raspberry Pi.  Enter the command:

1
sudo raspi-config

This will run a clunky looking configuration program where you use the cursor keys and the Enter key to select options.

Choose to boot into the command line (Option 3 then B1, B1) as this will save memory and the RPi will almost certainly be used without monitor, keyboard and mouse when it’s finally configured.

Then setup localization – basically this is telling it the timezone (Option 4, I2, Europe and then your nearest city).

Finally go into Advanced options (Option 7) and expand the file system (A1).

We’ll take this opportunity to update the Raspberry Pi in case any updates have been released since the Debian Jessie files were put together.  To do so enter the following commands:

1
sudo apt-get update
1
sudo apt-get upgrade

We’ll apply any changes by rebooting the Raspberry Pi with the following command:

1
sudo reboot

 

6. Build and install dump1090-mutability

We’ll use dump1090 to connect to the RTL dongle so we’ll build the latest version from the source code using the following commands:

1
sudo apt-get install git
1
sudo apt-get install debhelper
1
sudo apt-get install librtlsdr-dev
1
sudo apt-get install libusb-1.0-0-dev
1
cd /etc/udev/rules.d/
1
sudo wget https://www.wiganpi.co.uk/files/rtl-sdr.rules
1
sudo chmod 666 rtl-sdr.rules
1
cd /tmp
1
git clone https://github.com/mutability/dump1090.git
1
cd dump1090
1
sudo dpkg-buildpackage -b
1
sudo dpkg -i ../dump1090-mutability_1.15~dev_armhf.deb

You’ll be prompted to start dump1090 automatically.  Answer yes.

7. Protect the dongle and allow remote connections

RTL dongles can be used on the Raspberry Pi to receive digitial TV.  By default the Raspberry Pi will try to install its own drivers so we want to stop this from happening.  We can tell it to ignore the dongle by doing the following:

1
sudo nano /etc/modprobe.d/no-rtl.conf

and adding the following lines:

1
blacklist dvb_usb_rtl28xxu
1
blacklist rtl2832
1
blacklist rtl2830

Save and exit with Ctrl X, Y and Enter.  Then do:

1
sudo nano /etc/default/dump1090-mutability

and look for the line starting NET_BIND_ADDRESS in the networking section.  Change:

1
NET_BIND_ADDRESS=”127.0.0.1″

to

1
NET_BIND_ADDRESS=””

Save and exit with Ctrl X, Y and Enter

8. Enable dump1090’s web output

So that you can check on the Raspberry Pi to see what aircraft it is seeing we need to turn on the web server:

1
sudo apt-get install lighttpd
1
sudo lighty-enable-mod dump1090
1
sudo service lighttpd force-reload
1
sudo service dump1090-mutability restart

You should now be able to access your RPi with the following:

http://RaspberryPI-IP-Address/dump1090

where RaspberryPI-IP-Address is the IP address of your Raspberry Pi

9. Install Python

The final step is to install the programming language Python so that

1
sudo apt-get install python3

Now, having set up everything up you may want to install your choosed mlat client to upload data to your choosen service such has 360radar, freedar, flightaware or adsb exchange.

Leave a comment

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

%d bloggers like this: