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:

Post Processor Error Checks for Home Values


Recommended Posts

Using Mastecam X5 mu1

 

Hope someone can show me what I am doing wrong...

We are using a modified mplmaster post for a lathe.

An error error check has been added that gets the x home and z home for each operation.

I can get the xh$ and zh$ value but the zh$ causes some undesired output into the G code file.

 

The code below gets the x home value for each operation with no problem.

 

xhome = vequ(xh$)

xhome = xhome * 2

xhome = -xhome

sxhome = no2str(xhome)

 

However when I try the following line to get the z value the undesired code appears.

 

zhome = vequ(zh$)

 

When I use # to make it a remark or get the xh$ value a second time the error goes away.

 

Undesired Code below Desired Code below

O1832 O1832

N10G20 N10G20

N20G97 N20G97

N30G99 N30G99

N40M17 N40M17

N50G50X-30.1Z13.232 N50G50X-30.1Z13.232

N60G00T0200 N60G00T0200

N70G00T0202 N70G00T0202

N80M42 -------------------------- undesired output

N90G97S111M03 -------------- undesired output

N100G50S600 N80G50S600

N110G96M42S700 N90G96M42S700

N120M03 N100M03

N130G00X-24.125Z1.05M08 N110G00X-24.125Z1.05M08

N140G50S600 ------------------- undesired output

N150G96M42S700 ------------- undesired output

N160M03 ------------------------- undesired output

N170G01Z0.F.012 N120G01Z0.F.012

N180X-24.6794 N130X-24.6794

N190X-25.2794 N140X-25.2794

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