Skip to content
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

GPIO pins are very sensitive #8

Open
Benny7587 opened this issue Jun 16, 2021 · 2 comments
Open

GPIO pins are very sensitive #8

Benny7587 opened this issue Jun 16, 2021 · 2 comments

Comments

@Benny7587
Copy link

Because of the very sensitive GPIO pin and the long cable (3 meters) to the push button (we only play one video) the video starts sometimes when lights are switched on or off.
I tried to solve this with a pull up resistor and also a capacitor over the wire but cannot get it to work properly.
I was thinking of a software solution in a way that the status of the gpio pin is checked multiple times with a short wait state (5x50msecs…) in between. Could this eliminate an induction pulse on the long cable. What is your opinion about this idea?

@cveerkamp
Copy link

I know this issue is over a year old at this point, but I just found this project & I had the same issue. I am using this with an outdoor monitor and button panel, with the Pi inside about 10ft away. I was able to solve my issues by using an optoisolator board, with 12v on the button side, and then 3.3v on the Pi side. I use 4 buttons, so I ended up buying this: https://www.amazon.com/dp/B07TCVTD2K

@alubbock
Copy link
Owner

alubbock commented Jul 8, 2022

@cveerkamp That's a good suggestion - debouncing in hardware would be preferable where possible. Increasing VidLooper._GPIO_BOUNCE_TIME might also help, or a software-based debounce as described on StackOverflow might also help. If anyone wants to create a PR based on the StackOverflow method, I'd be happy to review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants