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:

Search the Community

Showing results for tags 'haas macro'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Mastercam Forums
    • Industrial Forum
    • Post Processor Development Forum
    • Educational Forum
    • Woodworking Forum
    • Machining, Tools, Cutting & Probing
    • 3D Printing

Categories

  • Mastercam Demo Software
  • Files Referenced in Books and Videos
    • Instructor Files
    • Mastercam X7
    • Mastercam X6
    • Mastercam X5
    • Mastercam X4
    • Mastercam X3
    • Mastercam X2
    • STEM
  • Free Book Samples
    • Mastercam 2020
    • Mastercam 2019
    • Mastercam 2018
    • Mastercam 2017
    • Mastercam X9
    • Mastercam X8
    • Mastercam X7
    • Mastercam X6
    • Mastercam X5
    • Mastercam X4
    • Mastercam X3
    • STEM Curriculum
  • Mastercam eBooks (PDF)
    • Mastercam 2023
    • Mastercam 2022
    • Mastercam 2021
    • Mastercam 2020
    • Mastercam 2019
    • Mastercam 2018
    • Mastercam 2017
    • Mastercam X9
    • Mastercam X8
    • Mastercam X7
    • Mastercam X6
    • Mastercam X5
    • Mastercam X4
  • Mastercam Documentation
    • Brochures
    • Press Releases
    • Tips & Guides
  • Tools
  • Post Processors
    • Post Processor 'How To' Info
    • Mpmaster (all versions)
    • Mplmaster (all versions)
    • Application Specific Posts
    • Educational Post Processors
    • Post Processor Request Forms
    • Post Processor Feature Checklist Forms

Product Groups

  • Sitewide Subscription
  • Books
    • Older Versions (No Demo Software)
  • eBooks (PDF)
    • Mastercam 2023
    • Older Versions (No Demo Software)
  • Multimedia
    • Older Versions (No Demo Software)
  • Clearance
  • eCourses
  • eCourses

Categories

  • General Mastercam
    • Hasp / Sim License Articles
    • Nethasp
  • Lathe
  • Toolpaths
    • FBM Drill
    • FBM Mill
    • Dynamic Milling
    • Contour
    • Drill
    • Pocket
    • Face
    • 2D Highspeed
    • Engraving
    • Surface Rough
    • Surface Finish
    • Surface High Speed
    • Curve 5 axis
    • Drill 5 Axis
    • Swarf 5 Axis
    • Multisurface 5 Axis
    • Flow 5 Axis
    • Rotary 4 Axis
    • Port 5 axis
    • Advanced Multiaxis
    • Circle Paths
    • Circle 5 Axis
  • Wire EDM
  • Art
  • Post-Processing
  • Editors & DNC
  • Add-ons + Chooks & Nethooks
  • Windows, PC & Hardware Troubleshooting
    • Windows Issues
    • Videocards
    • Network & Filesharing
  • Multiaxis
  • eBooks

Blogs

  • Mastercam Training Solutions
  • eMastercam Community
  • Reseller Blog
  • Future of CNC Manufacturing Education
  • Mastercam Xtras
  • Latest News

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Interests


Location


Mastercam SIM Number


AIM


MSN

Found 1 result

  1. I wrote this macro to easily find the mid point of X and Y and the Z surface for the picking up of details that are irregular shapes or just difficult to pick up with the Haas Canned Probing Cycles. -It will also will give the overall sizes in the offset page-described in directions. -I added DPRNT if you are using that functionality. -The directions are in the beginning and easy to follow. -There are large spaces in the coding to make it easy to see the questions that will come up on the controller. Hope this helps someone as it helps me all the time. Tom Prebelich (***START OF PROGRAM***) #101= 54 (WORK OFFSET, 54-59) (**MAKE SURE BLOCK DELETE IS OFF FOR FIRST PICKUP**) (PROGRAM WILL PICK UP MID POINT OF X OR Y) (FIRST PICKUP PROBE MOVES + POSITIVE, IN "X" OR "Y") (SECOND PICKUP PROBE MOVES - NEGATIVE, IN "X" OR "Y") (**MAKE SURE BLOCK DELETE IS OFF FOR FIRST PICKUP**) (1-JOG PROBE TO WITHIN .5 OF FIRST SURFACE) (2-CYCLE STAR/RUN PROGRAM) (**NOTE, BLOCK DELETE IS TURNED ON AT THIS POINT**) (3-SELECT JOG) (4-JOG PROBE TO WITHIN .5 OF OPPOSITE SECOND SURFACE) (5-SELECT MEMORY) (6-CYCLE STAR/RUN PROGRAM) (7-PROGRAM WILL ASK IF YOU WANT TO PICK UP Z) (8-SELECT N AND PROGRAM WILL END) (IF YOU WANT TO PICK UP Z CONTINUE WITH THESE STEPS) (--SELECT Y FOR YES AND HIT CYCLE START-PROGRAM WILL END) (--SELECT JOG) (--JOG PROBE TO WITHIN .5 OF THE Z SURFACE) (--SELECT MEMORY THEN CYCLE START) (--PROGRAM ASKS IF YOU ARE PICKING UP Z-THIS IS FOR SAFETY) (--PRESS Y FOR AND MACHINE WILL PICK UP Z) (MID POINT OF BOTH PICKUPS = OFFSET SELECTED) (INDIVIDUAL SURFACE PICKUPS ARE STORED IN G154P01 & G154P02) (OVERALL DISTANCE BETWEEN THE PICKUPS/WIDTH OF BLOCK ARE IN G154P03) (FIRST X PICKUP=G154P01) (SECOND X PICKUP-G154P02) (OVERALL DISTANCE BETWEEN X PICKUP-G154P03) (FIRST Y PICKUP=G154P01) (SECOND Y PICKUP-G154P02) (OVERALL DISTANCE BETWEEN Y PICKUP-G154P03) (-----REMINDERS-----) (YOU WILL BE ASKED TO PICK UP Z AT THE END) (ANSWER WITH Y=YES OR N=NO) (IF NO, PROGRAM ENDS) (IF YES, YOU WILL HAVE TO HIT CYCLE START TO CONTINUE) (-THIS PROMPTS/PREPARES THE MACHINE FOR PICKING UP Z) (JOG PROBE TO .5 OR LESS ABOVE Z PICKUP SURFACE) (HIT MEMORY AND CYCLE START WHICH WILL PICK UP Z) IF[#10503EQ123.45] GOTO 230 IF [#101 LT 54] #3000=20 (WORK OFFSET MUST BE 54-59) IF [#101 GT 59] #3000=21 (WORK OFFSET MUST BE 54-59) /N1 #10501=0 /N5 M109 P10501(USER INPUT FOR AXIS TO PICKUP) (WHICH AXIS ARE YOU PICKING UP?) (HIT "X" OR "Y" ON KEYBOARD) /IF[#10501EQ0.]GOTO5 IF[#10501EQ88.]GOTO100 (GOTO "X" PICKUP) IF[#10501EQ89.]GOTO200 (GOTO "Y" PICKUP) /GOTO1 (BEGINING OF X PICKUP) N100 /(1ST X PICKUP IN + DIRECTION) /G65 P9995 W154.01 A20. D.5 /#110=#14001 /GOTO 110 (2ND X PICKUP IN DIRECTION) G65 P9995 W154.02 A20. D-.5 #111=#14021 (AVERAGE FOR BOTH PICKUPS IN X) #115=[[#110+#111]/2] #7041=#7021-#7001 (SETTING WORK OFFSET FOR X) IF[#101EQ54] #5221=#115 IF[#101EQ55] #5241=#115 IF[#101EQ56] #5261=#115 IF[#101EQ57] #5281=#115 IF[#101EQ58] #5301=#115 IF[#101EQ59] #5321=#115 GOTO 120 N110 #3032=1(TURN BLOCK DEL ON) M30 N120 #3032=0(TURN BLOCK DEL OFF) #10188=#14041 DPRNT[] DPRNT[] DPRNT[FIXTURE*OFFSET*#101[40]] DPRNT[X*WIDTH*#14041[24]] GOTO 220 (END OF X PICKUP) (BEGINING OF Y PICKUP) N200 /(1ST Y PICKUP IN + DIRECTION) /G65 P9995 W154.01 A20. E.5 /#112=#14002 /GOTO 210 (2ND Y PICKUP IN -DIRECTION) G65 P9995 W154.02 A20. E-.5 #113=#14022 (AVERAGE FOR BOTH PICKUPS IN Y) #115=[[#112+#113]/2] #7042=#7022-#7002 (SETTING WORK OFFSET FOR Y) #10188=#14042 IF[#101EQ54] #5222=#115 IF[#101EQ55] #5242=#115 IF[#101EQ56] #5262=#115 IF[#101EQ57] #5282=#115 IF[#101EQ58] #5302=#115 IF[#101EQ59] #5322=#115 DPRNT[] DPRNT[] DPRNT[FIXTURE*OFFSET*#101[40]] DPRNT[Y*WIDTH*#14042[24]] GOTO 220 N210 #3032=1(TURN BLOCK DEL ON) M30 N220 #3032=0(TURN BLOCK DEL OFF) (Y=YES/N=NO, ARE YOU PICKING UP Z) #10502=0 N222 M109 P10502(USER INPUT FOR AXIS TO PICKUP) (ARE YOU PICKING UP "Z"?) ("Y"=YES, "N"=NO) IF[#10502EQ0.]GOTO222 IF[#10502NE89.] XOR IF[#10502NE78.] GOTO 222 IF[#10502EQ89.]GOTO225 (GOTO "Z" PICKUP) IF[#10502EQ78.]GOTO245 (GOTO END OF PROGRAM) N225 #10503=123.45 #3006=1 (AFTER HITTING START JOG Z TO POSITION AND HIT START) GOTO 250 N230 #10504=0 G103P1 N235 M109 P10504(PICKING UP "Z"?) (ARE YOU PICKING UP "Z"?) ("Y"=YES,"N"=NO) IF[#10504EQ0.]GOTO235 IF[#10504NE89.] XOR IF[#10504NE78.] GOTO235 IF[#10504EQ89.]GOTO240 (GOTO "Z" PICKUP) IF[#10504EQ78.]GOTO245 (GOTO END OF PROGRAM) N240 G65 P9995 W#101 A20. H-.5 (SINGLE SURFACE Z) G103P1 N245 #10503=0 N250 M30 (END OF Y PICKUP) (***END OF PROGRAM***)

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