Adjust thresholds

This commit is contained in:
Mike Cifelli 2023-10-28 11:31:13 -04:00
parent ef20bf5367
commit 9a99a1f8a6
Signed by: mike
GPG Key ID: 6B08C6BE47D08E4C
1 changed files with 3 additions and 3 deletions

View File

@ -61,12 +61,12 @@ class Marshaller(Server):
if distance_in_inches < 15:
self.red_led.on()
elif distance_in_inches < 20:
elif distance_in_inches < 23:
self.green_led.on()
self.yellow_led.on()
elif distance_in_inches < 25:
self.green_led.on()
elif distance_in_inches < 30:
elif distance_in_inches < 33:
self.yellow_led.on()
else:
self.blue_led.on()
@ -80,7 +80,7 @@ class Marshaller(Server):
def get_buffered_distance_in_inches(self):
distance = self.get_distance_in_inches()
if abs(distance - self.last_value) > 0.5:
if abs(distance - self.last_value) > 0.25:
self.last_value = distance
return self.last_value