Jump to content

Welcome to eMastercam

Register now to participate in the forums, access the download area, buy Mastercam training materials, post processors and more. This message will be removed once you have signed in.

Use your display name or email address to sign in:

Embed a post with a # variable.


Recommended Posts

I am having a program forcing a post to post a macro statement, since posting the # will hide anything behind it on that line. Is there a way to actually post it? 

 

I would like at the beginning of the program to look like this. Basically I am trying to automate having the program number being saved into the control. I can use manual entry, but I would prefer to have the statement higher up instead of so far down in the beginning. I also do not want to have add in the manual entry for every program we will be doing. 

 

 

 

%

O1122 ( PROGRAM )

#602=1122

Link to comment
Share on other sites


pheader$ #Call before start of file

hour = int(time$)

min = int((time$ - hour)* 100)

if hour > 12, hour = hour - 12

if hour = 0, hour = 12

year$ = year$ + 2000

 

"%", e$

spaces$=0

*progno$, " ", scomm_str, sprogname$, scomm_end, e$

"#602=1122", e$ # <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<add here after *progno$ line

spathnc$ = ucase(spathnc$)

smcname$ = ucase(smcname$)

comment$ # File descriptor

spaces$=0

 

 

Link to comment
Share on other sites

pheader$         #Call before start of file                         
      hour = int(time$)
      min = int((time$ - hour)* 100)
      if hour > 12, hour = hour - 12
      if hour = 0, hour = 12
      year$ = year$ + 2000

      "%", e$
      spaces$=0
      *progno$, " ", scomm_str, sprogname$, scomm_end, e$
      "#602=1122", e$  #  <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<add here after *progno$ line  
    spathnc$ = ucase(spathnc$)
      smcname$ = ucase(smcname$)
      comment$  # File descriptor
      spaces$=0

Thanks for the response Tim

 

This is a pre X version Post. So it is not using all the '$'

 

I have tried so many versions and layouts to figure how to post the comment as I need. I did find in the fanuc manual to make this easier. The program number is saved under #4000. So it does not need to post the prog no, instead it can read #602=#4000

 

So I guess the questions is now, is there a way to force the pound# sign no matter what, with [] or something? Might be futile do to the older version. But worth a try.

 

 

 

 

Link to comment
Share on other sites

Yeah, we're going back a decade or so...

 

try;

 

35, no_spc, 602=, no_spc, 35, no_spc, 4000, e

 

Tried this as typed, and with no space. was not sure if you meant either way. But just get an alarm on this line. Currently "Variable not defined: no_spc"

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.

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.

Join us!

eMastercam - your online source for all things Mastercam.

Together, we are the strongest Mastercam community on the web with over 56,000 members, and our online store offers a wide selection of training materials for all applications and skill levels.

Follow us

×
×
  • Create New...