1
0
mirror of https://github.com/skaringa/water-counter.git synced 2024-11-24 18:34:23 +01:00

Pause detection fixed

This commit is contained in:
Martin Kompf 2016-10-30 18:45:07 +01:00
parent bc2d29d27c
commit 99c57b9c19

View File

@ -62,7 +62,7 @@ def detect_pauses(data):
for (ts, counter) in data:
if counter > start_counter:
duration = ts - start_time
if duration > min_pause:
if duration >= min_pause:
result.append({'start' : start_time, 'duration' : duration})
start_time = ts
start_counter = counter