dump1090 icon indicating copy to clipboard operation
dump1090 copied to clipboard

Add range outline on skyaware map with configurable retention history

Open cartpauj opened this issue 3 months ago • 1 comments

Range Outline with Altitude-Based Gradient Visualization This PR adds a new Range Outline feature that visualizes the maximum detection range of your ADS-B receiver across all bearings (0-359°), with altitude-based color gradients showing your coverage profile.

What it does

  • Tracks maximum range at each degree bearing from the receiver
  • Displays altitude-colored outline on the map using the existing altitude color scale
  • Creates smooth gradients between adjacent bearings for visual continuity
  • Persists data across restarts with configurable retention period
  • Adapts dynamically as aircraft are tracked, expanding outward from the receiver location

Visual Example The outline starts as a small circle at your receiver location and gradually expands as aircraft are detected. Each segment is colored according to the altitude of the aircraft at maximum range for that bearing:

  • Purple/magenta for high-altitude aircraft (35,000+ ft)
  • Blue/cyan for medium altitude (15,000-30,000 ft)
  • Green/yellow for lower altitude (below 15,000 ft)

Configuration New command-line option: --range-outline-retention <hours> # Default: 24 hours

Example: ./dump1090 --lat 42.67 --lon -113.87 --range-outline-retention 48

UI Controls

  • Toggle via checkbox in the web interface settings panel
  • State persists across browser sessions
  • Works alongside existing site circles and range rings

Technical Details Backend (C):

  • Tracks range, timestamp, and altitude for each of 360 bearings
  • Prefers barometric altitude, falls back to geometric
  • Binary persistence format with automatic save every 60 seconds
  • JSON API endpoint: data/range_outline.json

Frontend (JavaScript):

  • 360 individual line segments with altitude-based coloring
  • Uses existing getAltitudeColor() function for consistency
  • Smooth color gradients between adjacent bearings
  • Always displays complete circle (small radius for bearings without data)

Files Modified

  • dump1090.h - Data structures
  • dump1090.c - Persistence and configuration
  • track.c - Range/altitude tracking
  • net_io.c - JSON generation
  • public_html/script.js - Visualization
  • public_html/index.html - UI controls

Documentation Complete documentation in RANGE_OUTLINE.md including:

  • Technical implementation details
  • Configuration options
  • Troubleshooting guide
  • Design decisions

cartpauj avatar Oct 14 '25 13:10 cartpauj