Hello Guest it is March 01, 2021, 06:13:02 AM

Author Topic: Normally Open VS Normally Closed  (Read 13931 times)

0 Members and 1 Guest are viewing this topic.

Normally Open VS Normally Closed
« on: August 10, 2016, 08:19:43 PM »
This is a good one.  Would like to hear the arguments that go to the heart of the reasoning.

To start, lets say axis A (maybe a tool changer moving in and out from limit 1 to limit 2).

Why should the limit switches be wired one way or the other. 

This will be fun as most opinions will be based on previous readings from the net without any actual thought to the real question.

  All my limits were wired N.O.........Good thing, because Mach 3 has a bug with "IF NOT"

Fire away.

Re: Normally Open VS Normally Closed
« Reply #1 on: August 10, 2016, 10:39:17 PM »
All commercial machines that I'm aware of use normally closed switches on limit circuits.

The reason for this is safety. With a normally open switch, your relying on the switch closing, completing the circuit and activating the input.  If a wire to the limit switch is broken (or not plugged in properly), then when the limit switch is closed, the input is NEVER activated. In some large machines this would destroy the machine.

Using a normally closed circuit, the input circuit  is closed in the normally operating condition. When the limit switch is hit and opened the input is activated. The advantage of this system is that the limit input will also be activated if a wire breaks or a connector becomes unplugged.

There is nothing to debate on this one.

Cheers,

Peter
----------------------------------------------------
Homann Designs
http://www.homanndesigns.com
email: peter at homanndesigns.com
Re: Normally Open VS Normally Closed
« Reply #2 on: August 10, 2016, 11:28:29 PM »
Agreed.  Peter has said it all.  Safety.

Now, as far as the Mach3 bug, are you writing a macro to check the status of the limit/homing switches?  No need to do IF NOT.  Just set the switch input to an active high when using normally closed switches (wired in series of course) and you're done.  The logic for macros is still the same, IF <limit switch state = TRUE> THEN STOP (or whatever action you need to do).  No need to do an IF NOT check.  You could also do an IF <limie switch state = FALSE> check if you need to make sure the switch is NOT active.

Hope this makes sense.

Stephen "Highspeed" Kruse

Offline Davek0974

*
  •  2,606 2,606
    • View Profile
    • DD Metal Products Ltd
Re: Normally Open VS Normally Closed
« Reply #3 on: August 11, 2016, 02:12:58 AM »
Industry standard safety relays like PILZ, PREVENTA et al, all use N/C switches and cannot be configured to use N/O switches on the safety monitoring side.
Bridgeport Mill, Mach3 V062, CSMIO-IP/A controller, AC Servo Drives.
Plasma table, Mach3 V062, Step motors, C&CNC THC.
Re: Normally Open VS Normally Closed
« Reply #4 on: August 11, 2016, 10:05:07 AM »
As I do a lot of industrial wiring I can add a few things.
Safety circuits such as E-Stop are generally wired in series meaning the output of one switch is wired to the input of the next and so on.  So these have to be wired NC so that there is a High signal to indicate the end of a circuit.  If any one switch is pressed, this opens the entire circuit.  If any wire is broken, this opens the entire circuit.  Very clearly the way to go and was figured out a long time ago.

For limit switches, there are two configurations commonly used.  If there is a manual switch that can move something, we will generally run the output of the switch through the NC contacts on the limit switch and then on to the starter.  This has as much to do with convience as it has to do with safety, it is merely an easy way to minimize wire pulls back to a remote cabinet housing the contactor.  If we use NO on the LS, then this would require an extra wire going back and would require a relay to break the circuit.  In this setup, it is safe to run the axis as long as the limit switch is Not Tripped.

In the case of a tool carosel, it is very different.  We want to know that it is either IN or OUT.  We really don't care where it is if it is somewhere in the middle.  We just know it is not safe to do anything until it is either IN or Out.  In this setup, it is considered safe to do something, when the limit switch IS Tripped.

Lets think about this.  In the OUT position, the machine is safe to run (with regards to the carosel anyway).  If I wire this LS normally closed, this means that when the carosel is OUT, the signal from this limit switch is OFF.   Heres where I disagree with the safest way to consider this.  If the wire is broken, is it more likely to short to a high signal, be cut clean, or be shorted to ground?  All are possible with the cut clean and shorted to ground being by far the most common.  With that said, if we use NC contact, we will be fooled into thinking the carosel is out anytime we have a circuit fail.  For example, the carosel is not quite all the way out and it is not safe to run the machine.  The out LS wire has broken.  We can monitor the IN LS but this only tells us that it is somewhere besides completely IN.  Not enough information.  My broken wire on the OUT LS indicates its OUT but it is not.

Peter mentioned above
"Using a normally closed circuit, the input circuit  is closed in the normally operating condition"

This is only relavent to a STOP circuit. When talking about LS, this statement would be exactly backwards if you were using NC contacts.  Normally Closed means that the contacts are closed when the switch is NOT activated.  In our Carosel example, the safe zone is when the switch IS activated.

Peter went on to say:
"When the limit switch is hit and opened the input is activated."

But this is only because you inverted the logic on the controller (mach3).  The actual input is deactivated and software flips this logic.

"The advantage of this system is that the limit input will also be activated if a wire breaks or a connector becomes unplugged."

In my opinion, this is absolutely the un-safest way to do this.  If a wire breaks or a connector becomes unplugged, this setup tells the controller that the carosel is against the OUT LS when in fact, it could be anywhere in the middle.  This is the essence of what I am getting at.

I think there is a lot of confusion between a Safety Stop Circuit and the use of Limit Switches.  Limit Switches are not saftey stop ciruits and are rarely wired in series with other components except when using a manual switch to activate some thing.  Generally, this is not what we are doing.  We are wiring a LS to a controllers input to determine if something is safe to move or not.  Its our job to try to predict the likely failures such as broken wires, and stuck limit switches.  I argue that in the carosel example, using NO contacts is a more reliable solution as it actually does catch the broken wire problem.  I think it comes down to this.
The input should be ON (actual input and not inverted by software) when the "thing" in question is in a safe operating position.  With that being said, on these types of machines, there are two different things going on.

X,Y and Z limit swithes are used to indicate that the axis is between limits and thus should provide a High signal when not on one of the limit switches.  Therefore, we should use N.C. contacts.  If a wire breaks, it indicates that a limit is tripped and we stop the machine.
Carosel In/Out, Carosel rotate fwd/rev, gear boxes, tool change.....these limit switches are used to indicate that something is exactly where it should be and should provide a High signal at that point.  Its only safe, when we are actually on these limit switches, so they should be wire using the N.O. contacts in my opinion.

This is how I wired my machine.  Almost all the documentation I read issues blanket statements about using N.C contacts when in fact, there are three primary situations to consider and they all three are different.  Stop circuits, LS used to declare its unsafe when tripped, and LS used to declare its unsafe when Not tripped.


Offline Davek0974

*
  •  2,606 2,606
    • View Profile
    • DD Metal Products Ltd
Re: Normally Open VS Normally Closed
« Reply #5 on: August 11, 2016, 10:16:53 AM »
I always try to wire my stuff with e-stop being N/C for reasons all have mentioned, all my input signals - buttons, homing, in your example the tool carousel position sensors I would always wire N/O so that a signal is provided to show intention - a button pressed, a proximity sensor in range of target, the tool carousel being in or out but not both or neither (needs logic here, OR gate i think).

Thats how i do stuff and it seems to make sense, rarely will a short circuit on an input be able to create a 24v signal, more likely short to chassis or just go open circuit so its a pretty safe system.

JMHO ;)
Bridgeport Mill, Mach3 V062, CSMIO-IP/A controller, AC Servo Drives.
Plasma table, Mach3 V062, Step motors, C&CNC THC.
Re: Normally Open VS Normally Closed
« Reply #6 on: August 11, 2016, 12:03:22 PM »
One of the reasons I brought all this up was the consideratiion of predicting failure.  I recently converted a Haas VF1 to Mach3.  Coming down the home stretch to finish it up.  Took my first cuts last week and all is good.

Whats missing is refining the software to be smart and look for failed components.  I.E.  broken wires, stuck limits....

All of my basic functions work great as long as nothing goes wrong.  Have to go back now and myticulously study the macros and put in all the things to catch failures.  This is what got me thinking about this topic.

We discussed the broken wire but what about a stuck limit switch.  Very common.

The software should have tons of checks in it.  In the carosel example, and using N.O. contacts for the In and Out LS, we should be looking at several things and not just firing an output and looking for an input.
Example:
Carosel is Out and I want to send it in to do a tool change.  Out LS is ON and IN LS is off.  This should be the first check in the program.  Confirm current state.  Turn on Output to send it in, wait to see the IN LS come on.  Confirm the Out LS cut off.  Add a time limit for all this to happen.  Repeat for sending it Out.
This will catch broken wires and stuck limit switches.  My current macros only fire an output and look for the input.  No other checks.  It would be really easy to leave it like this and hope for the best.  Matter of fact, I bet a bunch of folks have done this.  Anyhoo, my macros are about to double in size.  Hope some of this is helpful to others.
Re: Normally Open VS Normally Closed
« Reply #7 on: August 11, 2016, 01:02:04 PM »
Again, I don't see a need to make major changes to the macro.  No matter if it's NO or NC, due to the configuration of ACTIVE LOW for NO or ACTIVE HIGH for NC the logic in the macro would be the same.  If <switch active> THEN <do something> or IF <switch inactive> THEN <do something different>.  You could also use IF <switch active> THEN <do something> ELSE <do something different>; or even IF <switch inactive> THEN <do something different> ELSE <do something>.

The bottom line is the wiring does not change your macro logic as long as you have the configuration set in Ports and Pins to handle it appropriately.

Highspeed
Re: Normally Open VS Normally Closed
« Reply #8 on: August 11, 2016, 01:39:44 PM »
I understand exactly what you are saying.  My major changes to my macro are not related to that.  I was trying to say that I got the machine working and it would be very easy to just go make some chips.  Adding lines of code to catch all the possible hick ups can be quite involved when done correctly. 

For example, with my carosel above, the first thing to do is to verify its actually in the OUT position by looking at both LS signals.  My current program does not do this because I was trying to just get it to work.  This one check at the beginning will be added lines of code with some way to end the routine and send appropriate message that it ended because of this.  Or maybe you choose not to End the routine but perhaps try to send it Out and see if the LS states can be verified and maybe you continue with the task.  Maybe not.  Then on to the next check, fire the output for x number of seconds (again, my code does not yet do this), look for IN LS, double check that Out LS changed state and check that the the timer didn't expire.  Add lines of code for each of these checks.  End routine and send error message that clearly states why it ended.  Decide if you are going to leave that carosel somewhere between the LS's or do you try to send it back out.   

So my point being that in this case, we haven't even gotten to changing the tool and there's quite a bit to think about and write code.  Then test and besure the darn macro doesn't get hung up somewhere.  Had my VB programming skills not been 25 yrs sitting on a shelf, perhaps I would have put all this stuff in the first time.  Very glad I did not as I was able to get things going in a piece by piece way.  Now to do the right thing and finish it correctly.

Offline Davek0974

*
  •  2,606 2,606
    • View Profile
    • DD Metal Products Ltd
Re: Normally Open VS Normally Closed
« Reply #9 on: August 11, 2016, 01:47:29 PM »
I would simply send the carousel out, with a timer loop of maybe 2s - if it does not hit the out switch within that time then fault out of the macro with a message on screen.

No second chances - you never know why it did not hit the limit so not worth the risk of trying again, it won't fix itself ;)

The rest of it is simple if-then loops etc and some friendly informative screen messages.
Bridgeport Mill, Mach3 V062, CSMIO-IP/A controller, AC Servo Drives.
Plasma table, Mach3 V062, Step motors, C&CNC THC.