I have a strange problem, where running very long or complicated GCODEs causes the Y axis to gradually drift. One such sample GCODE file is attached to this topic.
What I mean by drift is that when I tell the machine to go to 0 position at the end of the program by calling G0 X0Y0Z0, the Y axis is actually offset from the original zero point by roughly 0.5mm along the Y axis, which is a very large error. This was verified and measured by drilling a tiny hole in the stock before running the GCODE, so the drift can be measured at the end of the program.
There are several reasons of this fault that came to my mind:
0. Something funky with the GCODE that I am not aware of
1. Numerical error building up within UCCNC software (unlikely, since it's only the Y axis that drifts and the GCODE represents a symmetrical operation along a circle)
2. Electrical noise causing the motor drivers (DM542) to fail to register some of the control pulses - this would be possible, but how do I measure/get rid of it?
3. Skipped steps - that's most likely not possible, since the axis loads are negligible (at least 2 orders of magnitude) compared to what this machine can reliably handle
4. Too high pulse frequency - it's already been taken care of and reduced to 50kHz which is 4 times lower than the maximum the DM542 drivers claim to be able to handle
5. Backlash - it's also not possible, because the machine runs precision made linear rails and ball screws on a rigid steel frame, and pushing against the axis with full force when the motors are enabled causes movement of the spindle that's less than 0.01mm.
If anyone has an idea as to what might be causing this strange issue, please let me know - it would save me a huge amount of time and bring back my confidence in this machine.