1

It seems that GPIO 5 (pin 29) is used by another process: when starting my script I get "...channel already in use..." warning.

Oscilloscope confirms that, because after a reboot, the pin is toggling.

Is there a way to find which script/program is accessing the pin? And in general is there a way to check which pins are already in use by other programs?

1 Answer 1

1

No, there is no general way.

Presumably it is your computer, you should be aware of any programs you have started.

In this case the most likely explanation is you have set the script you are running manually to also run at boot.

2
  • There should be something, since there is "...channel already in use..." warning. Jun 28, 2018 at 5:54
  • That is telling you that a process has "exported" that GPIO via the sysfs interface. In that particular case you could find the process with something like lsof. That does not help in the general case (most programs do not use sysfs) and may not in any particular case either (that may not be the process toggling the GPIO). Most GPIO programs bypass sysfs for performance and needed functionality reasons.
    – joan
    Jun 28, 2018 at 6:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.