OF runs program twice randomly, doesn't stop after program done

I’m wondering if someone has experienced this before, I have not found anything in the forums.

This has happened three times now (out of perhaps 30 runs recently):

  1. Load NC file, simulate, check everything, etc.
  2. Run program (estimated time shows about correct, e.g. 28 minutes, ETA is whacky)
  3. After ~28 min, on-screen timer goes from 0:01 to 0:00 (as it should be)
  4. Then timer shows something like “-0:00”, machine jogs back to start position of current NC, seems to repeat the current NC file
  5. User panics as machine should stop, hits all e-stops that are within reach.

Due to step #5, I’ve not been able to get a screenshot when this happens. Now I’m on the lookout and have the cell phone ready to capture in case it happens again.

I have double-checked that it is not somehow the NC file that has the same toolpath twice (also, the timer would show double the time in this case).

Any ideas?

I have experienced this! It happens so rarely that I thought I may have just been going crazy.

It happened in the early days, so I put it down to me doing something daft. Not noticed it since, though.

Could an application you are using for exporting of gcode be appending to an existing file instead of overwriting?

Good idea!
Most of my programs are one-off so I’ve not noticed on a re-run of the same code. I’ll pull up the code from my most recent experience and check.

Good point. I double checked this for the two last NC files where this happened. Happy to share them if it helps. I feel that if the toolpath would be there twice, the ETA would be 2x accordingly. I’ll be on the lookout if it happens again to give better debug information.

For reference, the two toolpaths were generated with different tools, one with Fusion 360, one with a fork of @cilynx 's pygdk (GitHub - cilynx/pygdk: Python G-code Development Kit)

Were you able to ever figure this out I’ve also had this problem a few times last two times running G-Code from light burn using the jtech 7 watt laser it will repeat itself and the timer will have a minus