Hello Guest it is April 18, 2024, 11:56:53 PM

Author Topic: edit button script problem with command code  (Read 1519 times)

0 Members and 1 Guest are viewing this topic.

edit button script problem with command code
« on: January 09, 2020, 05:33:12 PM »
Purchased CNC router, running it with Mach3.  Setting it up, necessary to edit the button script for "Auto Tool Zero".  Macro supplied with the machine (lines of text in an instruction sheet) has these lines of code for providing this script:

Code: [Select]
Call SetDRO(2,0.00)
code "G31 Z"Zprobe & "F"&ZfeedRate
While IsMoving()

I keep getting "Syntax Error" for the 2nd of these 3 lines.  I gather that the macro's purpose is to generate a line of G-code, something like
Code: [Select]
G31 Z2.50 F20

(if Zprobe happens to be 2.50 and ZfeedRate 20 inches per second)

Does anyone know what is wrong?

Any and all suggestions greatly appreciated.

Offline Tweakie.CNC

*
  • *
  •  9,198 9,198
  • Super Kitty
    • View Profile
Re: edit button script problem with command code
« Reply #1 on: January 10, 2020, 01:18:03 AM »
Try;

Call SetDRO(2,0.00)
code "G31 Z"&Zprobe & "F"&ZfeedRate
While IsMoving()
PEACE