hexagon logo

Logic

Hey guys I was wondering if anyone had a quick line of code they could throw my way
for dmis to re-run a feature if it was out of tolerance.

Was thinking about adding it to my A0B0 calibration if it read anything above .0002
To automatically just re-run that tool until it got within the 0.000-.0002 range.
Also to add it to certain programs that if it read it out as it was measuring that it would
at least ask if i wanted to re-measure because it was out.

Thanks
Parents
  • This code however will automatically remeasure the feature if its out of tolerance. once it remeasures the feature a second time, it will move on to continue the program.

    ASSIGN/MEASURE_COUNT=0
    MEASURE_CIR_1=LABEL/
    CIR_1      =FEAT/CONTACT/CIRCLE/DEFAULT,CARTESIAN,OUT,LEAST_SQR
                THEO/<0,0,0>,<0,0,1>,2,0
                ACTL/<0,0,0>,<0,0,1>,2,0
                TARG/<0,0,0>,<0,0,1>
                START ANG=0,END ANG=180
                ANGLE VEC=<0,1,0>
                DIRECTION=CCW
                SHOW FEATURE PARAMETERS=NO
                SHOW CONTACT PARAMETERS=YES
                  NUMHITS=4,DEPTH=0,PITCH=0
                  SAMPLE METHOD=SAMPLE_HITS
                  SAMPLE HITS=0,SPACER=0
                  AVOIDANCE MOVE=NO,DISTANCE=0.3937
                  FIND HOLE=DISABLED,ONERROR=NO,READ POS=NO
                SHOW HITS=NO
    DIM LOC1= LOCATION OF CIRCLE CIR_1  UNITS=IN ,$
    GRAPH=OFF  TEXT=OFF  MULT=10.00  OUTPUT=BOTH  HALF ANGLE=NO
    AX    NOMINAL       +TOL       -TOL       MEAS        DEV     OUTTOL
    D       2.0000     0.0020     0.0020     2.0000     0.0000     0.0000 ---#----
    END OF DIMENSION LOC1
                ASSIGN/CIR_OOT=LOC1.D.OUTTOL
                ASSIGN/MEASURE_COUNT=MEASURE_COUNT+1
                IF_GOTO/MEASURE_COUNT==[COLOR=#FF0000]2[/COLOR],GOTO = END_PROG [COLOR=#ff0000]<-----------change this number to remeasure that part X times[/COLOR]
                IF_GOTO/CIR_OOT>0,GOTO = MEASURE_CIR_1
    END_PROG   =LABEL/
    
  • Just tried it out and it works like a CHAMP!
    I really appreciate it.
Reply Children
No Data