From 1d7e56f83796ed56e9f4ec98f4cf7f8aede5f7ac Mon Sep 17 00:00:00 2001 From: Ben Nicholson Date: Wed, 19 Nov 2025 11:19:57 +1100 Subject: [PATCH] Change GPIO Both to Rising Change how the GPI detection workes, so it only does things on the rising edge --- ras_pi_RRCS_BusyLight.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ras_pi_RRCS_BusyLight.py b/ras_pi_RRCS_BusyLight.py index 0bac1a7..0617111 100644 --- a/ras_pi_RRCS_BusyLight.py +++ b/ras_pi_RRCS_BusyLight.py @@ -57,7 +57,7 @@ GPIO.setwarnings(False) GPIO.setmode(GPIO.BOARD) GPIO.setup(12, GPIO.IN, pull_up_down=GPIO.PUD_DOWN) -GPIO.add_event_detect(12, GPIO.BOTH, callback=button_callback, bouncetime=200) +GPIO.add_event_detect(12, GPIO.RISING, callback=button_callback, bouncetime=200) input("Press enter to quit\n\n") GPIO.cleanup() \ No newline at end of file