12.07.2015 Views

Logix5000 Controllers General Instructions - SLAC Confluence

Logix5000 Controllers General Instructions - SLAC Confluence

Logix5000 Controllers General Instructions - SLAC Confluence

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

324 Move/Logical <strong>Instructions</strong> (MOV, MVM, BTD, MVMT, BTDT, CLR, SWPB, AND, OR, XOR, NOT, BAND, BOR, BXOR, BNOT)Example 1:This example ORs bool_in1 and bool_in2 and places the resultin value_result_or.If BOOL_IN1 Is If BOOL_IN2 Is: Then VALUE_RESULT_OR Is:0 0 00 1 11 0 11 1 1Structured Textvalue_result_or := bool_in1 OR bool_in2;Function BlockExample 2:In this example, light1 is set (on) if:• only bool_in1 is set (true).• only bool_in2 is set (true).• both bool_in1 and bool_in2 are set (true).Otherwise, light1 is cleared (off).Structured TextIF bool_in1 OR bool_in2 THENlight1 := 1;ELSElight1 := 0;END_IF;Publication 1756-RM003I-EN-P - January 2007

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!