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:

@Mastercam

Customers
  • Posts

    79
  • Joined

  • Last visited

Posts posted by @Mastercam

  1. 16 hours ago, Alex Dales said:

    this is controlled by the variable rot_type which should be set by the MD.

    If you suspect your MD is not being read in, you can go directly to where its initialized and try changing the starting value to 2 and test this out. If the MD is not being read, then this will make the post use shortest direction.

    If that doesn't give you shortest direciton, the the MD is still over writing. You will want to check your MD settings and make sure they were saved properly, and be sure to re-load your machine definition into the part (mcam files hold the state of the machine and control definition the last time the file was saved and do not actively read in the changes made to the MD and CD) 

    Here is a link to our website for more on reloading machine definitions. http://www.inhousesolutions.com/2015/11/reloading-machine/

    If none of that works, you could try defining rot_type as a global formula by changing the initalization from rot_type : 2 to rot_type = 2. I wouldn't necessarily advise this especially if you haven't exhausted all the above options, but it *should* work :)

    Thank you Mr. Alex  😀 

    • Like 2
  2. 11 hours ago, crazy^millman said:

    Rotating the Plane give you what you needed? 🤔

    By Rotating  plane is a secondary solution. 
    In Generic post C zero is at 12 clock position for Lathe - Looking from front  &  For VTL C  zero at 9 clock position - Looking from Top .  But i need this C zero at 3 clock position.  
    so i made change in MD  c-axis but it is not working.

    For reference, I've attached some of images...….

     

    image.png.c485816458d93c49b6a19f5017543cfb.png

    Honor_seiki_VTL_Caxis_For_FACR_DRILL.png

  3. 21 hours ago, crazy^millman said:

    Take you [top-1] plane and rotate it 90 degrees and regenerate the operation. I got this:

    
    %
    O0000
    (PROGRAM NAME - T2)
    (DATE=DD-MM-YY - 13-02-21 TIME=HH:MM - 07:30)
    (MCX FILE - C:\USERS\RON\DOCUMENTS\MY MASTERCAM 2021\MASTERCAM\PARTS\VTL C AXIS SETTING.MCAM)
    (NC FILE - C:\USERS\RON\DOCUMENTS\MY MASTERCAM 2021\MASTERCAM\LATHE\NC\T2.NC)
    (MATERIAL - ALUMINUM MM - 2024)
    G21
    (TOOL - 8 OFFSET - 8)
    ( 10. FLAT ENDMILL)
    G0 T0808
    G17
    M23
    G0 G54 X46. Z5.
    C110.
    G97 S1145 M52
    G81 Z0. R2. F229.
    C155.
    G80
    G28 U0. V0. W0. H0. M55
    T0800
    M30
    %

    Generic post might not give you what you need. I am afraid you going to have to reach out to your dealer and get a custom post for what you need. I tried switches in the post and nothing seemed to give me what your after. I haven't messed with post in years I leave it to the professionals and focus on other work.

    Thank you so much !

  4. 4 minutes ago, crazy^millman said:

    I stand corrected the post has not been modified I apologize for making that assumption.

    Okay since you shared your file I will try to help you get it.

    We are looking in the Post for psccomp as the output variable.

    We first see it called in the ltlchg$ section of the post. This the first block called when changing tools or making a program. We see it in this section.

    
    ltlchg$          #Toolchange, lathe
          toolchng = one
          gcode$ = zero
          copy_x = vequ(x$)
          pcc_capture   #Capture LCC ends, stop output RLCC
          c_rcc_setup$  #Setup LCC on first 60000
          plcc_lead_begin  #Save original in sav_xa and shift copy_x for LCC comp.
          pcom_moveb    #Get machine position, set inc. from c1_xh
          c_mmlt$       #Position multi-tool sub, sets inc. current if G54...
          ptoolcomment
          comment$
          if home_type < two, #Toolchange G50/home/reference position
            [
            sav_xh = vequ(copy_x)
            sav_absinc = absinc$
            absinc$ = zero
            pmap_home   #Get home position, xabs
            ps_inc_calc #Set start position, not incremental
            #Toolchange home position
            if home_type = one,
              pbld, n$, *sgcode, pfxout, pfyout, pfzout, e$
            else,
              [
              #Toolchange g50 position
              pbld, n$, *sg28ref, "U0.", [if y_axis_mch, "V0."], "W0.", e$
              toolno = t$ * 100 + zero
              if home_type = m_one, pbld, n$, *sgcode, *toolno, e$
              else, pbld, n$, *sg50, pfxout, pfyout, pfzout, e$
              ]
            pe_inc_calc #Update previous
            absinc$ = sav_absinc
            copy_x = vequ(sav_xh)
            ]
          toolno = t$ * 100 + tloffno$
          pbld, n$, *sgcode, *toolno, e$
          pbld, n$, pfsgplane, e$
          pcaxis_off_l  #Postblock for lathe transition
          pcom_moveb    #Reset machine position, set inc. from last position
          pcan
          pspindle
          if opcode$ <> 106 | (opcode$ = 106 & suppress_point_spindle = no$),  #Do not enable spindle for point toolpath
            [
            if css_actv$,
              [
              if css_start_rpm, prpm  #Direct RPM startup for programmed CSS
              else, pcssg50, pcss  #NO RPM start - just output the CSS
              ]
            else, prpm  #Direct RPM was programmed
            ]
          sav_absinc = absinc$
          if home_type > one, absinc$ = zero
          pcan1, pbld, n$, psccomp, *sgcode, pwcs, pfxout, pyout, pfzout,
            pscool, strcantext, e$
          plcc_lead_end #Use sav_xa to position with comp. LCC
          pcom_movea    #Update previous, pcan2
          ps_inc_calc   #Reset current
          absinc$ = sav_absinc
          if (opcode$ <> 106 | (opcode$ = 106 & suppress_point_spindle = no$)) & css_start_rpm,  #Do not enable spindle for point toolpath
            pcssg50, pcss  #CSS output AFTER a G97S???? RPM spindle startup
          c_msng$        #Position single-tool sub, sets inc. current if G54...
          toolchng = zero
          !op_id$, !lturret$, !tool_op$, prv_millcc = zero
          prev_spindle = spindle_no$  #Save spindle used in this operation

    I like to copy the line or lines of code and then paste them into my post keeping the original post blocks like they were for reference.

    
    #      pcan1, pbld, n$, psccomp, *sgcode, pwcs, pfxout, pyout, pfzout,
    #        pscool, strcantext, e$
    
          pcan1, pbld, n$, *sgcode, pwcs, pfxout, pyout, pfzout,
            pscool, strcantext, e$ #RDB 2-11-21 Removed psccomp

    I then test the post and see where the G41/G42 get output to see if that moves it to where I want. Now we have created a big mess and don't get good output. We have different options, but none of them are what I would consider acceptable and worth spending anymore time on.

    
    %
    O0000
    (PROGRAM NAME - T)
    (DATE=DD-MM-YY - 11-02-21 TIME=HH:MM - 07:29)
    (MCAM FILE - C:\USERS\RON\DOCUMENTS\MY MASTERCAM 2021\MASTERCAM\PARTS\CUTTER COMPENSATION TEST.MCAM)
    (NC FILE - C:\USERS\RON\DOCUMENTS\MY MASTERCAM 2021\MASTERCAM\LATHE\NC\T.NC)
    (MATERIAL - ALUMINUM MM - 2024)
    G21
    (TOOL - 12 OFFSET - 12)
    (OD RIGHT 55 DEG  INSERT - DNMG 15 06 08)
    G0 T1212
    G18
    G97 S2136 M03
    G0 G54 X43.951 Z5.3 M8
    G50 S3600
    G96 S295
    G99 G1 Z3.3 F.2
    Z-59.864
    X46.447
    G18 G3 X46.847 Z-60.064 K-.2
    G1 Z-97.155
    G40 X49.676 Z-95.741
    G0 G42 Z5.3
    X41.055
    G1 Z3.3 F.2
    Z-59.864
    X43.951
    G40 X46.78 Z-58.45
    G0 G42 Z5.3
    X38.159
    G1 Z3.3 F.2
    Z0.
    Z-59.864
    X41.055
    G40 X43.884 Z-58.45
    G0 X46.247
    G28 U0. V0. W0. M05
    T1200
    M01
    (TOOL - 21 OFFSET - 21)
    (OD FINISH RIGHT - 35 DEG.  INSERT - VNMG 16 04 08)
    G0 T2121
    G18
    G97 S2487 M03
    G0 G54 X37.759 Z2.
    G50 S3600
    G96 S295
    G1 Z0. F.2
    Z-60.064
    X46.447
    Z-97.155
    G40 X49.276 Z-95.741
    G28 U0. V0. W0. M05
    T2100
    M30
    %

    I have what I call the Vanilla, Chocolate, Strawberry things people want. End of the day if it makes a good parts and get the job done then be happy you can do so and this will be one of those instances where sorry you get what you are getting. Want something super custom then reach out to your dealer and get a custom post because because of the way you want to see it. I tested this with about 5 different free lathe posts and they all do the same thing. Only my custom posts do what your asking for.

    Sorry I couldn't be of more assistance, but thank you for showing your a legitimate user of Mastercam.

    Thank you for quick response 😊

  5. 1 hour ago, crazy^millman said:

    Okay post a Z2G and then we can see what you're seeing. I have never seen the default Lathe post put the G41 there so that is new and not sure why you're seeing it. Only way to know is to have a copy of everything to then see why.

    i've attached post & project .  Default output for G41/G42 is in rapid block , But we need in linear block.....

    Cutter Compensation Test.mcam

    MPLFAN.mcam-content

  6. 6 hours ago, nickbe10 said:

    This will require some fairly straight forward post modification.

    Will need to know your base post and what you want it to look like.

    i'm using Default MPLFAN for MC2021

    5 hours ago, crazy^millman said:

    Looks like someone messed with your post. I have never seen G41 come out like that. Reload the Generic post and see what it does. If that is correct then do a file compare to correct the mistake someone made with the post.

    No one has modify the post . Only our requirement is G41/G42 should be come in Linear blocks only .  
    if possible could you please help me to fix this. 

  7. On 9/15/2020 at 4:16 AM, Zaffin_D said:

    The following regex will match M1000 - M1099

    
    \bM10[0-9][0-9]\b

    Here is a link to it being checked against common M-codes  

    As far as what language is used; in this case it probably doesn't matter.  They all should support what you are trying to do.  One difference I'm aware of is the the C++ standard library regex implementation doesn't support lookbehind.  I think this goes for javascript also, but google will have a better answer if you care to get into the minutiae.

    Hi,

    can you give me regex  Sync code  range from M01- M1000 

  8. On 7/9/2020 at 6:50 AM, Zaffin_D said:

    The above regex has some holes in it. 

    Here is a better one...

    
    \bM([1-9][0-9][1-9]|[1-9][1-9][0-9]|[2-9][0-9][0-9])\b

    ...and here is the regex being tested against some common M-codes. 

    \bM([1-9][0-9][1-9]|[1-9][1-9][0-9]|[2-9][0-9][0-9])\b   { Current range is  101-999}

    Hi, 

    How i can increase the range to 1000-1099 

    Regex Programming Language- 

    1. Python 

    2.Java

    3. Javascript

    4.PHP

    5.c/c++ 

     

    Which Programming Language is used to Creating regex for Mastercam ?

  9. On 7/8/2020 at 11:53 PM, JoshC said:

    please try this. 

    1. if you search the start menu for “choose a default app for each type of file” you should see that under system settings as I show in the first image below

    1.png

    2. From there you should be able to set the .mcam file extension to open with McamVersionSelecter executable

    2.png

    Facing the same issue after fixing that before a couple of months .

    • Like 1
  10. hello, 

    Is it possible to manipulate Manual entry output as per requirements. Kindly refer below example.

    %
    O0000
    (TOOL - 12 OFFSET - 12)
    (OD RIGHT 55 DEG  INSERT - DNMG 15 06 08)
    G0 T1212
    G18
    G97 S1724 M03
    G0 G54 X54.469 Z4.5 M8
    M101   header position required 
    G50 S3600
    G96 S295
    G99 G1 Z2.5 F.2
    Z-65.577
    X57.767
    X60.595 Z-64.162
    G0 Z4.5
    X47.873
    X50.701 Z-64.162
    G0 X58.767
     0.  (  M101 footer position required  but getting 0 value ) 
    G28 U0. V0. W0. M05
    T1200
    M30
    %

    manual entry.png

  11. Thank You Sir, 

    # Create a variable named 'tool_num'.
    	  # Format as "integer"
    	  if t$ < 10, tool_num = t$ * 1000 #Convert to 1000's
    	  if t$ > 9 & t$ < 100, tool_num = t$ * 100 #Convert to 100's
    	  if t$ > 99 & t$ < 1000, tool_num = t$ * 10 #Convert to 10's place
    	  if t$ > 999, tool_num = t$
    	  pbld, n$, *tool_num, sm06, e$

    above script i have already implemented . My intention is there should provision in fs2 

    For example program number -   fs2 7 4 0 4 0l  #Integer, force four leading

    when i enter program no 1 output is O0001 ( Right - Left  ).

    Program no. fs2  is completely  reverse in my case. ( output should be  - O1000 )  

     

  12. Hello, 

    Is there any way to added trailing zero base on input  in fs2 

    fs2 7   0 4 0 4t     #Integer, force four trailing 

    fmt  "T"  7  t$

    when i gives input to tool no. as below

    input - output to be accepted 

    1 - T1000  ( single digit input ) 

    11- T1100 ( two digit input )

    101 - T1010 ( Three digit input )

    T1000 - T1000 ( 4 digit input ) as it's.

    to meet above requirement. Any suggestion in above fs2 

     

     

  13. On 7/20/2020 at 1:08 AM, crazy^millman said:

    For machine sim? Or for the Machine definition that is not tied back to the Machine sim or even has any effect on any toolpath in Mastercam? Please give some more detail. 

    Not for Machine Simulation. 

    when i set xyz limit in Machine Kinematics in .mmd file. it doesn't shows any effect when toolpath creation or Nc code.

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