<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Recent changes to 193: buoncetime is not a debouce</title><link>https://sourceforge.net/p/raspberry-gpio-python/tickets/193/</link><description>Recent changes to 193: buoncetime is not a debouce</description><atom:link href="https://sourceforge.net/p/raspberry-gpio-python/tickets/193/feed.rss" rel="self"/><language>en</language><lastBuildDate>Wed, 06 Jan 2021 10:08:15 -0000</lastBuildDate><atom:link href="https://sourceforge.net/p/raspberry-gpio-python/tickets/193/feed.rss" rel="self" type="application/rss+xml"/><item><title>buoncetime is not a debouce</title><link>https://sourceforge.net/p/raspberry-gpio-python/tickets/193/</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;Hello everyone!&lt;/p&gt;
&lt;p&gt;Before complaining I want to thank you for the effort you are putting in this project :)&lt;/p&gt;
&lt;p&gt;I am using the bouncetime parameter, which I expected to be a debounce.&lt;br/&gt;
I expected it to wait for a given time before generate an edge event, checking for the pin to be stable in the new state.&lt;br/&gt;
But instead bouncetime is a minimum time between two generated events.&lt;br/&gt;
The event is generated immediately,  without any wait.&lt;/p&gt;
&lt;p&gt;Possible solutions I see giving a look to the code:&lt;br/&gt;
  - when an edge is found, set a callback after bouncetime, in this callback check the pin again, and if it is good generate the event&lt;br/&gt;
  - to be more accurate it could generate more frequent callbacks, acting like a polling check&lt;br/&gt;
  - or declare a function for the user to call, to  poll the pin&lt;/p&gt;
&lt;p&gt;At least... the internet should stop talking about bouncetime as a debounce&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Marco Negrini</dc:creator><pubDate>Wed, 06 Jan 2021 10:08:15 -0000</pubDate><guid>https://sourceforge.net85fcefb4c3578ff736af215555b6ef818dc40da7</guid></item></channel></rss>