Metadata-Version: 2.1
Name: aogn
Version: 0.1.0
Summary: Asynchronous APRS OGN (Open Glider Network) Client for asyncio and Python.
Home-page: https://github.com/csindle/aogn
Author: Colin Sindle
Author-email: aogn@succinct.co.za
License: UNKNOWN
Project-URL: Bug Tracker, https://github.com/csindle/aogn/issues
Platform: UNKNOWN
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: GNU Affero General Public License v3 or later (AGPLv3+)
Classifier: Operating System :: OS Independent
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE

# aogn

Asynchronous OGN ([Open Glider Network](http://wiki.glidernet.org/)) Client for asyncio and Python that receives the 
planes', gliders', receivers', etc. APRS messages.

Use a library like [python-ogn-client's](https://github.com/glidernet/python-ogn-client) `ogn.parser.parse` to interpret these messages.


## Installation

```
pip install aogn
```

## Usage

Please see `example.py` for a concurrent example.

Simple example:

```python
import asyncio
import logging
import sys

logging.basicConfig(
    stream=sys.stdout,
    level=logging.DEBUG,
    format='%(asctime)s %(levelname)s %(module)s %(message)s',
    datefmt='%b %d %H:%M:%S',
)

from aogn import Client


async def example() -> None:
    conn = Client(aprs_user='NO-CALL', )

    try:
        while True:
            # Get the APRS packet once available:
            raw_message = await conn.packet()
            logging.debug(raw_message)
    except KeyboardInterrupt:
        logging.info('OGN Gateway stopped.')

    await conn.disconnect()


if __name__ == '__main__':
    asyncio.run(example())

```


