Tar1090 -- improved webinterface for dump1090-fa and readsb

Thanks for the shortcuts.

They perform a hard refresh of the webpage clearing its cache and data, equivalent to the long-winded Safari > Preferences > Privacy > Manage Website Data… method I described above

Much quicker.

EDIT: I found on my system I had to hold the shift key and click the refresh icon image

Yeah older Safari had it as Shift-Refresh, but Safari 14.0 uses that for switching to the Reader view.
Its under the View menu as Reload Page and if you hold the modifier it changes to Reload Page from Origin.
At least with it you won’t need to screwup all your tabs and history.

Have now updated to the latest commit ( a4c0dea ) and can confirm that changes to config.js are now reflected with a simple page refresh.

I needed an initial hard refresh for two Macs running Safari 14.0 and macOS 10.15.7, but not for Safari 14.0.1 on the iPad, Firefox 81.0.2 on one of the aforementioned Macs, a Mac running Safari 14.0.1 on macOS 11 beta or a Mac running Safari 13.1.2 on macOS 10.13.6

Also, I’m sure some people will be pleased to see the appearance of the Altitude Chart option in the latest commit. :slight_smile:

Thanks, John

Re-added by @vkirienko

Hello @wiedehopf.

I did my weekly update to the latest tar1090 commit earlier (e823d85 add KML layer for testing) and found that there seems to be a problem with the aircraft icons and type codes.

Sime twin prop aircraft are showing single engine icons, and others are shown as small twin jets. Some aircraft (including a B738) don’t have a Type at all, and display the generic icon.

I’ve tried “reload page from source” without success - there was also a considerable lag in populating the Type column after that refresh. I’ve just updated to the most recent commit (52273b6 tfr stuff still in testing, don’t show by default), without any improvement.

Is this likely to be a problem with my setup, or a more general issue?

Non-default webserver setup?
Database files are gzipped on disk, so the webserver must not compress them but add Content-Encodign: gzip, if it doesn’t the DB won’t load.
You’ll see with F12 in the console log.

This change is getting annoying … might consider reverting it. Let’s see how many more complaints …

Sorry, I’m probably being a bit slow…

I have not deliberately changed the web server setup, but who knows?

Here are the install listings from earlier - if you need the F12 console stuff you will need to give me a bit more of a step by step. (note I update using the wget -nv install line in the readme which is not the same as the wget -q setting under the Update (same command as installation), despite the heading :slightly_smiling_face:

jrg@raspi4:~ $ sudo bash -c "$(wget -nv -O - https://raw.githubusercontent.com/wiedehopf/tar1090/master/install.sh)"
2020-11-13 07:14:05 URL:https://raw.githubusercontent.com/wiedehopf/tar1090/master/install.sh [14414/14414] -> "-" [1]
[sudo] password for jrg: 
remote: Enumerating objects: 91, done.
remote: Counting objects: 100% (91/91), done.
remote: Compressing objects: 100% (35/35), done.
remote: Total 46 (delta 9), reused 46 (delta 9), pack-reused 0
Unpacking objects: 100% (46/46), done.
From https://github.com/wiedehopf/tar1090-db
 * branch            master     -> FETCH_HEAD
 + 37fd448...a5bd7dd master     -> origin/master  (forced update)
HEAD is now at a5bd7dd db update
remote: Enumerating objects: 82, done.
remote: Counting objects: 100% (82/82), done.
remote: Compressing objects: 100% (33/33), done.
remote: Total 72 (delta 54), reused 57 (delta 39), pack-reused 0
Unpacking objects: 100% (72/72), done.
From https://github.com/wiedehopf/tar1090
 * branch            master     -> FETCH_HEAD
   30456d6..e823d85  master     -> origin/master
HEAD is now at e823d85 add KML layer for testing
Restarting lighttpd ...
--------------
--------------
All done! Webinterface available at http://192.168.124.104/tar1090
All done! Webinterface available at http://192.168.124.104/persist
jrg@raspi4:~ $ sudo bash -c "$(wget -nv -O - https://raw.githubusercontent.com/wiedehopf/tar1090/master/install.sh)"
2020-11-13 10:07:47 URL:https://raw.githubusercontent.com/wiedehopf/tar1090/master/install.sh [14414/14414] -> "-" [1]
[sudo] password for jrg: 
remote: Total 0 (delta 0), reused 0 (delta 0), pack-reused 0
From https://github.com/wiedehopf/tar1090-db
 * branch            master     -> FETCH_HEAD
HEAD is now at a5bd7dd db update
remote: Enumerating objects: 9, done.
remote: Counting objects: 100% (9/9), done.
remote: Compressing objects: 100% (1/1), done.
remote: Total 5 (delta 4), reused 5 (delta 4), pack-reused 0
Unpacking objects: 100% (5/5), done.
From https://github.com/wiedehopf/tar1090
 * branch            master     -> FETCH_HEAD
   e823d85..52273b6  master     -> origin/master
HEAD is now at 52273b6 tfr stuff still in testing, don't show by default
Restarting lighttpd ...
--------------
--------------
All done! Webinterface available at http://192.168.124.104/tar1090
All done! Webinterface available at http://192.168.124.104/persist

Update - it is yet another MacOS/Safari issue.

I’ve just checked MacOS Firefox and Windows 10/Edge and the one (of 8 still in range here, it is are very quiet) aircraft that has an issue - a PA44 shows as a twin prop in those browsers, but a single engine in Safari.

Not that big an issue…

Then i’ll indeed have a look at the browser log please.

Google Safari browser log on how to pull it up, not sure if F12 works. (while visiting /tar1090)
When you have it open, reload the page.

my problem:
I updated tar1090
changed in config.js “// MapDim = true;” into “MapDim = false;”
but map is still dimmed; so I have manually to click on “B”
It worked with version of somewhen in August;
all other changes I made are OK

It does save it per browser.
Anyhow … the issue you described is now fixed.

Should the instructions for // selection lines of columns in /usr/local/share/tar1090/html/config.js
be removed since it now seems the columns are selected by the tab in the table side of the web interface screen?

My // selected columns seem to be ignored from the config.js … The web page column selections seems to control what is displayed.

Apologies for earlier irrelevant reply - I was thinking in terms of a console on the Pi, not my browser.

Here is a screenshot of the Safari JavaScript console after a page refresh - note there were no aircraft within range of the receiver (early Saturday morning here). Let me know if you need anything more.

They are not exactly ignored, they represent the default columns for new visitors.

Yeah so that’s an issue with lighttpd if you run that.

cat /etc/os-release
sudo journalctl --no-pager -u lighttpd
ls /etc/lighttpd/conf-enabled
grep mod_setenv /etc/lighttpd/ -rnT

Let’s check all of the above.
Or did you really say it worked in other browsers?
How old is that Safari?

Just installed on my both devices the latest release, i was still on the version of Oct 24th

This is really an awesome job. The interface is getting better and better with every relase.
Wondering if FA is already thinking to take it as official interface as a Skyview replacement :slight_smile:

Thanks @wiedehopf, good work

As requested:

jrg@raspi4:~ $ cat /etc/os-release
PRETTY_NAME="Raspbian GNU/Linux 10 (buster)"
NAME="Raspbian GNU/Linux"
VERSION_ID="10"
VERSION="10 (buster)"
VERSION_CODENAME=buster
ID=raspbian
ID_LIKE=debian
jrg@raspi4:~ $ sudo journalctl --no-pager -u lighttpd
-- Logs begin at Fri 2020-11-06 11:08:56 AEDT, end at Sat 2020-11-14 06:05:40 AEDT. --
Nov 06 11:09:00 raspi4 systemd[1]: Starting Lighttpd Daemon...
Nov 06 11:09:00 raspi4 systemd[1]: Started Lighttpd Daemon.
Nov 13 07:14:44 raspi4 systemd[1]: Stopping Lighttpd Daemon...
Nov 13 07:14:44 raspi4 systemd[1]: lighttpd.service: Succeeded.
Nov 13 07:14:44 raspi4 systemd[1]: Stopped Lighttpd Daemon.
Nov 13 07:14:44 raspi4 systemd[1]: Starting Lighttpd Daemon...
Nov 13 07:14:44 raspi4 lighttpd[2102]: 2020-11-13 07:14:44: (server.c.1493) WARNING: unknown config-key: deflate.mimetypes (ignored)
Nov 13 07:14:44 raspi4 systemd[1]: Started Lighttpd Daemon.
Nov 13 10:07:58 raspi4 systemd[1]: Stopping Lighttpd Daemon...
Nov 13 10:07:58 raspi4 systemd[1]: lighttpd.service: Succeeded.
Nov 13 10:07:58 raspi4 systemd[1]: Stopped Lighttpd Daemon.
Nov 13 10:07:58 raspi4 systemd[1]: Starting Lighttpd Daemon...
Nov 13 10:07:59 raspi4 lighttpd[12797]: 2020-11-13 10:07:58: (server.c.1493) WARNING: unknown config-key: deflate.mimetypes (ignored)
Nov 13 10:07:59 raspi4 systemd[1]: Started Lighttpd Daemon.

jrg@raspi4 : ~ $ ls -la /etc/lighttpd/conf-enabled

total 8

drwxr-xr-x 2 root root 4096 Nov 13 10:07 .

drwxr-xr-x 4 root root 4096 Nov 5 16:44

lrwxrwxrwx 1 root root 47 Oct 2 14:58 88-dump1090-fa-statcache.conf → …/conf-available/88-dump1090-fa-statcache.conf

lrwxrwxrwx 1 root root 47 Jul 19 14:52 88-graphs1090.conf → /etc/lighttpd/conf-available/88-graphs1090.conf

lrwxrwxrwx 1 root root 44 Nov 13 10:07 88-tar1090.conf → /etc/lighttpd/conf-available/88-tar1090.conf

lrwxrwxrwx 1 root root 52 Nov 13 10:07 88-tar1090-persist.conf → /etc/lighttpd/conf-available/88-tar1090-persist.conf

lrwxrwxrwx 1 root root 39 May 22 14:20 88-timelapse1090.conf → …/conf-available/88-timelapse1090.conf

lrwxrwxrwx 1 root root 37 Oct 2 14:58 89-dump1090-fa.conf → …/conf-available/89-dump1090-fa.conf

lrwxrwxrwx 1 root root 42 Feb 14 2020 90-javascript-alias.conf → …/conf-available/90-javascript-alias.conf

lrwxrwxrwx 1 root root 54 Nov 13 10:07 95-tar1090-otherport.conf → /etc/lighttpd/conf-available/95-tar1090-otherport.conf


jrg@raspi4 : ~ $ grep mod_setenv /etc/lighttpd/ -rnT

/etc/lighttpd/conf-available/87-mod_setenv.conf: 1: server.modules += ( " mod_setenv " )

/etc/lighttpd/conf-available/89-dump1090-fa.conf: 42: server.modules += ( " mod_setenv " )

(Sorry I've got myself caught in quote format and can't escape! - will post a second reply with the rest...)

Yes - I’ve checked using Windows 10/ Edge Browser - here is that console log:

My Safari version is Version 14.0 (15610.1.28.1.9, 15610) which is current.

Hope this helps.

lighttpd -tt -f /etc/lighttpd/lighttpd.conf

That’s strange … seems lighttpd isn’t properly producing the error that i need to detect …
I suppose i can work around that -.-

@wiedehopf
Thank you for the update, works perfectly.

Totally agree with @foxhunter:
Wondering if FA is already thinking to take it as official interface as a Skyview