hexagon logo

Have the roundness of an auto-circle in a variable

Hi there,

I am trying to have the roundness of an auto-element in a variable. I cannot use a dimension as I have 30,000 circles and try to export all of these roudnesses via a script to a txt file.

Does anyone knows how to call the roundness of an auto-circle into a variable?

Thanks in advance.
Parents
  • Hi , I'm using a Zoom camera

    I found a different way perhaps. What do you think about this.

    In PC-DMIS I have the following.

    DIM LOC1= LOCATIE VAN CIRKEL CIR1  EENHEDEN=MM ,$
    GRAFIEK=UIT  TEKST=UIT  MULT=10.00  PIJLDICHTHEID=100  OUTPUT=BEIDE  HALVE HOEK=NEE
    AS        NOM       +TOL       -TOL       METG        AFW     BUITOL
    RN       0.000      0.050      0.000      0.009      0.009      0.000 -#-------
    EINDE VAN DIMENSIELOC1​


    Above you'll see that I have a Location Dimension called LOC1 and this calculates the roundness. Within the script I need to change the REF_ID and then extract the DIM_MEASURED. Put this in the loop, and it should give me the roundness values?!

    I tried doing with the following, but it didn't work.

    '' insert the REF_ID
    retval = LOC1.PutText ("iCnt", REF_ID, 0)
    '' Retrieve the value in the variable
    dRound = LOC1.GetText (DIM_MEASURED, 0)

    Do you know how I can have it to work?
Reply
  • Hi , I'm using a Zoom camera

    I found a different way perhaps. What do you think about this.

    In PC-DMIS I have the following.

    DIM LOC1= LOCATIE VAN CIRKEL CIR1  EENHEDEN=MM ,$
    GRAFIEK=UIT  TEKST=UIT  MULT=10.00  PIJLDICHTHEID=100  OUTPUT=BEIDE  HALVE HOEK=NEE
    AS        NOM       +TOL       -TOL       METG        AFW     BUITOL
    RN       0.000      0.050      0.000      0.009      0.009      0.000 -#-------
    EINDE VAN DIMENSIELOC1​


    Above you'll see that I have a Location Dimension called LOC1 and this calculates the roundness. Within the script I need to change the REF_ID and then extract the DIM_MEASURED. Put this in the loop, and it should give me the roundness values?!

    I tried doing with the following, but it didn't work.

    '' insert the REF_ID
    retval = LOC1.PutText ("iCnt", REF_ID, 0)
    '' Retrieve the value in the variable
    dRound = LOC1.GetText (DIM_MEASURED, 0)

    Do you know how I can have it to work?
Children
No Data