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.

Structured Text Programming 661Term Definition Examplesconstruct(see page 28-671)A conditional statement used to trigger structured text code (i.e, otherstatements).Terminate the construct with a semi colon “;”.IF...THENCASEFOR...DOWHILE...DOREPEAT...UNTILcomment(see page 687)Text that explains or clarifies what a section of structured text does.• Use comments to make it easier to interpret the structured text.• Comments do not affect the execution of the structured text.• Comments can appear anywhere in structured text.EXIT//comment(*start of comment . . .end of comment*)/*start of comment . . .end of comment*/AssignmentsUse an assignment to change the value stored within a tag. Anassignment has this syntax:tag := expression ;where:ComponenttagDescriptionrepresents the tag that is getting the new valuethe tag must be a BOOL, SINT, INT, DINT, or REAL:= is the assignment symbolexpression represents the new value to assign to the tagIf tag is this data type: Use this type of expression:BOOLBOOL expressionSINTnumeric expressionINTDINTREAL; ends the assignmentPublication 1756-RM003I-EN-P - January 2007

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

Saved successfully!

Ooh no, something went wrong!