Skip to content

Commit 7ee7d76

Browse files
committed
gmoccapy: remove S prefix for spindle display
because this does not reflect the spindle speed programmed with the S word. It shows the current resp. commanded speed.
1 parent 7d4698f commit 7ee7d76

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/emc/usr_intf/gmoccapy/gmoccapy.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4203,11 +4203,11 @@ def _update_spindle(self):
42034203
speed = hal.get_value("spindle.0.speed-out")
42044204
# catch very large values eg when using G96 w/o D value
42054205
if speed > self.max_spindle_disp:
4206-
self.widgets.lbl_spindle_act.set_text("S >"+str(self.max_spindle_disp))
4206+
self.widgets.lbl_spindle_act.set_text(">"+str(self.max_spindle_disp))
42074207
elif speed < -self.max_spindle_disp:
4208-
self.widgets.lbl_spindle_act.set_text("S <"+str(self.max_spindle_disp))
4208+
self.widgets.lbl_spindle_act.set_text("<"+str(self.max_spindle_disp))
42094209
else:
4210-
self.widgets.lbl_spindle_act.set_text("S {0}".format(int(round(speed))))
4210+
self.widgets.lbl_spindle_act.set_text("{0}".format(int(round(speed))))
42114211

42124212
def _update_vc(self):
42134213
#Note: self.stat.spindle[0]['speed'] does not reflect 'spindle.0.speed-out' pins when using G96 mode (issue #3449)
@@ -4341,13 +4341,13 @@ def _set_spindle(self, command):
43414341
rpm_out = rpm / self.stat.spindle[0]['override']
43424342
except:
43434343
rpm_out = 0
4344-
self.widgets.lbl_spindle_act.set_label("S {0}".format(int(rpm)))
4344+
self.widgets.lbl_spindle_act.set_label("{0}".format(int(rpm)))
43454345

43464346
if command == "stop":
43474347
# documentation of self.command.spindle()
43484348
# linuxcnc.spindle(direction, speed, spindle=0)
43494349
self.command.spindle(0)
4350-
self.widgets.lbl_spindle_act.set_label("S 0")
4350+
self.widgets.lbl_spindle_act.set_label("0")
43514351
elif command == "forward":
43524352
self.command.spindle(1, rpm_out)
43534353
elif command == "reverse":

0 commit comments

Comments
 (0)