I had a board that liked to give false positives on the touchplate (NO), but I was using NC endstops.
The circuit goes as follows: The signal pin registers a “stop” when it is logic HIGH. In order to do this, there is a resistor between the 5V rail and the signal pin. When there is no path to ground, this raises the voltage to 5V (Or near enough) and the pin registers high, and triggers. When there is an NC switch, it shorts the signal to ground, registering logic LOW, which is untriggered.
If you have NO switches, you reverse the logic gates. The signal registers triggered at logic LOW when the switch closes. (Logic LOW triggering is more normal in electronics, actually.) I don’t like using capacitors to filter this because it also slows down the signal, and if you’re close enough to have noise, then you’re slowing down the signal by a random time interval. Not my idea of a good way to get precision. (Yeah, probably unimportant in the slower second pass, but…)
So there’s another way to filter out the false positives, and that is to wire an additional resistor between the 5V rail and the signal pin. This decreases the overall resistance, which means that there needs to be a much higher noise signal to drop the logic to LOW. The downside is a little more power usage at idle, because it will pass a bit more current to the pin, and a little bit more when the stop is triggered and it passes the current to ground.
Most of the pullup resistors that I’ve seen look to be about 470R. That’s about 10-11mA at 5V. The UNO datasheet says that you can have about 200mA on a pin. I added a 470R resistor on one of my boards between the 5V rail and the signal pin, which essentially halves the resistance, and increases the current to 20~22mA. For me, this was good to remove any false triggering for a NO switch, and did not introduce any appreciable latency to the switch timing.
Physically, what I did was put a 3 pin connector on the endstop switch, with one leg of the resistor on the end pin, and the other added to the signal pin in the middle, with the wires connected as you’d otherwise expect between signal and ground.