Compare commits

..

No commits in common. "03f011fb80914c5c8de554c1d89c8f8ed715ff17" and "6a3bef6e1a630f64e31e80968f3051ab0208a3b1" have entirely different histories.

2 changed files with 4 additions and 8 deletions

View file

@ -1,3 +1,3 @@
#! /bin/bash
make -C /home/ncrs1/stephan/tk102gpx TIMELIMIT=-t1d tk102-1.gpx tk102-1.png tk102-2.gpx tk102-2.png tk102-1.txt tk102-2.txt
make -C /home/ncrs1/stephan/tk102gpx TIMELIMIT=-t1d tk102-1.gpx tk102-1.png tk102-2.gpx tk102-2.png

View file

@ -55,11 +55,9 @@ for o,v in options:
serial = time.strftime("%y%m%d%H%M", time.gmtime(time.time()-t)).encode()
if verbose:
print(f"--serial={serial}", file=sys.stderr)
"""
2403182137,<E9><F0><8F><CC>^]<CB><FE><CD>g<EE>^]}<FE><FD><DC>_<FF>P,GPRMC,213722.000,A,5416.3748,N,00952.1328,E,0.01,0.00,180324,,,A*6C,F,imei:013777002752663,110<D1>i
"""
tk_re = re.compile(b"".join((
b"(?P<SERIAL>24[0-9]+),",
b"(?P<SERIAL>23[0-9]+),",
b"(?P<PHONE>[^,]+(,[^,]*)?),",
b"GPRMC,",
b"(?P<TIME>[0-9]{6}(\.[0-9]+)?),",
@ -78,7 +76,7 @@ tk_re = re.compile(b"".join((
b"(?P<MESSAGE>[^,]+,)?",
b"imei:(?P<IMEI>[0-9]+),",
b"(?P<LEN>[0-9]{3})",
b"(?P<BCKS>2[^234]|[^2][^2])?"
b"(?P<BCKS>2[^23]|[^2][^2])?"
)), flags=re.DOTALL)
def gprmc2deg(d,dd):
@ -116,8 +114,6 @@ class TKGPX(gpxpy.gpx.GPX):
while data or follow or files:
m = tk_re.search(data)
while not m:
if verbose >= 3:
print(len(data), repr(data[-80:]))
ndata = inp.read(0x100000)
while not ndata and files:
inp.close()