I am not sure if this is the right place, I just wanted to mention that after building my first prusa and testing it I got sporadic false end detection on X. Issue was wires length (and they come together with x motor) that produces noise. Adding 400pF condenser (I put it directly on connector) from signal to ground solved the issue.