uArmProPython icon indicating copy to clipboard operation
uArmProPython copied to clipboard

No option to use the laser in laser mode 1

Open OssiLehtinen opened this issue 7 years ago • 0 comments

Hi,

first of all thanks for the nice and compact set of functions to operate the Swift Pro. Really easy to get started!

My minor issue: I didn't find an option to operate the laser. My solution was to add another method:

def goto_laser(self,x,y,z,speed):
    self.moving = True
    x = str(round(x, 2))
    y = str(round(y, 2))
    z = str(round(z, 2))
    s = str(round(speed, 2))
    cmd = protocol.SET_POSITION_LASER.format(x,y,z,s)
    self.sendcmd(cmd, True)

and protocol

SET_POSITION_LASER = "G1 X{} Y{} Z{} F{}"

not sure if this is the most elegant way of doing this, but gets the job done. The only difference to the normal 'goto' is the G1 at the beginning of the protocol.

Cheers, Ossi

OssiLehtinen avatar Jul 01 '17 21:07 OssiLehtinen