Z & Y limit switches are working, but X triggers before being touched

I’m installing limit switches on my Shapeoko 2 and am running into a little bit of an issue. When I home, it homes Z, then homes Y without issue. Then, when it starts to home X it will stop while it’s travelling to the switch. If I home again, it’ll usually trigger too early again. If it does hit the X limit, it will stop.

I’ve got the wires to the switch running through the X extrusion, along with the wires for the left Y motor, though they’re in their own piece of extrusion, since the X extrusion is two pieces butted up. The shielded motor cables and the 2 wires for the switch (22 gauge wire) do not touch each other.

I’m using this Aruduino GRBL sheild and the switches are on a little pcb with resistors, capacitors and a LED. And I’m using GRBL 1.1f.

I suspect I might be having a noise issue, but just on this one switch. I figured that the circuitry on the PCB for the switch was there to prevent that, but I’m not really sure. Any ideas?

It do sound like false trigger on the X, have you the switches wired as NO (Normally Open)?
If so you could rewire and try NC circuitry (Normally Closed), you need to change GRBL parameter $5=1 for NC operation ($5=0 equal NO and default configuration)

NC is usually more resistant against false triggers as its 5V when switch is not pressed.
(The switch have three pins, one for GND and one for NC and the third for NO)

I looked at the traces on the circuit boards the switches live on, and it did look like I could swap the wires so that they ran in NC.

However, what ended up working was building a noise filtering circuit using this diagram. I’m now able to home from the farthest opposite point on my machine.


1 Like