Exo
Active Member
Hi,
I'm doing a project and the PIC has to count pulses coming from a reed-switch. This switch will be far away from the PIC (100 meters).
I was thinking of just pulling the PIC's Input high with a lower value resistor (say 330 ohm - To lower input resistance) and letting the reed switch pull it down. Debouncing will be done in software .
Question: Will this work, or should i add some kind of filter? I'm not sure what effect the distance between the switch & PIC will have in terms of interference and it needs to be 100% reliable (no false pulse detections,...)
Also note that the wire will be running outdoors underground (if that matters).
I'm doing a project and the PIC has to count pulses coming from a reed-switch. This switch will be far away from the PIC (100 meters).
I was thinking of just pulling the PIC's Input high with a lower value resistor (say 330 ohm - To lower input resistance) and letting the reed switch pull it down. Debouncing will be done in software .
Question: Will this work, or should i add some kind of filter? I'm not sure what effect the distance between the switch & PIC will have in terms of interference and it needs to be 100% reliable (no false pulse detections,...)
Also note that the wire will be running outdoors underground (if that matters).