- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hey Guys,
Looking over the Tormach G Code reference, only inverse time feed movements are required to have a feedrate on every line. G93 starts inverse time mode and G94 stops it (starts feed units per minute rather). Therefore any G1 occuring AFTER a G94 shouldn't require a feedrate to be posted for every line.
https://www.tormach.com/g93_g94_g95.html
When the inverse time feed rate mode is active, an F word must appear on every line which has a G1, G2 or G3 motion and an F word on a line that does not have G1, G2 or G3 is ignored. Being in inverse time feed rate mode does not affect G0 (rapid traverse) motions.
It is an error if inverse time feed rate mode is active and a line with G1, G2 or G3 (explicitly or implicitly) does not have an F word.
The way I understand that, a feedrate for G94 Shouldn't be required.
But since forcing the feedrate to output on every line won't hurt anything here's what you need to change:
Find the OnLinear5D function (should be around line 1,000), and right below where it says fmode = 93 it'll say feedOutput.reset(); This line is used to force the feedrate to output every line during inverse time (G93) mode. We will just move that line outside the the if...else... statement so that every linear (G1) 5 axis move outputs the feedrate. so the code should like like this:
// Calculate Inverse Time Feed Rates
var f;
var fmode;
if (a || b || c) {
var length = getMoveLength(_x, _y, _z, _a, _b, _c, false);
var inverseTime = getInverseTime(length, feed);
f = inverseTimeOutput.format(inverseTime);
fmode = 93;
//feedOutput.reset(); // Moved to line 1031
} else {
f = feedOutput.format(feed);
fmode = 94;
}
// output the feedrate for every linear movement
feedOutput.reset();
And turn tcp mode back off, that shouldn't need to be on for a rotary axis. In fact, I do believe it's hardcoded to be off in other places in the post processor.
setMachineConfiguration(machineConfiguration); // Single rotary does not use TCP mode optimizeMachineAngles2(1); // 0 = TCP Mode ON, 1 = TCP Mode OFF
And here's the resulting toolpath with feedrates posted on every G1 line.
NOTE: This is only outputting a feedrate for 5 Axis G1 movements, it may be necessary to add an extra feedOutput.reset(); to onLinear also. If that is the case, this should do the trick:
I didn't verify if that actually works though, but again, I don't know why you have to output the feedrate on a G94 G1 movement. I might be missing something, but this should get you pointed in the right direction. Let me know if you have any questions, and let me know if this works for you. I'm curious if any other Tormach users are running into this issue also.
I also attached the edited post processor to this post so you can just download the one I edited for you and give it a shot if you don't wanna go hunting for exact lines.
Let me know how it goes!
-Xander Luciano
Xander Luciano
CAM Content Developer
If my post is helpful, press the
Kudo button - If it resolves your issue, press Accept as Solution!Quick Tips: When to resselect CAM geometry | Understanding Smoothing in CAM | Adaptive Facing | Online GCode Viewer
Fusion