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...

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

446 Program Control <strong>Instructions</strong> (JMP, LBL, JSR, RET, SBR, JXR, TND, MCR, UID, UIE, AFI, NOP, EOT, SFP, SFR, EVENT)Example 1:The JSR instruction passes value_1 and value_2 to routine_1.The SBR instruction receives value_1 and value_2 from the JSRinstruction and copies those values to value_a and value_b,respectively. Logic execution continues in this routine.The RET instruction sends float_a to the JSR instruction. The JSRinstruction receives float_a and copies the value to float_value_1.Logic execution continues with the next instruction following the JSRinstruction.Relay LadderRoutine:Main routineProgramSubroutine[other rungs of code]Structured TextRoutineMain routineSubroutineProgramJSR(routine_1,2,value_1,value_2,float_value_1);SBR(value_a,value_b);;RET(float_a);Publication 1756-RM003I-EN-P - January 2007

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

Saved successfully!

Ooh no, something went wrong!