24.01.2015 Views

PLC Programming

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

5 - Editors in CoDeSys<br />

'Insert' 'Parallel Branch (right)'<br />

Symbol:<br />

Shortcut: +<br />

This command inserts a parallel branch in the SFC editor as the right branch of the marked block. For<br />

this the marked block must both begin and end with a step. The new branch is then made up of one<br />

step. To allow jumps to the parallel branches that have been created, these must be provided with a<br />

jump label.<br />

'Insert' 'Parallel Branch (left)'<br />

Symbol:<br />

'Insert' 'Jump'<br />

'This command inserts a parallel branch in the SFC editor as the left branch of the marked block. For<br />

this the marked block must both begin and end with a step. The new branch is then made up of one<br />

step. To allow jumps to the parallel branches that have been created, these must be provided with a<br />

jump label (see 'Extras' 'Add label to parallel branch').<br />

'This command inserts a jump in the SFC editor at the end of the branch, to which the marked block<br />

belongs. For this the branch must be an alternative branch.<br />

The inserted text string 'Step' in the inserted jump can then be selected and replaced by the step<br />

name or the jump label of a parallel branch to be jumped to.<br />

'Insert' 'Transition-Jump'<br />

Symbol:<br />

This command inserts a transition in the SFC editor, followed by a jump at the end of the selected<br />

branch. For this the branch must be a parallel branch.<br />

The inserted text string 'Step' in the inserted jump can then be selected and replaced by the step<br />

name or the jump label of a parallel branch to be jumped to.<br />

'Insert' 'Add Entry-Action'<br />

With this command you can add an entry action to a step. An entry-action is only executed once, right<br />

after the step has become active. The entry-action can be implemented in a language of your choice.<br />

A step with an entry -action is designated by an "E" in the bottom left corner.<br />

'Insert' 'Add Exit-Action'<br />

With this command you can add an exit-action to a step. An exit-action is only executed once, before<br />

the step is deactivated. The exit-action can be implemented in a language of your choice.<br />

A step with an exit-action is designated by an "X" in the lower right corner.<br />

'Extras' 'Paste Parallel Branch (right)'<br />

This command pastes the contents of the clipboard as a right parallel branch of the marked block. For<br />

this the marked block must both begin and end with a step. The contents of the clipboard must,<br />

likewise, be an SFC block that both begins and ends with a step.<br />

'Extras' 'Add label to parallel branch'<br />

In order to provide a newly inserted parallel branch with a jump label, the transition occurring before<br />

the parallel branching must be marked and the command 'Add label to parallel branch' must be<br />

executed. At that point, the parallel branch will be given a standard name consisting of „Parallel" and<br />

an appended serial number, which can be edited according to the rules for identifier names. In the<br />

following example, "Parallel" was replaced by "Par_1_2" and the jump to the transition "End" was<br />

steered to this jump label.<br />

CoDeSys V2.3 5-31

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

Saved successfully!

Ooh no, something went wrong!