Giter Club home page Giter Club logo

piawaredump1090wrapper's Introduction

PiAware and DUMP1090 Python Request wrapper

Application is still in testing and development. If you have suggestions, comments or want to help out feel free to open a PR or submit an issue.

This is a Python wrapper for the piaware/dump1090 ADBS library. This module requests information from the Raspberry Pi via a RESTful request. Returning a list of all aircraf the PiAware is reading.

You will need local LAN access to a Piaware enabled device.

Requirments

  • Python 3.7+
  • Python Requests Library
  • An active and working FlightAware/ Piaware with dump1090 (You can get started here: https://flightaware.com/adsb/piaware/)
  • Make sure to have alook in the requirments.txt file for additional dependencies

Setup

  • Create a virtual enviorment with: python3 -m venv [env_name_here]
  • Download the setup.py file with the following command: python3 setup.py install
  • OR you can use pip pip3 install PiAware_Dump1090_Wrapper

Sample Usuage

from aircraft import Aircraft
from queryscanner import QueryScanner

q = QueryScanner("http://RPI_IP_ADDR_AS_STRING")
aircraft = q.get_all_aircraft()

for i in aircraft: 
    print(i)
    

To-Do

  • Setup a docs for reference
  • Fix some typos
  • Improve setup.py and requirements
  • Better exception handling-
  • Implement generator function for querying
  • Fixes "To-Dos" throughout code base
  • When calling aircraft.update() method should not update the hex (ICAO) number as it is unique per aircraft. Implement method that will throw/return error and override the setattr method?
  • Implement custom exceptions on aircraft distance calculation while continuing to set attrs to None.
  • Try to implement tuple unpacking or a cleaner way to take arugments for the calucluate_distance_of_aircraft method
  • Check calculation for any mathmetical errors when computed? Need to read more about this equation to do so? Is there something more accurate? Is this a concern?
  • Do we need to check for any more errors in the input values of calculate_distance_of_airacft?
  • Implment testing (waiting on this as I am working on a firebase project for this)
  • Create exception for QueryScanner._create_query_url() if the url is invalid. Should sanatize this data more?
  • In Query Scanner there is an _auth method. Need to see if some PiAwares have a method of authorization.
  • Implement ability to get the status of the PiAware. This should be just an fstring dump of the date as it would be out of scope to relay on this for that information (maybe make a seperate model?)
  • Using n^2 method for querying data in get_all_aircraft(). I was able to improve a feature that queried the reciever twice for something, now need to work on improving this for effieceny.
  • Need to improve on exception handinling in get_all_aircraft()
  • Add implementation to avoid creating multiple queryscanner(). Need a better way to initlizie this class.
  • Create a PyPi package

piawaredump1090wrapper's People

Contributors

kc8 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.