Sign in to follow this  
Followers 0
vanilla_gorilla

SQC and Multiple conditions

10 posts in this topic

Ok, guys, let me try and explain this one and see what feedback I get. Background :- Machine that is basically a sequencer. I need a multiple condition for the first rung........ Lets say steps 2-10 are always the same based on the input. First "input" step in the sequence for example will run if sensor A is made. (signalling a succesful operation) or if operator triggers an input (lets say sensor A didnt make on the last sequence and the operator has to reset, so the sensor never made, or the operator is starting with "no part" in the machine) Hope you can follow..... I know I could write a seperate subroutine SQC based on operator "reset", BUT I am exploring alternatives.... One thought I had was moving a new "first step" into the sequencer based on the operator reset, and then dumping the original first step back in there after the "first succesful" sequence completion. Cheers

Share this post


Link to post
Share on other sites
I think I need a picture on this one. I'm not following

Share this post


Link to post
Share on other sites
Yeah I know its hard to follow.........Ill try again......... Sequence starts on an operator PB as long as a part is in the nest...... If the machine is starting for the day or if an operator stops the machine mid cycle, there is no part in the nest. (and hence sensor is not made) (normal sequence would start with the part present sensor on) Either condition I need to have the machine cycle.... Operator has a "GO" button and a "RESET" button..... Clear as Mud !! Just the first SEQ line is different is both cases..... (One ignores the Part Present, 1 looks for it)

Share this post


Link to post
Share on other sites
So am I understanding correctly that one of your sequence inputs needs to be true if either there is a part present and the GO button is pressed or when there is not a part present and the RESET button is pressed?

Share this post


Link to post
Share on other sites
We're close !! Either there is a part at the part present (normal condition) and they hit the GO or there is no part there and they hit the GO (after hitting reset first, dont have to, but is an option). Right now the SQC is looking for the sensor on the first line of the sequence (so its looking for a "1", lets say on N7:0/1) and I want it to go if the sensor is made or not...... If I put a "0" as a condition at N7:0/1 in the SQC then obviously (I am assuming) if the sensor is made then SQC isnt true and the machine wont cycle. (Same is true currently with a "1" in N7:0/1, if it sees a 0, the sensor NOT made, then it wont process) Hope that helped a little more.....

Share this post


Link to post
Share on other sites
Ok I think I am getting closer. Do you want to completely remove the part present sensor from the sequencer or just from the 1st step of the sequencer? Or am I lost again

Share this post


Link to post
Share on other sites
I guess it boils down to the fact that I dont care if the part sensor is made or not really (the machine stops at this point as the end of the sequence and waits for the operator "GO"). I just need to be able to satisfy the "OR" condition as the first step in the SEQ (Other things in the sequence are going on here that dont relate to the issue I am trying to resolve), or have the SQC ignore the sensor state at this point. (But putting a "0" in the SQC makes the PLC look for that "ON" condition) Hope I'm helping here !!

Share this post


Link to post
Share on other sites
Have a look at THIS download and see if your SQC looks similar to Rung 2 of the Main Routine except the B9 is replaced with N7. This is not the cleanest sample but it may help. If you wanted to change the state the sequencer was looking for in step one you would change B9:1/0 (N7:1/0) and not B9:0/0 (N7:0/0). Now the problem with doing this is the Part Present sensor must now always be not made. I think this might be what you are running into. From here you have 3 choices 1. Put a branch around the Part present input feeding the Sequencer. The problem with this is if there was a point you need to see a transition of the sensor this will not work 2. 1. Put an AFI (Always False Input) behine the Part present input feeding the Sequencer. This presents the same problem as solution 1 3. Without seeing your program and knowing your process I would put a branch around the part present input feeding the sequencer and put an EQU instruction in the branch with source a being R6:0.POS and source b being 1. Replace R6:0 with whatever your sequencer control is. This will cause the sequencer only to ignore the part present switch during position 1 of the sequencer. Am I getting any closer

Share this post


Link to post
Share on other sites
Think we are making some headway !! 1 and 2 wont work...(I look at the same sensor in other positions in the sequence) Option 3 may get me to where I am going, not sure yet.... There really is no branch with the "sensor" in it. The entire 16pt input card is mapped to N7:0 and the seq is looking at those inputs. The "GO" button is one of those bits, as is the present sensor etc. (The sequencer is always "live") I should be able to move a new STEP1 sequence into N7:0 if I force the operator to hit RESET before GO if no part is present ? Reset loads a "0" into the Part present "bit" for seq1, operator hits start, line 1 seq is true because part present is not made. Machine does its cycle...When R6:0.DN is true load the original 16 bits back in FOR SEQ1 into N7:0 ???

Share this post


Link to post
Share on other sites
You can still alter the values going into N7:0. On the rung after the MOV that puts the inputs in N7:0 put the EQU statement we talked about earlier then a MVM statement but mask all the bits but the part present and move the value you need to N7:0 that way

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0