ACU-RITE CNC 3500i User Manual
Page 434
408
11 G-Code Edit, Help, & Advanced Features
1
1
.4 A
d
v
a
nced Pr
ogr
a
mming
The read only variables are set in Blocks N60 to N90. Then, the
sub-program is called. At Block N170, the first move is made along the
X-axis, followed by a move along the Y-axis. At Blocks N190 and N200,
the logical negative sign makes the axis move in the opposite
direction. The contents of the variables remain the same.
At Block N220, a loop, which ends at Block N310, is set up. The loop
runs the number of times contained in variable #154. The first move in
the loop is in the X and Y axes to the side of cut value in #153. In Block
N240, #111 decrements at each pass through the loop, by the value
of the side cut. This value, in turn, is used to calculate a new length of
cut for each side.
N210
#111 = 0 ;* SET SIDE CUT INCREMENT TO 0
N220
LOOP #154 ;* LOOP #154 NUMBER OF TIMES
N230
X#153 Y#153 ;* SET SIDE CUT
N240
#111 = #111 #153 ;* DECREMENT SIDE CUT EACH
LOOP
N250
#101 = #151 + (#111 * 2 ) ;* CALCULATE NEW X
LENGTH
N260
#102 = #152 + (#111 * 2 ) ;* CALCULATE NEW Y
LENGTH
N270
X#101 ;* MOVE AROUND SQUARE USING NEW SIDE
* LENGTHS
N280
Y#102
N290
X( #101)
N300
Y( #102)
N310
END
N320
M99