I've read enough about filtering on I/O lines to know... that I don't know anything.
![Smiley :)](https://www.eevblog.com/forum/Smileys/default/xsmiley.gif.pagespeed.ic.R8GFI-pF6f.png)
Let's say I have a simple MCU project consisting of an I2C 7-segment display (e.g.
this), some buttons (i.e. NO momentary switches), and some "kit" MCU (e.g. an Arduino Nano clone). For simplicity's sake, let's also say I'm plopping the MCU board onto a breadboard and connecting the other bits with 6"-12" wires.
My initial design just has each of several input pins wired directly to a button, in turn wired directly to "ground". I'm handling debounce in software (basically, near-continuous polling, and only register a press when the pin has continuously polled closed-circuit for some number of milliseconds).
Some obvious possible applications include alarm clock or stopwatch. In many cases, spurious detection of button presses is... ungood. (For example, my hypothetical stopwatch won't function very well if the MCU erroneously thinks the 'stop' button was pressed.)
What else, if anything, do I need to ensure that a) I don't pick up spurious button presses, and b) the I2C bus works? (Filter caps? ESD protection? Shielding around the wires? The eventual project is part of an automation system that's going to have other stuff, particularly a bunch of large 12V EMRs as well as other PCBs, in the same enclosure. Also, the I2C and button wires are going to be close together, maybe even bundled.)