As answered on the Mach forum, Mach3 doesn't support conditional stuff in the g-code.
You can work around this by creating VB macros and calling them via M codes.
Mach3 won't load this parametric code. Is it a syntax error or just not within Mach's capabilities? It's hanging on line 4 not liking the word 'If'.
Thanks.
Chris
O001
N1#123=0
N2#100=[5/.125]
N3#101=[#123*.125]
N4IF[#123EQ#100]GOTO7
N5#123=[#123+1]
N6GOTO8
N7M30
N8G1 X[#101] Z0 Y0
N9Z0.037 Y0.0054
N10Z0.0643 Y0.0156
N11Z0.0924 Y0.0313
N13Z0.1144 Y0.0469
N14Z0.1332 Y0.0625
N16Z0.1646 Y0.0938
N17Z0.1904 Y0.125
N20Z0.2115 Y0.1563
N21Z0.2288 Y0.1875
N23Z0.2434 Y0.2188
....etc.
N121Z0.1227 Y11
N122Z0.1095 Y11.125
N123Z0.0961 Y11.25
N124Z0.0825 Y11.375
N125Z0.0687 Y11.5
N126Z0.0549 Y11.625
N127Z0.0409 Y11.75
N128Z0.0268 Y11.875
N129Z0.0127 Y12
N130G0Z.75
N131Y0
N132GOTO3
As answered on the Mach forum, Mach3 doesn't support conditional stuff in the g-code.
You can work around this by creating VB macros and calling them via M codes.
Gerry
Mach3 2010 Screenset
http://home.comcast.net/~cncwoodworker/2010.html
(Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)
Can you point me to any info on writing VB macros for Mach? My understanding of the Mach macro stuff on the Mach website is that it's for controlling the Mach screen interface which isn't what I'm trying to do...but maybe I'm confused about this.
Thanks.
Chris
You can send g-code commands via VB.
A good source of info is the wizards. View the VB code in the buttons for examples. Use operator>edit button script and click the flashing buttons to see the vb code.
Gerry
Mach3 2010 Screenset
http://home.comcast.net/~cncwoodworker/2010.html
(Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)