This guide explains how to assemble a simple ADS-B base station using Raspberry Pi and cheap off-the-shelf components and how to connect your station to the OpenSky Network.
The proposed base station will be able to receive and decode transponder signals from planes in the radius of up to 200-300 km.
You will also be able to feed your data into OpenSky Network and other networks and use it in local applications like PlanePlotter.
Instructions below are based on the ADS-B using dump1090 for the Raspberry Pi guide.
This guide assumes installation in a home network with internet connection via router like FRITZ!Box.
- The most important prerequisite is place with clear view of the sky where you could place the antenna.
- If you want to feed your data into OpenSky Network, you must be able to open and forward ports on your router.
- OpenSky Network needs a static host name or IP address to connect to your base station. If you don't have a static IP address (you normally don't), your router must support dynamic DNS using a provider like DuckDNS.org or No-IP.com.
- Your router must support WiFi so that you could connect Raspberry Pi to the network wirelessly.
- Raspberry Pi set
- Receiver
We'll assume that you already have a PC with microSD or SD card reader, monitor with HDMI connection and USB keyboard and mouse needed for installation and that you don't have to order the additionally.
- You will need a 2A power supply for Raspberry Pi.
- Make sure memory card package includes the SD adapter so that you could use this card in a normal PC (which usually has a SD card reader but not the microSD.
- MicroSDHC Class 10 (high speed class) is highly recommended.
- If you connect the receiver to one of the USB port on Raspberry Pi directly, it will cover other ports. You can avoid this using the USB extension cable.
- You'll need a coaxial cable to connect your antenna to your USB RTL-SDR receiver. The shopping list above assumes an antenna with the N Female connector. The recommended NooElec NESDR Mini 2+ receiver has an MCX Female socket, so you basically need to connect MCX Female to N Female. Such cables (MCX Male - N Male) are quite rare, a much better option is a N Male - SMA Male plus SMA Female - MCX Male combination.
- The N Male - SMA Male plus SMA Female - MCX Male combination also using the FlightAware band-pass filter which reduces the noise and increases the number of the processed ADS-B messages. This filter has the SMA Female input and SMA Male output so it can be inserted between to cables (from antenna and to to receiver). If you want to spare the filter, just connect two cables directly.
- The band-pass filter is optional, but it is highly recommended. It drastically increases the number of messages.
- The NooElec NESDR Mini 2+ includes a small SMA Female - MCX Male adapter, so you don't necessarily need the SMA Female - MCX Male cable. However, if you use the FlightAware band-pass filter, it is highly recommended to get SMA Female - MCX Male cable as well to add flexible connection between the filter and the receiver. Otherwise the filter is connected rigidly into the small MCX socket and as a potential to break it.
- Assemble the Raspberry Pi
- Connect the components
- Setup the Raspberry Pi
- Prepare the SD card with the Raspbian operating system
- Perform the Raspbian installation
- Build and install drivers for the RTL-SDR receiver
- Build and install the
dump1090
decoder
- Connect your base station to the OpenSky Network
- Set up dynamic DNS for your Raspberry Pi
- Make the port
30005
port accessible from the internet - Create an OpenSky Network account
- Configure a new sensor in OpenSky Network
- Attach heatsinks to chips
- Fix the Raspberry Pi to the case using screws, close the case
Antenna:
- Antenna N Female
- Cable N Male - SMA Male
- (Optional) Band-pass filter SMA Female - SMA Male
- (Optional) Cable SMA Female - MCX Male, alternatively use the SMA Female - MCX Male adapter
- USB RTL-SDR Receiver
- USB extension cable
- ... to Raspberry Pi
WLAN Adapter:
- WLAN Adaper
- USB extension cable
- ... to Raspberry Pi
Also connect keyboard and mouse.
Follow the NOOBS Setup instructions. In short:
- Download and install the SDFormatter (a software to format your microSDHC card).
- Insert your microSDHC memory card into your PC (using the SD adapter).
- Format the microSDHC card using SDFormatter. Make sure you've selected the correct drive letter. Use the options
FORMAT TYPE
FULL (Erase)
andFORMAT SIZE ADJUSTMENT
OFF
. - Download and unzip NOOBS ("New Out Of the Box Software", an easy operating system installer for Raspberry Pi).
- Copy the uzipped NOOBS files to the freshly formatted microSDHC card.
- Safely eject the memory card.
- Insert the card into Raspberry Pi.
- Connect the power.
- Perform the Raspbian installation.
- Configure the system after installation (you'd typically want to set region and locale and change the default password (
pi
/raspberry
). - Set up the WLAN/internet connection.
- Update and upgrade the system:
sudo apt-get update
sudo apt-get upgrade
- Install
git-core
andgit
:
sudo apt-get install git-core git
Now your Raspberry Pi is ready to be used.
cd ~
git clone https://github.com/openskynetwork/raspberry-pi-adsb.git
chmod +x ~/raspberry-pi-adsb/*.sh
Check out, build and install drivers for the RTL-SDR receiver:
cd ~/raspberry-pi-adsb
./setup-rtl-sdr.sh
You will be prompted to reboot after the set up.
After the system rebooted, you can check the RTL-SDR connection by running:
rtl_test
You should be seeing something like:
Found 1 device(s):
0: Realtek, RTL2838UHIDIR, SN: 00000001
Using device 0: Generic RTL2832U OEM
Found Rafael Micro R820T tuner
Supported gain values (29): 0.0 0.9 1.4 2.7 3.7 7.7 8.7 12.5 14.4 15.7 16.6 19.7 20.7 22.9 25.4 28.0 29.7 32.8 33.8 36.4 37.2 38.6 40.2 42.1 43.4 43.9 44.5 48.0 49.6
[R82XX] PLL not locked!
Sampling at 2048000 S/s.
Info: This tool will continuously read from the device, and report if
samples get lost. If you observe no further output, everything is fine.
Reading samples in async mode...
This means RTL-SDR drivers were compiled and installed successfully.
dump1090
decodes signals coming from the RTL-SDR receiver.
Check out, build and install dump1090
:
cd ~/raspberry-pi-adsb
./setup-dump1090.sh
The setup-dump1090.sh
also installs dump1090
as a service so that dump1090
starts automatically after system restart.
You will be once again prompted to reboot after the set up.
After the system rebooted, you might want to check if dump1090
is running correctly. Just go to http://127.0.0.1:8080
in the browser on Raspberry Pi, you should see a map with planes.
Alternatively, you can start dump1090
in the interactive mode from the command line. To do this, first stop the running dump1090
service:
sudo /etc/init.d/dump1090.sh stop
Now start the dump1090
in the interactive mode:
~/dump1090/dump1090 --interactive --gain -10 --net --net-beast
You should be getting output like:
Hex Mode Sqwk Flight Alt Spd Hdg Lat Long Sig Msgs Ti|
-------------------------------------------------------------------------------
3C4B4C S 34000 470 344 5 39 1
44D076 S 25000 4 5 1
3C66B3 S 2037 DLH8YA 19475 339 121 48.916 11.190 4 27 5
040032 S 2540 ETH707 5875 273 119 49.905 8.698 8 113 0
3C6DCD S 7610 31000 465 108 4 12 1
44A8A2 S 1000 JAF83X 34625 454 292 5 130 2
710105 S 2702 SVA116 33000 510 125 49.382 7.167 4 156 1
...
Finally, start the dump1090
service again:
sudo /etc/init.d/dump1090.sh start
Just follow the steps mentioned here: https://opensky-network.org/community/projects/30-dump1090-feeder
Once you set everything up and entered your OpenSky username correctly, it'll show up in your receiver profile (My OpenSky > Receiver Profile).
- This guide is largely based on the ADS-B using dump1090 for the Raspberry Pi guide
- This guide uses RTL-SDR drivers from the osmocomSDR project
- We use the Malcolm Robb's fork of the
dump1090
software
This guide is published under the MIT license.