PDA

View Full Version : Question about the switch circuit in the PBP manual



schu4647
- 11th April 2010, 16:48
The switch circuit in the PBP manual shows the input pin pulled up through a 10k. That 10k then gets grounded through a switch causing a low on the input. I have noticed that the capacitance of the pin interacting with the trace inductance causes some very fast ringing. I am seeing -2Volts for about 25ns. Why is this ok? I assume it is since this is a very common method for reading switch inputs on micros and various other IC's but it violates the minimum voltage of the pin.

Charles Linquis
- 11th April 2010, 18:22
If your trace is short, the ringing is probably caused by your test setup (like a scope probe with a 6" ground lead.

The PIC probably doesn't "see" that -2V signal. Even if it did, the body diode (on the input of the pin) would clamp it to a diode drop below GND.

rsocor01
- 12th April 2010, 04:57
Also, to avoid false readings and weird behavior of the switch a pause should always be set after a ground is detected (if a pullup resistor is used). This pause is for debouncing the switch and to let the ringing pass. In an 'ideal' switch you wouldn't need this debouncing pause period, but a real world switch will mechanically oscillate and act strange.

Robert

Acetronics2
- 12th April 2010, 13:37
I am seeing -2Volts for about 25ns. Why is this ok? I assume it is since this is a very common method for reading switch inputs on micros and various other IC's but it violates the minimum voltage of the pin.

Hi, schu

1) note most of the the inputs have clamp diodes to VDD and VSS ... ( Hi , Charles ...)

sooo ... not less than - .6 volts ...

2) min Detection time of PicŪ pins is 50 ns ...

Alain