Limit Switch Wiring?

Post Reply
oldrayj
Posts: 93
Joined: Wed Sep 26, 2012 8:00 pm
Location: Bellbrook, Ohio
Contact:

Limit Switch Wiring?

Post by oldrayj » Tue Feb 19, 2013 3:52 pm

I’ve been trying to piece together the info I’ve found on the forum in order to properly wire limit switches. Is the diagram below correct? If not, please point me in the right direction. Thanks.
Limit1.png
Limit1.png (159.14 KiB) Viewed 11864 times

PsyKo
Posts: 430
Joined: Thu Aug 30, 2012 8:42 pm
Location: France

Re: Limit Switch Wiring?

Post by PsyKo » Tue Feb 19, 2013 4:19 pm

I don't think this is correct, but I'm no expert in electronic.

I think you simply have to remove the Red +5V wire since the limit pins are already held HIGH. When the switch is closed, they are connected to GND which trigger the limit detection.

Below is what I would do, assuming the left and right pin of the switch connects when the switch is closed :
vhbbewj6.jpg
vhbbewj6.jpg (33.02 KiB) Viewed 11859 times

If someone could confirm.
Shapeoko #736
Kress 800, Z Axis upgrade, dual Y, 600mm X&Y rails, metal spacers and V Wheels, home switches, 4th axis
Goko - Free CNC Control Software - http://www.shapeoko.com/forum/viewtopic ... 380#p44380

cvoinescu
Posts: 4442
Joined: Thu Jul 19, 2012 6:50 pm
Location: Camberley, UK
Contact:

Re: Limit Switch Wiring?

Post by cvoinescu » Tue Feb 19, 2013 8:00 pm

That's not good either. You want the pull-ups, as the internal ones are weak. You want 1K or slightly less.

I can't scan or draw anything right now, so I'll try to use words. You have six switches and three resistors. The resistors are connected between +5V and the three input pins on the Arduino. The X switches are connected, in parallel, between one of the pins and ground. Same for the two Y switches on a second pin, and the two Z switches on a third pin. The switches should be NO, so when they're not pressed the resistors pull the pins up to +5V, and when any one is pressed, the respective pin tied to GND.

The original diagram is almost right, except half of the resistors aren't necessary, +5V and GND are swapped, and you should use the C and NO terminals of the switches, not C and NC.

Hope this helps.
Proud owner of ShapeOko #709, eShapeOko #0, and of store.amberspyglass.co.uk

oldrayj
Posts: 93
Joined: Wed Sep 26, 2012 8:00 pm
Location: Bellbrook, Ohio
Contact:

Re: Limit Switch Wiring?

Post by oldrayj » Tue Feb 19, 2013 9:08 pm

Thanks for the input. Really helped. I'm going to make a new diagram to make sure I get it right. Thanks again.

oldrayj
Posts: 93
Joined: Wed Sep 26, 2012 8:00 pm
Location: Bellbrook, Ohio
Contact:

Re: Limit Switch Wiring?

Post by oldrayj » Tue Feb 19, 2013 10:27 pm

Another try.
Limit1 (2).png
Limit1 (2).png (165.98 KiB) Viewed 11822 times

cvoinescu
Posts: 4442
Joined: Thu Jul 19, 2012 6:50 pm
Location: Camberley, UK
Contact:

Re: Limit Switch Wiring?

Post by cvoinescu » Tue Feb 19, 2013 10:38 pm

Swap the 5V and GND connections to the Arduino (so that the resistors go to 5V and the wire common to all six switches goes to GND) and you have it. Also, 3K3 is probably fine, but I'd use 680 ohm to increase noise immunity (especially if you run these wires along the stepper cables).
Proud owner of ShapeOko #709, eShapeOko #0, and of store.amberspyglass.co.uk

oldrayj
Posts: 93
Joined: Wed Sep 26, 2012 8:00 pm
Location: Bellbrook, Ohio
Contact:

Re: Limit Switch Wiring?

Post by oldrayj » Wed Feb 20, 2013 2:08 pm

Third time's a charm (hopefully). Thanks for your patience.
Limit3.png
Limit3.png (143.22 KiB) Viewed 11797 times

cvoinescu
Posts: 4442
Joined: Thu Jul 19, 2012 6:50 pm
Location: Camberley, UK
Contact:

Re: Limit Switch Wiring?

Post by cvoinescu » Wed Feb 20, 2013 2:19 pm

Yay! Perfect. :)
Proud owner of ShapeOko #709, eShapeOko #0, and of store.amberspyglass.co.uk

Tom Smith
Posts: 297
Joined: Mon Apr 09, 2012 9:55 pm
Location: North Vancouver, British Columbia

Re: Limit Switch Wiring?

Post by Tom Smith » Wed Feb 20, 2013 5:49 pm

I'm a big fan of this kind of instructions - my electronics skills are sketchy at best, and a clear picture is worth, well, a thousand words :)

Thanks oldray, cvoinescu (sometimes I wish I knew peoples names, addressing people by their forum tags seem odd sometimes :)

Tom
_______________
ShapeOko1 191

cvoinescu
Posts: 4442
Joined: Thu Jul 19, 2012 6:50 pm
Location: Camberley, UK
Contact:

Re: Limit Switch Wiring?

Post by cvoinescu » Wed Feb 20, 2013 7:38 pm

Hi, Tom. It's Catalin, or Cat for short.
Proud owner of ShapeOko #709, eShapeOko #0, and of store.amberspyglass.co.uk

Post Reply