From 4ab145c62a71f07121effd532b0e05790dee2f09 Mon Sep 17 00:00:00 2001 From: Ian Adam Naval Date: Sat, 12 Sep 2015 01:28:08 -0400 Subject: [PATCH] Tweak thresholds and sliding window size Increasing sliding window size makes it less sensitive to change, which makes it take a little longer to register that the dryer is on. This allows for short bursts of acceleration due to opening/closing the door and loading clothes. --- laundry_notifier/run.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/laundry_notifier/run.py b/laundry_notifier/run.py index 46e7009..f6ba897 100644 --- a/laundry_notifier/run.py +++ b/laundry_notifier/run.py @@ -24,8 +24,8 @@ Ianonavy Bot """ G_RANGE = 2 INTERVAL = 0.005 # seconds -WINDOW_SIZE = 40 # intervals -THRESHOLD = 0.003 # G's +WINDOW_SIZE = 1000 # intervals +THRESHOLD = 0.025 # G's MAX_EMAIL_FREQUENCY = 60 # seconds