1090-to-owntracks

Import ADS-B data into OwnTracks via MQTT

Stars
12

1090-to-owntracks

This small program slurps the data from aircraft.json as produced by tedsluis/dump1090 which is a Mode S decoder for RTLSDR devices.

Data is published to the MQTT topic ot/flights/<flightnumber> in OwnTracks-compatible JSON:

{
  "tst": 1474648272,
  "cog": 134,
  "lon": 6.658383,
  "_type": "location",
  "flight": "KLM1963",
  "roc": 0,
  "lat": 51.381042,
  "_geoprec": 2,
  "alt": 10058,
  "vel": 877,
  "name": "KLM1963"
}

Hardware

My Rpi

I bought this dongle and simply plugged it in.

$ lsusb
Bus 001 Device 004: ID 0bda:2838 Realtek Semiconductor Corp. RTL2838 DVB-T

$ cat /etc/modprobe.d/no-rtl.conf
blacklist dvb_usb_rtl28xxu
blacklist rtl2832
blacklist rtl2830

$ ./dump1090 --interactive --metric --net --net-beast --net-bind-address 0.0.0.0 --write-json /tmp/air/ --json-location-accuracy 2