I'm having difficulty searching and was wondering if someone could help me. I want to create a loop that ask the operator if they want to check another part. (checking multiple parts but not a defined amount) but can't seem to find any threads that meet what i'm looking for.
Kinda along these lines
"do you want to check another?"
"yes" would run the loop and back to the beginning,
"no" would end the loop and print off the report with all the parts ran.
UPDATE:
Here's what I came up with I also added a comment and dimension so it will print every part with an entered part number to one single report. good for CAP studies where we number each part.
STARTUP =ALIGNMENT/START,RECALL:USE_PART_SETUP,LIST=YES
ALIGNMENT/END
MODE/MANUAL
PREHIT/0.1
RETRACT/0.1
MOVESPEED/ 100
MANRETRACT/0.1181
FORMAT/TEXT,OPTIONS, ,HEADINGS,SYMBOLS, ;NOM,TOL,MEAS,DEV,OUTTOL, ,
LOADPROBE/2X50MM
TIP/T1A0B0, SHANKIJK=0, 0, 1, ANGLE=0
PLN1 =FEAT/PLANE,CARTESIAN,TRIANGLE
THEO/<12.3841,10.8092,-24.3772>,<0.0000203,-0.0001256,1>
ACTL/<12.7461,11.4439,-24.4182>,<-0.0010152,-0.0000618,0.9999995>
MEAS/PLANE,3
HIT/BASIC,NORMAL,<12.4297,11.351,-24.3771>,<0.0000203,-0.0001256,1>,<12.7412,11.5325,-24.4182>,USE THEO=YES
HIT/BASIC,NORMAL,<11.9393,10.6151,-24.3772>,<0.0000203,-0.0001256,1>,<12.6315,11.3995,-24.4183>,USE THEO=YES
HIT/BASIC,NORMAL,<12.7834,10.4614,-24.3772>,<0.0000203,-0.0001256,1>,<12.8656,11.3999,-24.4181>,USE THEO=YES
ENDMEAS/
CIR1 =FEAT/CIRCLE,CARTESIAN,IN,LEAST_SQR
THEO/<12.4197,10.7849,-24.4932>,<0,0,1>,0.7599
ACTL/<12.69,10.9125,-24.4995>,<0,0,1>,0.7603
MEAS/CIRCLE,3,ZPLUS
HIT/BASIC,NORMAL,<12.4194,11.1648,-24.4942>,<0.0009949,-0.9999995,0>,<12.6863,11.2927,-24.5007>,USE THEO=YES
HIT/BASIC,NORMAL,<12.7961,10.7326,-24.4933>,<-0.9904903,0.1375824,0>,<12.3554,10.7321,-24.4989>,USE THEO=YES
HIT/BASIC,NORMAL,<12.0434,10.7322,-24.4922>,<0.9903483,0.1386009,0>,<13.0247,10.7322,-24.4988>,USE THEO=YES
ENDMEAS/
A1 =ALIGNMENT/START,RECALL:STARTUP,LIST=YES
ALIGNMENT/LEVEL,ZPLUS,PLN1
ALIGNMENT/TRANS,ZAXIS,PLN1
ALIGNMENT/TRANS,XAXIS,CIR1
ALIGNMENT/TRANS,YAXIS,CIR1
ALIGNMENT/END
MODE/DCC
MOVE/CLEARPLANE
CLEARP/ZPLUS,0.1,ZPLUS,0,ON
MOVE/CLEARPLANE
L1 =LABEL/…………………………………………………………….. (this line starts the loop)
C2 =COMMENT/INPUT,NO,FULL SCREEN=NO,
Part number?...………………………………………………………. (here I ask what the number on the part is and ASSIGN it to a variable)
ASSIGN/V1=C2.INPUT
PLN2 =FEAT/CONTACT/PLANE/DEFAULT,CARTESIAN,NONE
THEO/<0,0,0>,<0,0,1>
ACTL/<0,0.0001,-0.0001>,<0.0002898,-0.0004154,0.9999999>
TARG/<0,0,0>,<0,0,1>
ANGLE VEC=<0.0000001,1,0>,RADIAL
SHOW FEATURE PARAMETERS=NO
SHOW CONTACT PARAMETERS=NO
MOVE/CLEARPLANE
CIR2 =FEAT/CONTACT/CIRCLE/DEFAULT,CARTESIAN,IN,LEAST_SQR
THEO/<0,0,-0.12>,<0,0,1>,0.76
ACTL/<-0.0001,0.0001,-0.12>,<0,0,1>,0.7604
TARG/<0,0,-0.12>,<0,0,1>
START ANG=0,END ANG=360
ANGLE VEC=<0.0000001,1,0>
DIRECTION=CCW
SHOW FEATURE PARAMETERS=NO
SHOW CONTACT PARAMETERS=NO
COMMENT/REPT,
COMMENT/REPT,
"Part #"+V1...……………………………………………………. (here it prints what's in the quotes and adds the entered number, I had to go with NO spaces around the + sign to make it work)
DIM BORE= LOCATION OF CIRCLE CIR2 UNITS=IN ,$
GRAPH=OFF TEXT=OFF MULT=10.00 OUTPUT=BOTH HALF ANGLE=NO
AX NOMINAL +TOL -TOL MEAS DEV OUTTOL
D 0.7600 0.0020 0.0020 0.7604 0.0004 0.0000 -----#---
END OF DIMENSION BORE
MOVE/CLEARPLANE
C1 =COMMENT/YESNO,NO,FULL SCREEN=NO,AUTO-CONTINUE=NO,
Run another part?
IF_GOTO/C1.INPUT=="YES",GOTO = L1...………………………………….. (this sends it back to the L1 label and starts the loop over, or ends the program with a "no" selection)
MOVE/CLEARPOINT
it works good. I start with manual hits to locate and set the part's position, then use DCC hits to measure the same features over and over, to be complete I should use another alignment after the loop starts but this is just a basic loop program I did to learn how to make it work. as long as you have a fixture that holds the part steady in the same place this setup could work well. Be careful to start over from the beginning for each session or it will keep adding to the list on the printout instead of starting over. or if you get stopped mid stream and want to complete it later, just leave it open and running at a comment and come back later.
Kinda along these lines
"do you want to check another?"
"yes" would run the loop and back to the beginning,
"no" would end the loop and print off the report with all the parts ran.
UPDATE:
Here's what I came up with I also added a comment and dimension so it will print every part with an entered part number to one single report. good for CAP studies where we number each part.
STARTUP =ALIGNMENT/START,RECALL:USE_PART_SETUP,LIST=YES
ALIGNMENT/END
MODE/MANUAL
PREHIT/0.1
RETRACT/0.1
MOVESPEED/ 100
MANRETRACT/0.1181
FORMAT/TEXT,OPTIONS, ,HEADINGS,SYMBOLS, ;NOM,TOL,MEAS,DEV,OUTTOL, ,
LOADPROBE/2X50MM
TIP/T1A0B0, SHANKIJK=0, 0, 1, ANGLE=0
PLN1 =FEAT/PLANE,CARTESIAN,TRIANGLE
THEO/<12.3841,10.8092,-24.3772>,<0.0000203,-0.0001256,1>
ACTL/<12.7461,11.4439,-24.4182>,<-0.0010152,-0.0000618,0.9999995>
MEAS/PLANE,3
HIT/BASIC,NORMAL,<12.4297,11.351,-24.3771>,<0.0000203,-0.0001256,1>,<12.7412,11.5325,-24.4182>,USE THEO=YES
HIT/BASIC,NORMAL,<11.9393,10.6151,-24.3772>,<0.0000203,-0.0001256,1>,<12.6315,11.3995,-24.4183>,USE THEO=YES
HIT/BASIC,NORMAL,<12.7834,10.4614,-24.3772>,<0.0000203,-0.0001256,1>,<12.8656,11.3999,-24.4181>,USE THEO=YES
ENDMEAS/
CIR1 =FEAT/CIRCLE,CARTESIAN,IN,LEAST_SQR
THEO/<12.4197,10.7849,-24.4932>,<0,0,1>,0.7599
ACTL/<12.69,10.9125,-24.4995>,<0,0,1>,0.7603
MEAS/CIRCLE,3,ZPLUS
HIT/BASIC,NORMAL,<12.4194,11.1648,-24.4942>,<0.0009949,-0.9999995,0>,<12.6863,11.2927,-24.5007>,USE THEO=YES
HIT/BASIC,NORMAL,<12.7961,10.7326,-24.4933>,<-0.9904903,0.1375824,0>,<12.3554,10.7321,-24.4989>,USE THEO=YES
HIT/BASIC,NORMAL,<12.0434,10.7322,-24.4922>,<0.9903483,0.1386009,0>,<13.0247,10.7322,-24.4988>,USE THEO=YES
ENDMEAS/
A1 =ALIGNMENT/START,RECALL:STARTUP,LIST=YES
ALIGNMENT/LEVEL,ZPLUS,PLN1
ALIGNMENT/TRANS,ZAXIS,PLN1
ALIGNMENT/TRANS,XAXIS,CIR1
ALIGNMENT/TRANS,YAXIS,CIR1
ALIGNMENT/END
MODE/DCC
MOVE/CLEARPLANE
CLEARP/ZPLUS,0.1,ZPLUS,0,ON
MOVE/CLEARPLANE
L1 =LABEL/…………………………………………………………….. (this line starts the loop)
C2 =COMMENT/INPUT,NO,FULL SCREEN=NO,
Part number?...………………………………………………………. (here I ask what the number on the part is and ASSIGN it to a variable)
ASSIGN/V1=C2.INPUT
PLN2 =FEAT/CONTACT/PLANE/DEFAULT,CARTESIAN,NONE
THEO/<0,0,0>,<0,0,1>
ACTL/<0,0.0001,-0.0001>,<0.0002898,-0.0004154,0.9999999>
TARG/<0,0,0>,<0,0,1>
ANGLE VEC=<0.0000001,1,0>,RADIAL
SHOW FEATURE PARAMETERS=NO
SHOW CONTACT PARAMETERS=NO
MOVE/CLEARPLANE
CIR2 =FEAT/CONTACT/CIRCLE/DEFAULT,CARTESIAN,IN,LEAST_SQR
THEO/<0,0,-0.12>,<0,0,1>,0.76
ACTL/<-0.0001,0.0001,-0.12>,<0,0,1>,0.7604
TARG/<0,0,-0.12>,<0,0,1>
START ANG=0,END ANG=360
ANGLE VEC=<0.0000001,1,0>
DIRECTION=CCW
SHOW FEATURE PARAMETERS=NO
SHOW CONTACT PARAMETERS=NO
COMMENT/REPT,
COMMENT/REPT,
"Part #"+V1...……………………………………………………. (here it prints what's in the quotes and adds the entered number, I had to go with NO spaces around the + sign to make it work)
DIM BORE= LOCATION OF CIRCLE CIR2 UNITS=IN ,$
GRAPH=OFF TEXT=OFF MULT=10.00 OUTPUT=BOTH HALF ANGLE=NO
AX NOMINAL +TOL -TOL MEAS DEV OUTTOL
D 0.7600 0.0020 0.0020 0.7604 0.0004 0.0000 -----#---
END OF DIMENSION BORE
MOVE/CLEARPLANE
C1 =COMMENT/YESNO,NO,FULL SCREEN=NO,AUTO-CONTINUE=NO,
Run another part?
IF_GOTO/C1.INPUT=="YES",GOTO = L1...………………………………….. (this sends it back to the L1 label and starts the loop over, or ends the program with a "no" selection)
MOVE/CLEARPOINT
it works good. I start with manual hits to locate and set the part's position, then use DCC hits to measure the same features over and over, to be complete I should use another alignment after the loop starts but this is just a basic loop program I did to learn how to make it work. as long as you have a fixture that holds the part steady in the same place this setup could work well. Be careful to start over from the beginning for each session or it will keep adding to the list on the printout instead of starting over. or if you get stopped mid stream and want to complete it later, just leave it open and running at a comment and come back later.
Comment