Heckler,
The reed switches are different ones but I have rigorously tested the ones under the track including the lead wire to the location of the new controller. This was easily done by rolling the trolley with magnet over the switch and checking the continuity. All 3 worked well.
Vibration seems to be unlikely but I would have to devise a test to confirm that.
I have worked with hall sensors before and considered it in concept but the most distant of the 3 track sensors is about 7 feet away from the controller. The advantage of the reed switch is that it does not require the additional complexity of getting 5vDC power to each sensor location and in the end, the the signal is still traveling along an antenna-like lead wire parallel to all this noisy DC motor operation and an arcing power connection (the trolley catenary.)
Bypass caps as you suggest are a recurring theme in all the posts I have read. I assume you mean putting them on the control board trace at the node where the the input pin and pullup intersect? That would make it parallel with the pullup to ground?
As I mentioned in a previous reply, I had read about dual sampling and think the idea has merit. I understand the concept in the code you provided, thanks. I will try this if external shielding fails to solve the problem. It is a bit of a hassle getting back into the control enclosure to get things ready for ICSP (some dis-assembly required.)
I have a clunky old Tektronix scope with a CRT output and one channel fried but I could always make a project out of dusting it off and remembering how to use it again!
Bookmarks