- Posts: 1943
- Thank you received: 338
terans1085 wrote: I used it similar to you, as it also occurred to me that REMAP does not call the epilog when used with a pure python remap.
So far, the only way I could get around the readahead issue mentioned earlier is by using this code:
Warning: Spoiler!
def m6(self):
if self.task==0:
yield INTERP_OK
result = m6_prolog(self)
if result == 1:
print("m6 prolog ready")
yield INTERP_EXECUTE_FINISH
elif result == 2:
print("M6: no change required")
yield INTERP_OK
else:
print("M6: prolog error")
yield INTERP_ERROR
if m6_epilog(self) == 1:
print("m6 epilog ready")
yield INTERP_OK
else:
print("M6: epilog error")
yield INTERP_ERROR
This forces sync before each epilog, and I'm somewhat happy. However this also causes a curious "bug" in such a chain of events:
- I open part1.nc in axis
- I open part2.nc in axis
- I run part2.nc
- I manually stop part2.nc
- part1.nc is loaded back automatically. Titlebar shows part1.nc. Preview still shows part2.ngc
- Manually pressing CTRL-R or reload icon reloads part2.nc
So i'm wondering, if it is possible to come up with an "abort" script that reloads the proper gcode file.....
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.