-
Notifications
You must be signed in to change notification settings - Fork 124
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pi hangs w/ buster when pin value changes #177
Comments
This is the first time I've heard of this issue and I'm unable to reproduce the issue with the onoff integration tests on Buster. Please provide a simple but complete program that can be used to reproduce the issue. Please also provide the output of the following commands when run on the Raspberry Pi:
|
This appears to be a related issue raspberrypi/linux#2550, however onoff doesn't appear to suffer from this issue. |
@fivdi Thanks for taking the time to look into this. I was out for a few days but I'll work on putting together a small repro. It might be related to other hardware I have on the pi (I have an ezconnect board between the pi and a PICAN2 CANBus card. ) |
@fivdi First, I don't think there is a fundamental problem so I will close the issue. But I did get some fairly interesting findings by messing with pin/port numbers and hardware. The code I was testing with is super simple, just the blink example plus a watch on another pin:
However, when I first started, I accidentally used the pin number, not the GPIO number so line 3 read With that code and without the PICAN2 board, I could not get the pi to hang. Of course, I also wasn't getting any hits on the pin either, because I was watching some non-existent pin. With that code and the PICAN2 board, the pi would hang anytime any pin was touched with a wire, even when the wire wasn't grounded or attached to voltage. I can't really explain this, but with the code reduced to just this:
It would run forever without the PICAN2 but would hang as soon as any pin was touched while the PICAN2 was attached. I tried reproing that again just now and noticed that the console logging, which should happen every second, stalls for about 10 seconds when a pin is touched, and my bluetooth kb and mouse hang but then the "blink" console logs start up again so the pi isn't completely hung. Yet, the original code with the pin properly set to 21 works correctly, with or without the PICAN2 board attached. Therefore, while I'm still confused as to why it was/is hanging/ish with no ignitionSwitch watch, I'm closing the issue. |
Oh, and if you still want it: |
It appears that this library suffers from the same issue as rpio with regard to interrupts on newer versions of Raspbian? The solution proposed there is to disable interrupts via dtoverlay=gpio-no-irq but that prevents other hardware that depends on interrupts from working. Are there any other work-arounds?
The text was updated successfully, but these errors were encountered: