Jump to content
CFBFP

How to change the instruction RET (return from subroutine), can't edit

Recommended Posts

Hi

 

at the end of each subroutine in the ladder program you find "RET". You can't move it to the right or place it somewhere else.

I want to conditionally return from a subroutine, but I can't move this object to insert a condition.

Why is it? How then to conditionally return from a subroutine?

 

f.

Share this post


Link to post
Share on other sites

The one listed in the subroutine may be required by the software, but you should be able to add additional RETs to the subroutine.

 

Have you tried adding an additional rung with your conditions and adding a second RET function to it?

 

Reference Page 34 of the Ladder Programming PDF, or the help system in visilogic shows an example of what I mean.

Share this post


Link to post
Share on other sites

I'm curious as to the logic you are using that would require a conditional RET? This invites the possibility of a Watchdog Timer alarm. You might consider a variation with conditional CALL of the Subroutine instead.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...