ADS-B, or automatic dependent surveillance – broadcast, is used by commercial airplanes to broadcast their latitude and longitude along with other information to the air traffic controller. This information is transmitted at 1090MHz. ADS-B signals can be received using RTL-SDR dongle and decoded using software. In this project we use dump1090 program or command line to decode ADS-B signals on Linux machine and create an Aircraft Signal Receiver. Apart from decoding ADS-B signals, dump1090 program also creates a Google Maps Web server where it displays the locations of airplanes whose ADS-B signals are being received.
Tools required for the setup
Tools required are laptop or computer running Linux/Ubuntu (preferably Ubuntu 14.04 and above), RTL-SDR dongle, antenna and dump1090 program installed on Ubuntu operating system (OS).
Installation of dump1090
Download dump1090 using the given link below.
Open the terminal and go to folder where dump1090 is saved. For installing it, type ‘make’ and press Enter, to install dump1090 on the computer.
Next, install rtl-sdr library by using the following command:
$ sudo apt-get install librtlsdr-dev
To test the hardware, plug in RTL-SDR dongle to the Linux machine and run the following command on the terminal:
$ ./rtl_test -t
If everything is working fine, you will get an output similar to the following:
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
[R82XX] PLL not locked!
Sampling at 2048000 S/s.
No E4000 tuner found, aborting.
To use dump1090, refer to its manual for various commands and functions. For that, run the command given below.
$ ./dump1090 –help
A brief manual of dump1090 is given below.
| dump1090 ModeS Receiver Ver : 1.07.1908.13 |
–device-index Select RTL device (default: 0)
–gain Set gain (default: max gain. Use -100 for auto-gain)
–enable-agc Enable the Automatic Gain Control (default: off)
–freq Set frequency (default: 1090 Mhz)
–ifile Read data from file (use ‘-’ for stdin)
–interactive Interactive mode refreshing data on screen
–interactive-rows Max number of rows in interactive mode (default: 15)
–interactive-ttl Remove from list if idle for (default: 60)
–interactive-rtl1090 Display flight table in RTL1090 format
–raw Show only messages hex values
–net Enable networking
–modeac Enable decoding of SSR Modes 3/A & 3/C
–net-beast TCP raw output in Beast binary format
–net-only Enable just networking, no RTL device or file used
–net-http-port HTTP server port (default: 8080)
–net-ri-port TCP raw input listen port (default: 30001)
–net-ro-port TCP raw output listen port (default: 30002)
–net-sbs-port TCP BaseStation output listen port (default: 30003)
–net-bi-port TCP Beast input listen port (default: 30004)
–net-bo-port TCP Beast output listen port (default: 30005)
–net-ro-size TCP raw output minimum size (default: 0)
–net-ro-rate TCP raw output memory flush rate (default: 0)
–lat Reference/receiver latitide for surface posn (opt)
—lon Reference/receiver longitude for surface posn (opt)
–fix Enable single-bits error correction using CRC
–no-fix Disable single-bits error correction using CRC
–no-crc-check Disable messages with broken CRC (discouraged)
–phase-enhance Enable phase enhancement
–aggressive More CPU for more messages (two bits fixes, …)
–mlat display raw messages in Beast ascii mode
–stats With –ifile print stats at exit. No other output
–onlyaddr Show only ICAO addresses (testing purposes)
–metric Use metric units (meters, km/h, …)
–snip Strip IQ file removing samples < level
–debug Debug mode (verbose), see README for details
–quiet Disable output to stdout. Use for daemon applications
–ppm Set receiver error in parts per million (default 0)
–help Show this help
Debug mode flags: d = Log frames decoded with errors
D = Log frames decoded with zero errors
c = Log frames with bad CRC
C = Log frames with good CRC
p = Log frames with bad preamble
n = Log network debugging info
j = Log frames to frames.js, loadable by debug.html
Using this manual, an interactive session can be carried out to view incoming decoded ADS-B signals from the airplanes in a tabular format. For that, type ‘–interactive’ as one of the commands on the terminal.
Apart from receiving decoded information from ADS-B signals, plot and see it graphically on a map. To do so, type the argument ‘–net’ on the terminal. This will create a Google Maps Web server on which the points where the airplanes are located can be plotted using the data from dump1090.
Enter the following command:
$ ./dump1090 –interactive –net
The following will appear on the terminal:
Hex Mode Sqwk Flight Alt Spd Hdg Lat Long Sig Msgs Ti|
On the browser go to http://localhost:8080. All nearby airplanes will appear on Google Maps, along with other relevant data such as latitude, longitude and altitude.
A screenshot of Google Maps captured during testing is shown in Fig. 2.
Varun Kumar is an electronics hobbyist and a circuit designer. His interests include wireless communication and computer programming