Find a file
nathan 5d6aa0e398 removed profiling files and changed gitignore for shp and geojson files
Former-commit-id: 80e12805b0dc79841b0996f11f28b53e50a590f7
Former-commit-id: 21a1e822e1596cecb779edbb0b788732c1d5131a
2020-06-17 22:12:23 -07:00
font map conversion in python directly from svg to c array bin file, with bash script. File cleanup (BFG to follow) 2020-03-01 21:17:12 -08:00
.DS_Store builds and runs 2020-03-10 16:56:59 -07:00
.gitignore removed profiling files and changed gitignore for shp and geojson files 2020-06-17 22:12:23 -07:00
0.geojson.REMOVED.git-id removing profiling files 2020-06-17 22:09:53 -07:00
1.geojson.REMOVED.git-id removing profiling files 2020-06-17 22:09:53 -07:00
3.geojson.REMOVED.git-id removing profiling files 2020-06-17 22:09:53 -07:00
Aircraft.cpp fixed more warnings and Makefile issues. Should compile on mac now 2020-06-16 21:50:41 -07:00
Aircraft.h fixed std:chrono issues 2020-06-14 15:26:26 -07:00
AircraftList.cpp fixed more warnings and Makefile issues. Should compile on mac now 2020-06-16 21:50:41 -07:00
AircraftList.h more c cleanup and label physics adjustments 2020-03-20 22:08:40 -07:00
anet.c fixed more warnings and Makefile issues. Should compile on mac now 2020-06-16 21:50:41 -07:00
anet.h fixed more warnings and Makefile issues. Should compile on mac now 2020-06-16 21:50:41 -07:00
AppData.cpp fixed more warnings and Makefile issues. Should compile on mac now 2020-06-16 21:50:41 -07:00
AppData.h more c cleanup and label physics adjustments 2020-03-20 22:08:40 -07:00
dump1090.h fixed more warnings and Makefile issues. Should compile on mac now 2020-06-16 21:50:41 -07:00
getmap.sh updating readme for WSL support 2020-06-08 11:49:58 -07:00
Input.cpp fixed std:chrono issues 2020-06-14 15:26:26 -07:00
Input.h fixed std:chrono issues 2020-06-14 15:26:26 -07:00
interactive.c massive refactor to c++ in progress, doesn't build now 2020-03-07 17:22:20 -08:00
magma.h directory cleanup of old hw stuff (retained in subdir 2019-09-08 15:06:42 -05:00
Makefile fixed more warnings and Makefile issues. Should compile on mac now 2020-06-16 21:50:41 -07:00
Map.cpp fixed ms clock issue using steady_clock -> high_resolution_clock. Changed line drawing to recursive instead of building line list in Map.cpp, seems to be a lot faster. 2020-06-13 22:15:47 -07:00
Map.h testing hard coded multipliers for latlon conversion and different quadtree filling logic 2020-06-13 20:54:21 -07:00
mapconverter.py added resolution argument to mapconverter 2020-06-16 21:50:58 -07:00
mode_ac.c directory cleanup of old hw stuff (retained in subdir 2019-09-08 15:06:42 -05:00
mode_s.c fixed more warnings and Makefile issues. Should compile on mac now 2020-06-16 21:50:41 -07:00
monokai.c directory cleanup of old hw stuff (retained in subdir 2019-09-08 15:06:42 -05:00
monokai.h removed defs.h and structs.h 2020-03-18 22:38:00 -07:00
ne_10m_admin_0_boundary_lines_land.shp.REMOVED.git-id removing profiling files 2020-06-17 22:09:53 -07:00
ne_10m_admin_0_boundary_lines_land.shp:Zone.Identifier removing profiling files 2020-06-17 22:09:53 -07:00
ne_10m_admin_0_boundary_lines_land.shx removing profiling files 2020-06-17 22:09:53 -07:00
ne_10m_admin_0_boundary_lines_land.shx:Zone.Identifier removing profiling files 2020-06-17 22:09:53 -07:00
ne_10m_admin_1_states_provinces_lines.shp.REMOVED.git-id removing profiling files 2020-06-17 22:09:53 -07:00
ne_10m_admin_1_states_provinces_lines.shp:Zone.Identifier removing profiling files 2020-06-17 22:09:53 -07:00
ne_10m_admin_1_states_provinces_lines.shx.REMOVED.git-id removing profiling files 2020-06-17 22:09:53 -07:00
ne_10m_admin_1_states_provinces_lines.shx:Zone.Identifier removing profiling files 2020-06-17 22:09:53 -07:00
ne_10m_coastline.shp.REMOVED.git-id removing profiling files 2020-06-17 22:09:53 -07:00
ne_10m_coastline.shp:Zone.Identifier removing profiling files 2020-06-17 22:09:53 -07:00
ne_10m_coastline.shx removing profiling files 2020-06-17 22:09:53 -07:00
ne_10m_coastline.shx:Zone.Identifier removing profiling files 2020-06-17 22:09:53 -07:00
ne_10m_land.svg:Zone.Identifier removing profiling files 2020-06-17 22:09:53 -07:00
net_io.c massive refactor to c++ in progress, doesn't build now 2020-03-07 17:22:20 -08:00
parula.c directory cleanup of old hw stuff (retained in subdir 2019-09-08 15:06:42 -05:00
parula.h begin conversion to c++. modified existing c files to compile with g++ 2020-03-07 13:19:49 -08:00
README.md moved drawtrails into map redraw logic for faster refresh when trails are long 2020-06-17 22:01:18 -07:00
run_viz1090.sh more Readme edits and file cleanup 2020-06-08 15:57:11 -07:00
test.geojson.REMOVED.git-id removing profiling files 2020-06-17 22:09:53 -07:00
View.cpp moved drawtrails into map redraw logic for faster refresh when trails are long 2020-06-17 22:01:18 -07:00
View.h moved drawtrails into map redraw logic for faster refresh when trails are long 2020-06-17 22:01:18 -07:00
view1090.h directory cleanup of old hw stuff (retained in subdir 2019-09-08 15:06:42 -05:00
viz1090.cpp map convert precision change. fixed map load issue. changed time functions to std::chrono 2020-06-11 21:55:04 -07:00

viz1090

This is work in progress There are a lot of missing pieces in this implementation so far:

  • A proper map system yet. Eventually map data should be pulled from Mapbox or similar.
  • In-application menus or configuration yet.
  • Theming/colormaps (important as this is primarily intended to be eye candy!)
  • Integration with handheld features like GPS, battery monitors, buttons/dials, etc.
  • Android build is currently broken

BUILDING

Tested and working on Ubuntu 18.04, Raspbian Stretch / Buster, Windows Subsystem for Linux (with Ubuntu 18.04), and Mac

  1. Install build essentials
sudo apt-get install build-essential
  1. Install SDL and RTL-SDR libararies
sudo apt-get install libsdl2-dev libsdl2-ttf-dev libsdl2-gfx-dev librtlsdr-dev

Note: On Raspbian the SDL2 package requires X to be running. See the Raspberry Pi section for notes on running from the terminal and other improvements.

  1. Download and build spidr
cd ~
git clone https://www.github.com/nmatsuda/spidr
cd spidr
make clean; make
  1. Download and process map data Until more comprehensive map source (e.g., Mapbox) is integrated, viz1090 uses the lat/lon SVG files from https://www.mccurley.org

The getmap.sh pulls the large SVG file for the contiguous 48 US states and produces a binary file for viz1090 to read.

sudo apt install python3 python3-pip
pip3 install lxml numpy tqdm
./getmap.sh

There is also a world map avaiable from McCurley (https://mccurley.org/svg/data/World.svgz), which is much lower resolution and thus better for lower power hardware.

The mapconverter script called by getmap.sh downsamples the file to render resonably quickly on a Raspberri Pi 4. If you are on a slower device (e.g, a Raspberry Pi 3), you may want to try something like:

python3 mapconverter.py --resolution 64 all.svg

On the other hand, if you are on a modern desktop or laptop, you can use something higher (but you probably don't need the full 6 digit precision of the McCurley SVG file):

python3 mapconverter.py --resolution 8192 all.svg
  1. (Windows only)

As WSL does not have an X server built in, you will need to install a 3rd party X server, such as https://sourceforge.net/projects/vcxsrv/

* run Xlaunch from the start menu
* Uncheck "Use Native openGL"
* Open the Ubuntu WSL terminal
* Specify the X display to use
```
export DISPLAY=:0
```
* Start viz1090 as described below.

RUNNING

  1. Start dump1090 (http://www.github.com/MalcolmRobb/dump1090) locally in network mode:
dump1090 --net
  1. Run viz1090
./viz1090 --fullsceen --lat [your latitude] --lon [your longitude]

viz1090 will open an SDL window set to the resolution of your screen.

RUNTIME OPTIONS

Argument Description
--server [domain name or ip] Specify a dump1090 server
--port [port number] Specify dump1090 server port
--metric Display metric units
--lat Specify your latitude in degrees
--lon Specify your longitiude in degrees
--screensize [width] [height] Specify a resolution, otherwise use resolution of display
--uiscale [scale] Scale up UI elements by integer amounts for high resolution screen
--fullscreen Render fullscreen rather than in a window

HARDWARE NOTES

This software was originally intended for Raspberry Pi devices, and it is currently optimized for the Raspberry Pi 4 with the following configuration:

If running as a front end only, with a separate dump1090 server, the best option is to use an Android phone, such as the Pixel 2, which significantly outperforms a Raspberry Pi 4.

viz1090 has been tested on other boards such as the UP Core and UP Squared, but these boards have poor performance compared to a Raspberry Pi 4, along with worse software and peripheral support, so they are not recommended. viz1090 with a low resolution map will run on these boards or even a Raspberry Pi Zero, so these remain options with some tradeoffs.

Of course, a variety of other devices work well for this purpose - all of the development so far has been done on a touchscreen Dell XPS laptop.

Credits

viz1090 is largely based on dump1090 (Malcom Robb, Salvatore Sanfilippo)