Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/mattrasband/aioaprs

Asyncio based read-only APRS streaming library
https://github.com/mattrasband/aioaprs

aprs asyncio ham-radio python3

Last synced: 7 days ago
JSON representation

Asyncio based read-only APRS streaming library

Awesome Lists containing this project

README

        

# aioaprs

Asyncio Based APRS client

## Usage

### Install

```bash
$ pip install -U https://github.com/mrasband/aioaprs.git
```

### Use

```python
import asyncio
import dataclasses
import logging
import re
from typing import List, Optional

from . import (
APRSClient,
AreaFilter,
Point,
RangeFilter,
TypeFilter,
Types,
)

logging.basicConfig(level=logging.INFO)

async def main():
async with APRSClient("KD0VTE", filters=[
RangeFilter(Point(39.545917, -104.927592), 100),
# Ignore everything except the Position reports
~TypeFilter([
Types.ITEMS,
Types.MESSAGE,
Types.NWS,
Types.OBJECTS,
# Types.POSITION,
Types.QUERY,
Types.STATUS,
Types.TELEMETRY,
Types.USER_DEFINED,
Types.WEATHER,
]),
]) as client:
async for packet in client:
print(packet)

if __name__ == "__main__":
try:
asyncio.run(main())
except KeyboardInterrupt:
pass
```