kopia lustrzana https://github.com/glidernet/ogn-python
Cosmetics
rodzic
fbbf65f2de
commit
21573ae829
|
@ -1,6 +1,6 @@
|
|||
from ogn.model.beacon import Beacon
|
||||
from ogn.model.position import Position
|
||||
from ogn.model.receiver import Receiver
|
||||
from .model.beacon import Beacon
|
||||
from .model.position import Position
|
||||
from .model.receiver import Receiver
|
||||
|
||||
|
||||
def parse_aprs(text):
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
from urllib.request import urlopen
|
||||
|
||||
from ogn.db import session
|
||||
from ogn.model.address_origin import AddressOrigin
|
||||
from ogn.model.flarm import *
|
||||
from .db import session
|
||||
from .model.address_origin import AddressOrigin
|
||||
from .model.flarm import Flarm
|
||||
|
||||
|
||||
def get_devices_from_ddb():
|
||||
|
@ -27,7 +27,7 @@ def get_devices_from_flarmnet():
|
|||
response = urlopen("http://flarmnet.org/files/data.fln")
|
||||
lines = response.readlines()
|
||||
for line in lines:
|
||||
if (len(line) != FLARMNET_LINE_LENGTH):
|
||||
if (len(line) != Flarm.FLARMNET_LINE_LENGTH):
|
||||
continue
|
||||
|
||||
flarm = Flarm()
|
||||
|
|
|
@ -4,7 +4,7 @@ from sqlalchemy import Column, String, Integer, Float, DateTime
|
|||
from sqlalchemy.ext.declarative import AbstractConcreteBase
|
||||
|
||||
from ogn.aprs_utils import createTimestamp, dmsToDeg, kts2kmh, feet2m
|
||||
from ogn.model.base import Base
|
||||
from .base import Base
|
||||
|
||||
|
||||
# "original" pattern from OGN: "(.+?)>APRS,.+,(.+?):/(\\d{6})+h(\\d{4}\\.\\d{2})(N|S).(\\d{5}\\.\\d{2})(E|W).((\\d{3})/(\\d{3}))?/A=(\\d{6}).*?"
|
||||
|
|
|
@ -2,8 +2,8 @@ import re
|
|||
|
||||
from sqlalchemy import Column, Integer, String, Unicode, Boolean, SmallInteger
|
||||
|
||||
from ogn.model.address_origin import *
|
||||
from ogn.model.base import Base
|
||||
from .address_origin import AddressOrigin
|
||||
from .base import Base
|
||||
|
||||
|
||||
FLARMNET_LINE_LENGTH = 173
|
||||
|
|
|
@ -3,7 +3,7 @@ import re
|
|||
from sqlalchemy import Column, String, Integer, Float, Boolean, SmallInteger
|
||||
|
||||
from ogn.aprs_utils import fpm2ms
|
||||
from ogn.model.beacon import Beacon
|
||||
from .beacon import Beacon
|
||||
|
||||
|
||||
class Position(Beacon):
|
||||
|
|
|
@ -2,7 +2,7 @@ import re
|
|||
|
||||
from sqlalchemy import Column, String
|
||||
|
||||
from ogn.model.beacon import Beacon
|
||||
from .beacon import Beacon
|
||||
|
||||
|
||||
class Receiver(Beacon):
|
||||
|
|
Ładowanie…
Reference in New Issue