We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 844045e commit 03793ccCopy full SHA for 03793cc
1 file changed
src/emc/rs274ngc/interp_g7x.cc
@@ -1191,8 +1191,24 @@ int Interp::convert_g7x(int mode,
1191
try {
1192
switch(cycle) {
1193
case 70: path.do_g70(&motion,x,z,d,e,p); break;
1194
- case 71: path.do_g71(&motion,subcycle,x,z,u,w,d,i,r); break;
1195
- case 72: path.do_g72(&motion,subcycle,x,z,u,w,d,i,r); break;
+ case 71:
+ if(x!=imag(start)) {
1196
+ std::complex<double> end{real(start),x};
1197
+ path.emplace_back(std::make_unique<straight_segment>(
1198
+ start, end
1199
+ ));
1200
+ }
1201
+ path.do_g71(&motion,subcycle,x,z,u,w,d,i,r);
1202
+ break;
1203
+ case 72:
1204
+ if(z!=real(start)) {
1205
+ std::complex<double> end{z,imag(start)};
1206
1207
1208
1209
1210
+ path.do_g72(&motion,subcycle,x,z,u,w,d,i,r);
1211
1212
}
1213
} catch(std::string &s) {
1214
ERS("G7X error: %s", s.c_str());
0 commit comments