pytec: remove obsolete conversions

This commit is contained in:
Astro 2020-12-18 19:37:14 +01:00
parent b176fc2788
commit 7c55e34145
1 changed files with 2 additions and 4 deletions

View File

@ -51,13 +51,11 @@ def recv_data(tec):
ch0 = data[0]
series_lock.acquire()
try:
time = ch0['time'] / 1000.0
for k, s in series.items():
if k in ch0:
v = ch0[k]
if type(v) is float:
s.append(time, v)
s.append(ch0['time'], v)
finally:
series_lock.release()
@ -106,7 +104,7 @@ def animate(i):
else:
max_y = max(max_y, max_y_)
if min_x is not None and max_x - TIME_WINDOW > min_x:
if min_x and max_x - TIME_WINDOW > min_x:
for s in series.values():
s.clip(max_x - TIME_WINDOW)
finally: