Radar scope view for your ADSB data

While working on a scope view for an ESP32 display and decided to just make it a single html page you that can be dropped into a tar1090/dump1090-fa folder after minimal config.

This is an initial release, there are bugs and undocumented features that may trigger on live data events and crash the page. It may not work with every feeder setup in its current state. The next release should remove configuration needs for most feeder setups.

Quick tip:
Putting adsb-radar.html on your feeder in a directory accessible through a browser = :smiley:

Simply opening adsb-radar.html on your desktop = :sob:

Live Demo: https://www.youtube.com/watch?v=7APCgx_lYsY
Live stream will be occasionally down and you may see it running future versions.

4 Likes

That’s pretty slick, thanks!

I installed it first on my laptop & had to enable a CORS extension my browser to get it to work. I’ll move it over to my Pi eventually, but can’t be bothered right now…

@tritium

I do NOT have tar1090. I have only dump1090-fa with Skyaware map.

All your config instruction are tar1090 specific, nothing for dump1090-fa, although there is a difference between the two.

(1) The /usr/share/dump1090-fa folder does NOT contain an html folder. As such I drpped your file adsb-scope.html in folder /usr/share/skyaware/html/

(2) In case of tar1090, the json file location is tar1090/data/aircraft.json. In case of dump1090-fa, the location is /run/dump1090-fa/aircraft.json. In configuration, I used

const TAR1090_URL = "/run/dump1090-fa/aircraft.json"

However in spite of this, your page in browser failed to display at following address:

192.168.12.24/skyaware/adsb-radar.html

There must be something wrong withe configuration I used. Can you please give details of how to configure adsb-scope.html when there is No tar1090 installed, and only dump1090-fa with skyaware map is available. Thank you.

Required:
(1) Exactly in which of the following folders your file adsb-scope.htnl is to be dropped:

  • `/usr/share/dump1090-fa
  • /usr/share/skyaware/html
  • Any other folder (please specify full path)

(2) What value for const TAR1090_URL shold be set in case if no tar1090 is installed.

(3) Full url to be used to display adsb-radar.html in a browser on a computer on same local netwok

1 Like

On a setup where you’re using a browser on a desktop computer and the pi is on the local network, I think you put the file adsb-radar.html on the desktop computer that has the browser. Then just double click on it and the browser is launched. I least it is with Safari on a Mac.

I edited adsb-radar.html as:

const TAR1090_URL = “http://[ip of pi]/run/dump1090-fa/aircraft.json”

and also added location, and launched the browser as above. Unfortunately all I got was the user interface with the sweeping radar scope but no aircraft.

I noticed in the Github readme it has the following caution:

“If the data source is on a different domain, you may encounter CORS (Cross-Origin Resource Sharing) errors and only the UI will load. The server hosting aircraft.json must be configured to allow requests from the domain where you are viewing adsb-scope.html to load the data from the json file.”

Doesn’t that mean the server on the pi (usually lighttpd) has to be reconfigured for this to work?

Edit to add: I guess adsb-scope.html is the same adsb-radar.html.

1 Like

I do NOT have tar1090. I have only dump1090-fa with Skyaware map.

Easy solution:

sudo bash -c “$(wget -nv -O - ``https://github.com/wiedehopf/tar1090/raw/master/install.sh``)”

On a setup where you’re using a browser on a desktop computer and the pi is on the local network, I think you put the file adsb-radar.html on the desktop computer that has the browser. Then just double click on it and the browser is launched.

The html file needs to be on the same device running the feeder or you’ll CORS will block it. Or you can try the CORS chrome extension https://chromewebstore.google.com/detail/lhobafahddgcelffkeicbaginigeejlf?utm_source=item-share-cb

You could just get the lat lon from receiver.json to be found in the same directory as aircraft.json.

Then you can give this instruction:

wget https://raw.githubusercontent.com/dustsignal/adsb-radarscope/refs/heads/main/adsb-radar.html -O /usr/local/share/tar1090/html/adsb-radar.html

Which will provide a working interface without further config at:

http://192.168.2.16/tar1090/adsb-radar.html

On whichever IP of course.

Just preventing further inquiries you will get.
Or you could provide similar instructions to load it into the skyaware html directory :slight_smile:
That way it doesn’t need tar1090 for those that don’t have it.
The receiver.json will have lat lon the same.

@abcd567 if you drop it in the tar1090 or skyaware html directory, you don’t need to change the aircraft.json it comes with by default.

Thanks for the suggestions. Having the code automatically look for known locations of aircraft.json and feeder lat/lon will be in the next version.

Not sure if this is bug in the html or my browser acting weird, but when I click on one of the aircraft “blips”, I get a tooltip kind of popup that shows all of the message data for that plane.

This works great if the one that I click on is in the upper 2/3 of my screen. For any flight near the bottom, the tooltip extends below the bottom of the display and I can’t see a way to move it or scroll in such a way that I can see all of the content.

It seems to be that the popup is always to the lower right of the cursor - even if there is no screen available to display there.

That popup was a late night addition, will be fixed in the next release.

1 Like

Sorry, I am not interested in installing tar1090.
Give me a solution without installing tar1090

1 Like

Ok I tried putting adsb-radar.html on the pi. I edited adsb-radar.html as follows:

const TAR1090_URL = “/run/dump1090-fa/aircraft.json”;

and added in HOME_LAT and HOME_LON values.

I put adsb-radar.html file in /usr/share/skyaware/html directory.

I launched web browser to URL http://192.168.xx.yy/skyaware/adsb-radar.html

where 192.168.xx.yy is IP of pi. I still don’t see aircraft. Just shows the user interface for the radar scope. Any suggestions? Thanks.

@jimMerk2
Please see my yesterday’s post. This is exactly what I did yesterday, and got a radarscreen on 192.168.12.24/skyaware/adsb-radar.html with rotating green line, but no planes. It seems system is not allowing the adsb-radar.html to pull aircraft.json from folder /run/dump1090-fa/

1 Like

@jimMerk2
@tritium

OK solved by using following setting. Now the radar screen is populated by aircraft.

const TAR1090_URL = "/skyaware/data/aircraft.json";

The file adsb-radar.html is in folder /usr/share/skyaware/html

 

Adress in browser of Phone:
192.168.12.24/skyaware/adsb-radar.html (192.168.12.24 is local IP of RPi)

 

 

1 Like

You’re right, that works.

I don’t understand why it works, but thanks.

Edit to add: I see /skyaware/data/aircraft.json was shown as the data source in the @tritium GitHub Readme.

1 Like

@jimMerk2
I did not find it yesterday when I browsed @tritium’s Github site. Either I missed it or it was added later. Even when I posted my settings and requested @tritium to tell me where I made mistake, he did not tell me the correct setting, instead proposed to install tar1090.

Only 4 hrs ago, I found it by studying the file /etc/lighttpd/conf-enabled/89-skyaware.conf , where under CORS Header (Cross-Origin Resource Sharing) it was clear. Please see screenshot below

Click on Screenshot to See Larger Size

 

Thanks I was wondering where the url skyaware/data/aircraft.json was defined. I see just above the part you showed it has an alias defined:

alias.url += (
“/skyaware/data/” => “/run/dump1090-fa/”,
“/skyaware/data-978/” => “/run/skyaware978/”,
“/skyaware/” => “/usr/share/skyaware/html/”
)

Edit to add: I only vaguely understand lighttpd. I haven’t really found a tutorial to explain it.

1 Like

By the way, Radar scope also works fine if you have the adsb-radar.html file on your laptop/desktop machine with the feeder on your local network. Just use full url to the feeder (usually pi) for const TAR1090_URL in adsb-radar.html as it says in the GitHub readme. There doesn’t seem to be any problem with CORS (at least on a Mac using Safari browser). YMMV with other browsers.

2 Likes

@jimMerk2

(1) On my Windows 11 Desktop, the local drop-in file adsb-radar.htmldoes not work either on Firefox or Google Chrome. No aircraft, and no rotating green line. The Desktop and Pi are on Same local network, and I have used full path:

const TAR1090_URL = "http://192.168.12.24/skyaware/data/aircraft.json";

(1) On my Android Phone, when on same WiFi as RPi, the local drop-in file `adsb-radar.html with above noted TAR1090_URL, does WORK OK on default browser (Samsung), Firefox and Google Chrome at following address:

http://127.0.0.1:14699/main/0/storage/emulated/0/Download/adsb-radar.html

All aircraft, and rotating green line both are shown.

Click on Screenshot to See Larger Size
Click Again to See Full Size

 

1 Like

That seems strange that you don’t even see the animated window.

For my mobile device (iPhone), I’ll have to charge it up and try it. Shows how little I use it.

1 Like