hexagon logo

Main and Sub programs

Is it possible to wright Main and Sub programs in PcDmis as done on the CNC machines? Looking for more possibilities in the lights out area, checking multiple fixtured parts.

In Fanuc NC code,
Main program 1234 >> G65PXXXXXX calls a sub program to run independent (set of instructions).
at the end of sub, M99 returns control to main program.
Main program 1234 >> G65PYYYYYY calls a sub program to run independent (set of instructions).
at the end of sub, M99 returns control to main program.
Main program 1234 >> G65PZZZZZZ calls a sub program to run independent (set of instructions).
at the end of sub, M99 returns control to main program.
Main program 1234 >> end M30​​
Parents
  • My issue was that I needed everything in 1 report, write to a .csv and the parts varied just a little. I needed to pass a ton of variables and it made the creating process no worth it in the end.

    If you are going to run part A, B, and C on the table, then yes, perhaps subroutines may work.

    Create a main program, call part A sub, run and print report, call part B sub, run and print report, call part C sub, run print report, and so on.
  • I think about the part serial numbers..maybe have each sub read a text file containing the parts serial number. That way you can create that text file before you leave for the day and have traceability on your reports. Something to consider.
Reply Children
No Data