Files
adsb-tools/python/adsblib.py

10 lines
176 B
Python
Raw Normal View History

2016-02-18 10:10:47 -08:00
import json
import socket
def GetEvents(host, port):
with socket.create_connection((host, port)) as sock:
fh = sock.makefile()
for line in fh:
yield json.loads(line)