mbmckeon
01-14-2006, 11:46 AM
I have written code that will cut 6 rows of 16 at specific locations. It uses two different bits for each block of wood. On the 16th block it cut using the first bit and never made it to the second bit and started cutting with the first bit again. The cut files are cut.sbp and cut_f.sbp (depending on the row). I have verified the movements in these files, and there shouldn't be any weird activity. Could it be that the files are corrupted? I've attached some of the code below.
&cola = 0
&colb = 7
&col2a = 0
&col2b = 7
&col3a = 0
&col3b = 7
&col4a = 0
&col4b = 7
&col5a = 0
&col5b = 7
&col4 = 0
&col6 = 0
check1a:
IF &cola = 0 THEN J2 .0312,&cola*3.6875
IF &cola = 8 THEN GOTO check1b
&cola = &cola + 1
FP cut.sbp,1,1,1,1,2
IF &cola < 8 THEN JY &cola*3.6875
IF &cola < 8 THEN GOTO check1a
check1b:
IF &colb = 7 THEN J2 .0625,&colb*3.6875
IF &colb = 16 THEN GOTO check2a
&colb = &colb + 1
FP cut.sbp,1,1,1,1,2
IF &colb < 16 THEN JY &colb*3.6875
IF &colb < 16 THEN GOTO check1b
check2a:
IF &col2a = 0 THEN J2 30.5,&col2a*3.6875
IF &col2a = 8 THEN GOTO check2b
&col2a = &col2a + 1
FP cut_f.sbp,1,1,1,1,2
IF &col2a < 8 THEN JY &col2a*3.6875
IF &col2a < 8 THEN GOTO check2a
check2b:
IF &col2b = 7 THEN J2 30.479,&col2b*3.6875
IF &col2b = 16 THEN GOTO check3a
&col2b = &col2b + 1
FP cut_f.sbp,1,1,1,1,2
IF &col2b < 16 THEN JY &col2b*3.6875
IF &col2b < 16 THEN GOTO check2b
check3a:
IF &col3a = 0 THEN J2 30.9375,&col3a*3.6875
IF &col3a = 8 THEN GOTO check3b
&col3a = &col3a + 1
FP cut.sbp,1,1,1,1,2
IF &col3a < 8 THEN JY &col3a*3.6875
IF &col3a < 8 THEN GOTO check3a
check3b:
IF &col3b = 7 THEN M2 31,&col3b*3.6875
IF &col3b = 16 THEN GOTO check4a
&col3b = &col3b + 1
FP cut.sbp,1,1,1,1,2
IF &col3b < 16 THEN JY &col3b*3.6875
IF &col3b < 16 THEN GOTO check3b
check4:
IF &col4 = 0 THEN J2 61.4375,&col4*3.6875
IF &col4 = 16 THEN GOTO check5a
&col4 = &col4 + 1
FP cut_f.sbp,1,1,1,1,2
IF &col4 < 16 THEN JY &col4*3.6875
IF &col4 < 16 THEN GOTO check4
check5a:
IF &col5a = 0 THEN J2 61.9062,&col5a*3.6875
IF &col5a = 8 THEN GOTO check5b
&col5a = &col5a + 1
FP cut.sbp,1,1,1,1,2
IF &col5a < 8 THEN JY &col5a*3.6875
IF &col5a < 8 THEN GOTO check5a
check5b:
IF &col5b = 7 THEN M2 61.9218,&col5b*3.6875
IF &col5b = 16 THEN GOTO check6
&col5b = &col5b + 1
FP cut.sbp,1,1,1,1,2
IF &col5b < 16 THEN JY &col5b*3.6875
IF &col5b < 16 THEN GOTO check5b
check6:
IF &col6 = 0 THEN J2 92.375,&col6*3.6875
IF &col6 = 16 THEN GOTO check7
&col6 = &col6 + 1
FP cut_f.sbp,1,1,1,1,2
IF &col6 < 16 THEN JY &col6*3.6875
IF &col6 < 16 THEN GOTO check6
check7:
END
END
&cola = 0
&colb = 7
&col2a = 0
&col2b = 7
&col3a = 0
&col3b = 7
&col4a = 0
&col4b = 7
&col5a = 0
&col5b = 7
&col4 = 0
&col6 = 0
check1a:
IF &cola = 0 THEN J2 .0312,&cola*3.6875
IF &cola = 8 THEN GOTO check1b
&cola = &cola + 1
FP cut.sbp,1,1,1,1,2
IF &cola < 8 THEN JY &cola*3.6875
IF &cola < 8 THEN GOTO check1a
check1b:
IF &colb = 7 THEN J2 .0625,&colb*3.6875
IF &colb = 16 THEN GOTO check2a
&colb = &colb + 1
FP cut.sbp,1,1,1,1,2
IF &colb < 16 THEN JY &colb*3.6875
IF &colb < 16 THEN GOTO check1b
check2a:
IF &col2a = 0 THEN J2 30.5,&col2a*3.6875
IF &col2a = 8 THEN GOTO check2b
&col2a = &col2a + 1
FP cut_f.sbp,1,1,1,1,2
IF &col2a < 8 THEN JY &col2a*3.6875
IF &col2a < 8 THEN GOTO check2a
check2b:
IF &col2b = 7 THEN J2 30.479,&col2b*3.6875
IF &col2b = 16 THEN GOTO check3a
&col2b = &col2b + 1
FP cut_f.sbp,1,1,1,1,2
IF &col2b < 16 THEN JY &col2b*3.6875
IF &col2b < 16 THEN GOTO check2b
check3a:
IF &col3a = 0 THEN J2 30.9375,&col3a*3.6875
IF &col3a = 8 THEN GOTO check3b
&col3a = &col3a + 1
FP cut.sbp,1,1,1,1,2
IF &col3a < 8 THEN JY &col3a*3.6875
IF &col3a < 8 THEN GOTO check3a
check3b:
IF &col3b = 7 THEN M2 31,&col3b*3.6875
IF &col3b = 16 THEN GOTO check4a
&col3b = &col3b + 1
FP cut.sbp,1,1,1,1,2
IF &col3b < 16 THEN JY &col3b*3.6875
IF &col3b < 16 THEN GOTO check3b
check4:
IF &col4 = 0 THEN J2 61.4375,&col4*3.6875
IF &col4 = 16 THEN GOTO check5a
&col4 = &col4 + 1
FP cut_f.sbp,1,1,1,1,2
IF &col4 < 16 THEN JY &col4*3.6875
IF &col4 < 16 THEN GOTO check4
check5a:
IF &col5a = 0 THEN J2 61.9062,&col5a*3.6875
IF &col5a = 8 THEN GOTO check5b
&col5a = &col5a + 1
FP cut.sbp,1,1,1,1,2
IF &col5a < 8 THEN JY &col5a*3.6875
IF &col5a < 8 THEN GOTO check5a
check5b:
IF &col5b = 7 THEN M2 61.9218,&col5b*3.6875
IF &col5b = 16 THEN GOTO check6
&col5b = &col5b + 1
FP cut.sbp,1,1,1,1,2
IF &col5b < 16 THEN JY &col5b*3.6875
IF &col5b < 16 THEN GOTO check5b
check6:
IF &col6 = 0 THEN J2 92.375,&col6*3.6875
IF &col6 = 16 THEN GOTO check7
&col6 = &col6 + 1
FP cut_f.sbp,1,1,1,1,2
IF &col6 < 16 THEN JY &col6*3.6875
IF &col6 < 16 THEN GOTO check6
check7:
END
END