| 10925 | @app.route('/adsb-radar') |
| 10926 | def adsb_radar_page(): |
| 10927 | """Serve the ADS-B radar screen (live aircraft at 1090 MHz via dump1090). |
| 10928 | |
| 10929 | Served when any SDR is present (so the page can offer its Install-dump1090 |
| 10930 | button even before dump1090 exists), when dump1090 itself is ready, or when |
| 10931 | the RF Waterfall demo toggle (``sdr_demo`` / ``RAGNAR_SDR_DEMO``) is on (the |
| 10932 | page then shows a synthetic sky). 404s otherwise. Login required. |
| 10933 | """ |
| 10934 | env = os.environ.get('RAGNAR_SDR_DEMO', '').strip().lower() |
| 10935 | demo = bool(shared_data.config.get('sdr_demo')) or env in ('1', 'true', 'yes', 'on') |
| 10936 | # Serve whenever an SDR is present (even without dump1090) so the page can |