Jump to content
OMRON Forums

Non-existent G/M-codes


wbzhong

Recommended Posts

When user specifies a non-existent G/M-codes, i.e. the jump label is not defined in the G/M subprogram, PMAC will execute the command from the top of G/M subprogram.

I can catch the error at the top, but how can I know which code does the user specified, i.e. the jump label?

Link to comment
Share on other sites

I am not aware of a "built in" way to read this. PMAC might store the line number as an L Variable inside the calling function, which in turn means it would be accessible as the same-index R Variable inside the called function. However, if that is not the case, it may not be possible without modifying the calling function, which likely isn't a viable solution.

  • Thanks 1
Link to comment
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.

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