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
  • I would try something like this :

    ASSIGN/V1=0
    DO/
    IF V1>0
    COMMENT/OPER,NO,FULL SCREEN=YES,AUTO-CONTINUE=NO,
                    CLEAN THE TIP AND THE SPHERE !
    END IF/
    AUTOCALIBRATE/PROBE, PARAMETER_SET=A0B0, QUALTOOL_MOVED=NO,
            SHOW_SUMMARY=NO, OVERWRITE_RESULTSFILE=NO
    ASSIGN/V2=PROBEDATA("STANDARDDEVIATION")
    ASSIGN/V1=V1+1
    UNTIL/V2<0.0002

  • Do you happen to know the format used for using dimensioning box data?
    Example: Like I take a circle then dimension that circle with tolerance.
    say I named the dimensioned circle "whatever"
    How can I write it out to prompt me if I want to re-meas the circle if the deviation box is triggered?
    I've exhausted all my ideas on the logic.
  • So what do u want to do, if the dimension is out to tolerance, go calibrate the probe?

    i would create a parameter set in the beginning of the program and calibrate the probe, then measure and dimension the feature. If the feature is out of tolerance, go re calibrate the probe, re measure the part and if it’s still out of tolerance, end the program
  • I want it to prompt me that if a dimension is out of tolerance then ask if I want to re-measure it.
    No re-calibration.
  • try this

    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
                IF_GOTO/CIR_OOT>0,GOTO = BAD
    GOOD       =LABEL/
                GOTO/END_PROG
    BAD        =LABEL/
                COMMENT/OPER,NO,FULL SCREEN=NO,AUTO-CONTINUE=NO,
                "CIR_1 IS OUT OF TOLERACNE BY " +CIR_OOT
    C1         =COMMENT/YESNO,NO,FULL SCREEN=NO,AUTO-CONTINUE=NO,
                DO YOU WANT TO RE MEASURE?
                IF_GOTO/C1.INPUT=="YES",GOTO = MEASURE_CIR_1
    END_PROG   =LABEL/
    


    FYI, type {code}, return to the next line and paste your code, then return again to the next line and type {/code}, except us straight brackets instead of curly ones
  • 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.