Real-time aircraft tracking using 1090 MHz Mode S transponder signals with RTL-SDR devices.
This project provides a comprehensive ADS-B (Automatic Dependent Surveillance-Broadcast) aircraft tracking system that:
- Tracks aircraft in real-time using 1090 MHz Mode S transponder signals
- Displays aircraft positions on an interactive map with live updates
- Shows aircraft details including callsign, altitude, speed, heading, and vertical rate
- Provides signal analysis tools for debugging and optimization
- Supports automatic gain control for optimal signal reception
- Real-time aircraft tracking at 1090 MHz
- Mode S transponder decoding with CRC-24 verification
- Aircraft identification (ICAO addresses, callsigns)
- Position tracking (latitude/longitude, altitude)
- Flight data (speed, heading, vertical rate)
- Live map display with aircraft positions
- Statistics panel with tracking information
- Advanced preamble detection using signal correlation
- Dynamic thresholding based on signal percentiles
- Noise reduction with moving average filtering
- Automatic gain control for optimal signal resolution
- Multiple message type support (DF=17/18 ADS-B Extended Squitter)
- Comprehensive debug logging to console and file
- Signal strength analysis and threshold optimization
- Message decoding statistics with success rates
- Signal analyzer for antenna and gain optimization
- Bit-level debugging for troubleshooting reception issues
- RTL-SDR USB dongle (RTL2832U + R820T/R820T2/R828D tuner)
- Frequency range covering 1090 MHz
- Recommended models: RTL-SDR Blog V3/V4, NooElec NESDR
- 1090 MHz antenna (quarter-wave ~6.8cm or specialized ADS-B antenna)
- Good line of sight for aircraft reception
- Proper grounding and impedance matching recommended
- Python 3.10+
- USB 2.0/3.0 port for RTL-SDR device
- 4GB+ RAM recommended for real-time processing
- Linux/macOS/Windows (tested on macOS)
# Install RTL-SDR drivers (macOS with Homebrew)
brew install librtlsdr
# Or on Ubuntu/Debian
sudo apt-get install rtl-sdr librtlsdr-dev
# Or on Windows - use Zadig to install WinUSB drivers
# Clone the repository
git clone <repository-url>
cd adsb-aircraft-tracker
# Install with Poetry (recommended)
poetry install
poetry shell
# Or with pip
pip install pyrtlsdr numpy matplotlib scipy
# Start the ADS-B aircraft tracker
poetry run python adsb_scanner.py
# Or with debug logging
poetry run python adsb_scanner.py --debug
# With custom gain setting
poetry run python adsb_scanner.py --gain 30.0
# Using convenience script
./run_adsb_scan.sh
# Analyze signal quality and find optimal settings
poetry run python adsb_signal_analyzer.py
This tool will:
- Test antenna connection
- Find optimal gain settings
- Analyze spectrum around 1090 MHz
- Detect ADS-B activity
- Provide specific recommendations
# Find optimal signal threshold
poetry run python find_optimal_threshold.py
# Quick signal quality test
poetry run python test_adsb_simple.py
# Focused signal debugging
poetry run python debug_adsb_signals.py
# Bit inversion testing
poetry run python test_bit_inversion.py
python adsb_scanner.py [options]
Options:
--sample-rate RATE Sample rate in MHz (default: 2.0)
--device-index INDEX RTL-SDR device index (default: 0)
--gain GAIN SDR gain in dB or "auto" (default: auto)
--debug Enable detailed debug logging
--help Show help message
- Aircraft positions plotted on interactive map
- Aircraft labels showing callsign/ICAO and altitude
- Live updates as aircraft move
- Zoom and pan capabilities
- Total/valid message counts and success rates
- Active aircraft count and details
- Recent aircraft list with last seen times
- Signal strength indicators
- Start/Stop scanning
- Clear aircraft database
- Real-time updates every 2 seconds
When --debug
is enabled, detailed information is logged to:
- Console output for real-time monitoring
- adsb_debug.log file for detailed analysis
Debug information includes:
- Signal strength and threshold analysis
- Preamble detection details
- Message decoding attempts
- CRC validation results
- Aircraft tracking updates
- Check signal analyzer output - run
adsb_signal_analyzer.py
- Verify antenna connection - should see power increase with gain
- Check for ADS-B activity - use flight tracking websites
- Try different gain settings - automatic gain usually works best
- Improve antenna placement - higher elevation, clear line of sight
- Use automatic gain control -
--gain auto
(default) - Check antenna connection and impedance matching
- Reduce interference - move away from electronics
- Improve antenna - use dedicated 1090 MHz ADS-B antenna
- Check signal strength - should see strong signals in analyzer
- Verify threshold settings - use
find_optimal_threshold.py
- Check for quantization - automatic gain helps
- Antenna issues - poor connection can cause bit errors
- Frequency: 1090 MHz
- Modulation: Pulse Position Modulation (PPM)
- Message types: DF=17/18 Extended Squitter
- Data rate: 1 Mbps
- Message length: 112 bits (short) or 224 bits (long)
- Sample rate: 2 MHz (configurable)
- Preamble detection: Mode S pattern correlation
- Bit extraction: Multi-point sampling with maximum detection
- Threshold: 99th percentile adaptive thresholding
- CRC validation: CRC-24 polynomial verification
- Aircraft identification: Callsign extraction from Type 1-4 messages
- Position decoding: CPR (Compact Position Reporting) format
- Velocity decoding: Ground speed and heading calculation
- Altitude decoding: Barometric and GNSS altitude
adsb_scanner.py
- Main ADS-B aircraft tracker with GUIrun_adsb_scan.sh
- Convenience script for easy startup
adsb_signal_analyzer.py
- Comprehensive signal analysisfind_optimal_threshold.py
- Signal threshold optimizationdebug_adsb_signals.py
- Focused debugging tooltest_adsb_simple.py
- Simple signal quality testtest_bit_inversion.py
- Bit inversion testing
test_adsb.py
- Comprehensive test suite
adsb_debug.log
- Debug output log (generated during operation)
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests if applicable
- Submit a pull request
This project is licensed under the MIT License - see the LICENSE file for details.
- RTL-SDR community for hardware support
- ADS-B protocol specifications
- Open source SDR software ecosystem