fixed rtime value
This commit is contained in:
4
main.py
4
main.py
@@ -85,7 +85,7 @@ def generateMap():
|
||||
active = datasta[9]
|
||||
pwr = datasta[10]
|
||||
csq = datasta[11]
|
||||
rtime = datasta[12]
|
||||
|
||||
rtime = datetime.now(tz)
|
||||
rtime = rtime.strftime("%Y-%m-%d %H:%M:%S")
|
||||
|
||||
@@ -100,7 +100,7 @@ def generateMap():
|
||||
f.write("lat|lng|Name|SN|Unit time|STA received|Lat|Lon|Country|Velocity|Heading|Nav|Nsat|Age|Active|Pwr|Csq|sta\n")
|
||||
for key in dictionary.keys():
|
||||
if lat and lon is not None:
|
||||
wr = f"{lat}|{lon}|{key}|{obuid}|{time}|{rtime}|{lat}|{lon}|{country}|{velocity}|{heading}|{nav}|{nsat}|{age}|{active}|{pwr}|{csq}|{sta}\n
|
||||
wr = f"{lat}|{lon}|{key}|{obuid}|{timefromsta}|{rtime}|{lat}|{lon}|{country}|{velocity}|{heading}|{nav}|{nsat}|{age}|{active}|{pwr}|{csq}|{sta}\n
|
||||
|
||||
# TODO: needs rewrite to trigger this function on request
|
||||
time.sleep(200)
|
||||
|
||||
Reference in New Issue
Block a user