Viewing Switch Bounce with an Oscilloscope - Page 1
Forum section: electronics / beginners

author: kbish
author_rank: Newbie
timestamp: April 11, 2015, 04:09:40 am
content: Greetings all.I am a first time poster to this forum, although I have learned a good number of things as I have started studying electronics recently as a hobby. Unfortunately, I have gotten stumped on something and need to ask for a bit of advice. This largely is focused on the use of an oscilloscope, but since I believe it is quite possible that the issue is with me, the beginner, versus the scope, I have posted it here rather than the Test Equipment forum. Apologies in advance if this is mis-posted.I recently purchased a "starter" oscilloscope, a Siglent SDS 1102CML, so that I could use it to directly view what some of my circuits are doing as I follow on with example projects and exercises. After a bit of familiarization I decided to start by looking at switch bounce in some SPST switches. My goal was to see the "raw" bounce, the effect of adding a capacitor in parallel, and finally a Schmitt Trigger. Modest goals, but I figured it was a good place to start.I set up the scope, checked the probe compensation, and then set up to trigger on a downward edge. After a bit of experimentation and User Manual interpretation (the manual could be better), I got to where I was capturing the event nicely. I could see the signal start at 5V then drop down to 0V as expected. The problem is I could never see the bounce! Experiments with changing the time base, acquisition method, or trigger threshold didn't matter - even when the sample length caught the rising edge of the button being released there was no bounce captured.Not believing this I rebuilt the circuit with an Arduino and coded a quick sketch to count bounce transitions and connected the oscilloscope to that. While not every push had bounces, a good percentage of them did but the scope never showed them -- even when their amount of time captured after the down edge was quite large. I have seen demonstrations online where USB-based scopes with lesser specs than this scope caught the bounce, so I am really puzzled.I would certainly appreciate advice on what I might be doing wrong. At this point I've usually been able to puzzle out situations like this, but not this time.A little more information to help:In the case of the version I build with the Arduino counting bounces, the circuit is a pretty standard SPST switch, with the sensing pin on the Arduino connected to 5V via a 10K Ohm pullup resistor connected to one side the switch and the other side of the switch going to groundThe probe is attached to the Vcc side of the SPST switch and ground lead to groundI have tried both 1x and 10x probe settings and made the appropriate updates within the scope to reflect the change in compensationAs I mentioned above, I have tried a wide variety of time base settings, acquire settings, trigger thresholds etc (if I listed them all out there may be some tragic humor in seeing how long the list is, but I don't know if it will help)If there is anybody familiar with this scope who can provide specific comments, or others with general guidance, I'm all ears (or eyes since I'll read your comments).Thanks in advance for your thoughts. I'm happy to provide additional information that may be helpful, just let me know.KB

author: tautech
author_rank: Super Contributor
timestamp: April 11, 2015, 04:58:39 am
content: Welcome to the forumTo capture events like these one would set up for the expected waveform, adjust the Trigger level to an appropriate level and use "Single".The scope would display "Armed" and the waveform would be captured WHEN it meets the Trigger settings.It would not matter too much for the Timebase setting as when captured you can expand the waveform with the Timebase for closer inspection.Where in the circuit you attempt to observe the bounce will have some bearing on what you will see.Also check the Ch input BW limit is not set to 20MHz. You want full BW to see fast edges.

author: ivaylo
author_rank: Frequent Contributor
timestamp: April 11, 2015, 06:31:55 am
content: What tautech said. Doing whatever you are doing with the Arduino is much harder than just using the scope in Single shot mode. You can also try a pull down resistor and rising front triger.

author: Jeroen3
author_rank: Super Contributor
timestamp: April 11, 2015, 01:17:59 pm
content: You can also set the scope to "normal" trigger and increase the trigger-holdoff.This will allow you to continue pressing the button without pressing the "single" button again.

author: PSR B1257
author_rank: Frequent Contributor
timestamp: April 11, 2015, 03:54:56 pm
content: QuoteSure, since there is none. You just open the switch, why should it bounceIf you want to see some bouncing, you have to close the switch. And put a load (100R or whatever, not critical, as long as it is areasonablevalue) to the switch too, otherwise you possibly measure all sorts of crap, but not the signal of interest.In the end, it could look like this.

author: dannyf
author_rank: Super Contributor
timestamp: April 12, 2015, 12:32:43 am
content: QuoteMaybe your particular switch doesn't bounce? It could be such a nice switch; it could have a built-in debouncer; ...