Skip to content

Commit

Permalink
upintheair simplifications
Browse files Browse the repository at this point in the history
  • Loading branch information
wiedehopf committed Aug 6, 2021
1 parent 4caf272 commit 5e9fb78
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 2 deletions.
10 changes: 9 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -298,12 +298,20 @@ To judge the actual range (/?pTracks, see next chapter), one needs to first know
- Near the top of the page, an URL for the panorama is mentioned.
- Replace the XXXXXX in the following command with the ID contained in your panorama URL, then run the command on your pi:
```
sudo wget -nv -O /usr/local/share/tar1090/html/upintheair.json "http://www.heywhatsthat.com/api/upintheair.json?id=XXXXXXXX&refraction=0.25&alts=12192"
sudo /usr/local/share/tar1090/getupintheair.sh XXXXX
```
- You should now have a range outline for the theoretical range for aircraft at 40000 ft on your tar1090 map

- It might be interesting to compare to http://192.168.x.yy/tar1090/?pTracks which will by default will display the last 8 hours of traces.

- More options for loading multiple outlines and for a different instance
```
# load two outlines, 10000 ft and 40000 ft
sudo /usr/local/share/tar1090/getupintheair.sh XXXXX 3048,12192
# load a 10000 ft outline for the tar1090 instance located at /978
sudo /usr/local/share/tar1090/getupintheair.sh XXXXX 3048 978
```

## /tar1090/?pTracks

![Screenshot2](https://raw.githubusercontent.com/wiedehopf/tar1090/screenshots/screenshot4.png)
Expand Down
22 changes: 22 additions & 0 deletions getupintheair.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
#!/bin/bash

ID="$1"

if [[ -z $1 ]]; then
echo "no ID supplied"
exit
fi

ALTS="12192"
if [[ -n $2 ]]; then
ALTS="$2"
fi

instance=tar1090
if [[ -n $3 ]]; then
instance="tar1090-$3"
fi


wget -nv -O "/usr/local/share/${instance}/html/upintheair.json" "http://www.heywhatsthat.com/api/upintheair.json?id=${ID}&refraction=0.25&alts=${ALTS}"

2 changes: 1 addition & 1 deletion install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ fi


# copy over base files
cp install.sh uninstall.sh LICENSE README.md $ipath
cp install.sh uninstall.sh getupintheair.sh LICENSE README.md $ipath
cp default $ipath/example_config_dont_edit
rm -f $ipath/default

Expand Down

0 comments on commit 5e9fb78

Please sign in to comment.