From b584dd1cebcca58059c718e018706e9afeca34ac Mon Sep 17 00:00:00 2001 From: Dmitry Petuhov Date: Mon, 15 Jun 2020 14:14:24 +0300 Subject: [PATCH] Fix gpio ISR Gpio utility gets wpi pin numger, not gpio pin number. Calling with latter leads to error. --- wiringPi/wiringPi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wiringPi/wiringPi.c b/wiringPi/wiringPi.c index f3c638e..a97c219 100755 --- a/wiringPi/wiringPi.c +++ b/wiringPi/wiringPi.c @@ -2030,7 +2030,7 @@ int wiringPiISR (int pin, int mode, void (*function)(void)) else modeS = "both" ; - sprintf (pinS, "%d", bcmGpioPin) ; + sprintf (pinS, "%d", pin) ; if ((pid = fork ()) < 0) // Fail return wiringPiFailure (WPI_FATAL, "wiringPiISR: fork failed: %s\n", strerror (errno)) ;