kwaltzer (Customer) asked a question.

High NO bit not turning on ouput.

Please look at the snapshot of the ladder logic. Im lost as to why the Siren set coil will not turn on with the alarm bit is high.

 

I have this set up on a similar program for another machine that will turn on the set coil, even forcing the other alarm bits high doesnt turn on the coil.


  • PouchesInc (Customer)

    You cannot use set and reset along with out coils of the same output, bit, tag, or whatever in any PLC.

    • Tinker (Customer)

      I'm not so sure one "cannot" use SET, RST and OUT on the same output. Think of stages or subroutines that are not intended to be active at the same time. But I think one should not. I can't think of any good reason to, and even if there were a case where it seemed to have some use, the confusion it could cause in the future would be a good reason to find another way.

       

      The OUT is what is causing the problem in this case, since it is the last thing operating on the SIREN coil (in this sample anyway) it will override whatever the SET or RST have done.

       

      "I have this set up on a similar program for another machine that will turn on the set coil,"

      Maybe you have a typo? maybe the OUT is supposed to acting on different coil?

       

      I don't use Productivity, what does the blue background mean? does it indicate the code isn't running? if so, then yes, the SET won't turn on the coil if the code isn't executing , but even if it were running the OUT would override the SET.

      Expand Post
      • kewakl (Customer)

        Task background is user configured. It has no significance to the project's operation.

  • RBPLC (Customer)

    It's probably because the background is blue.

  • kewakl (Customer)

    Do your observations indicate the the output follows the state of 'MLD Idle Alarm?"

    If so, the OUT instruction, being the last functional instruction wins the contention.

     

    Think back, if you have ever had the pleasure to watch Ron Beaufort's PLC Bootcamp series...

    (Let's forget about turning on/off address space registers and think about the 'bitbox' on which the instruction is working. That bitbox has the name 'Siren')

    [If the logic is being scanned] [OVERSIMPLIFIED DESCRIPTION FOLLOWS]

    SET 'puts a "1" in the bitbox,' ONLY when the rung logic is true. (In your case ONLY when the rung logic GOES true.)

    RST 'puts a "0" in the bitbox,' ONLY when the rung logic is true.

    OUT puts the state of the rung logic into the bitbox on every scan.

     

    Now, think about the order of stuffing boolean values into that bitbox.

    If the SET rung logic evaluates to a 1 being put into that bitbox, you have a TRUE state. (In your case you have a ONESHOT SET, so only the IMMEDIATE FALSE-TO-TRUE transition of rung logic causes this bitbox to be stuffed with a '1'.)

    Later, if the RST rung logic evaluates to a 1 being put into the bitbox, that previous '1' is changed to a '0' for a FALSE state.

     

    Now, regardless of what has come before, we MUST look at the OUT instruction.

    OUT ALWAYS puts its rung logic into the bitbox REGARDLESS of rung logic evaluating to a true.

     

    The OUT instruction is last in the rung scanning and therefore wins the contest.

     

    Note that all this happens before you actually use the value in the bitbox 'Siren,' so you do not see the interaction between these contentious control output instructions.

     

     

    [edit: whitespace, typo, clarification]

    Expand Post
  • kwaltzer (Customer)

    . .......Ok yeah so I was mistaken and It wasnt the same on the other program. To many early mornings and late nights are starting to affect the grey matter between my ears.

     

    The blue background doesnt indicate anything. I changed it because its easier on my eyes than the white and I find it easier to see the color changes on the ladder logic when monitoring.

     

    Appreciate your time thanks.

    Expand Post