Step Motor Speed at Microstepping September 12, 2023 06:52AM |
Registered: 1 year ago Posts: 4 |
device.serial.write("G91\n".encode()) while 1: data = device.serial.readline() if data == b"ok\n": break s=time.perf_counter() for i in range(25): device.serial.write(b"G1 Z0.001\n") # move up 1 micrometer (0.001 mm) device.serial.write(b"M400\n") # wait for current move finish c = 0 while 1: data = device.serial.readline() print(data) if data== b'ok\n': c += 1 if c == 2: # "ok" message will return after "G1 Z0.001" and "M400" command break print(time.perf_counter()-s)
device.serial.write("G91\n".encode()) while 1: data = device.serial.readline() if data == b"ok\n": break s=time.perf_counter() for i in range(25): device.serial.write(b"G1 Z0.001\n") # move up 1 micrometer (0.001 mm) time.sleep(.02) # just sleep for 0.02 seconds, I did not use M400 print(time.perf_counter()-s)
>>> m503 SENDING:M503 echo:; Linear Units: echo: G21 ; (mm) echo:; Temperature Units: echo: M149 C ; Units in Celsius echo:; Steps per unit: echo: M92 X800.00 Y800.00 Z25600.00 echo:; Max feedrates (units/s): echo: M203 X1200.00 Y1200.00 Z1200.00 echo:; Max Acceleration (units/s2): echo: M201 X60.00 Y60.00 Z60.00 echo:; Acceleration (units/s2) (P R T): echo: M204 P60.00 R60.00 T60.00 echo:; Advanced (B S T X Y Z): echo: M205 B20000.00 S0.00 T0.00 X0.30 Y0.30 Z0.30 echo:; Home offset: echo: M206 X0.00 Y0.00 Z0.00 echo:; Stepper driver current: echo: M906 X1200 Y1200 Z1200 echo: M906 I1 X1200 Y1200 echo:; Driver stepping mode: echo: M569 S1 X Y Z echo: M569 S1 I1 X Y echo:; Backlash compensation: echo: M425 F1.00 X0.00 Y0.00 Z0.00
Re: Step Motor Speed at Microstepping September 12, 2023 09:37PM |
Registered: 7 years ago Posts: 341 |
Quote
It is taking 0.1 seconds for 1 micrometer and I think it is very slow. Also single 100 micrometer movement takes about 0.15 seconds
Re: Step Motor Speed at Microstepping September 13, 2023 05:30PM |
Registered: 1 year ago Posts: 4 |