From 4beca321dc903ea044d39bfd37dd2436489ac085 Mon Sep 17 00:00:00 2001 From: halfbakery Date: Tue, 3 Sep 2019 18:52:58 +0200 Subject: [PATCH] adjusting delta calculation for better WT0124 decoding --- src/RF_Handling.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/RF_Handling.c b/src/RF_Handling.c index 8cdc030..6b8e5b1 100644 --- a/src/RF_Handling.c +++ b/src/RF_Handling.c @@ -91,8 +91,8 @@ uint8_t Compute_CRC8_Simple_OneByte(uint8_t byteVal) uint16_t compute_delta(uint16_t bucket) { - //return ((bucket >> 2) + (bucket >> 4)); - return (bucket >> 2); // 25% delta of bucket for advanced decoding + return ((bucket >> 2) + (bucket >> 4)); + //return (bucket >> 2); // 25% delta of bucket for advanced decoding } bool CheckRFBucket(uint16_t duration, uint16_t bucket, uint16_t delta)