Code Error?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Code Error?

    So I've got to track CMM "up time", below is the code I came up with. It just pulls some info into variables and then writes them to a .csv file. Issue is sometimes it writes the LASTEXECUTIONTIME and sometimes it doesn't. Is it an issue with my code or and issues with the demon?

    It will record the "program name", date and time every time it runs but it misses the execution time sometimes.



    ASSIGN/V1="DEMO_PROGRAM" + ","
    ASSIGN/V2=LASTEXECUTIONTIME() + ","
    ASSIGN/V3=GETPROGRAMINFO("DATE") + ","
    ASSIGN/V4=GETPROGRAMINFO("TIME")
    ASSIGN/V5=V1 + V2 + V3 + V4
    FPTR =FILE/OPEN,C:\Users\Public\Desktop\CMM Reports\CMMUtil.csv,APPEND
    FILE/WRITELINE,FPTR,V5
    FILE/CLOSE,FPTR,KEEP
    Kevin

  • #2
    There are a lot more things in CMM up time than just the probe going beep, beep, beep. Part Setup time, probe qualification, minor editing along the way etc. You'll need a paper log to keep track of all that.

    Comment


    • #3
      I know there are a lot more variables with CMM up time, however to show planed down time and calculate OEE I first need to know how many hours a day the CMM is executing a program.
      Kevin

      Comment


      • #4
        You could just use something like

        Code:
                    ASSIGN/START_TIME=SYSTIME()
        
        program
        
                    ASSIGN/STOP_TIME=SYSTIME()
        to record a time from the moment the execute button is pressed until the moment the program finished executing. Wirte the values out to a .csv file and then dump the data into Excel to work out your up time. Just grabbing a time at the beginning and end allows you to record any manual probing or other operations that would not get recorded by LASTEXECUTIONTIME().

        If this is something your company is keen on monitoring on a long term basis it may be worth asking your Hexagon rep about Asset Manager as it's designed to do exactly what you're after - monitor and report on machine utilisation.
        Neil Challinor
        PC-DMIS Product Owner

        T: +44 870 446 2667 (Hexagon UK office)
        E: [email protected]

        Comment

        Related Topics

        Collapse

        Working...
        X