Thought I would try and refresh this post in hopes of getting a response.
I have written many macros but I am stumped as to solve my next macro project. I want to read in the tool list that is produced at the header of the program "n,output_tool_list", into an array. Assigning each tool label to the tool number.
I call tools by label but BobCad cannot call the next tool label only the next tool number. So prefetch doesn't work. If I can print the "output_tool_list in the script I can then build the array so I can finally write a macro to prefetch by label.
The beginning of my post looks like this:
1. Start of file programmed zero
n,comment_start,prog_name
n,comment_start,output_date," ",output_time
n,comment_start,machine_make,machine_model
n,comment_start,"TOOL LIST"
n,"()"
n,"( BLANK DIMENSIONS X",stock_length," Y",stock_width," Z",stock_height
n,"( PART POSITION X",zero_position_x," Y",zero_position_y
n,"()"
n,output_tool_list
program_block_2
G_CODE HEADER:
N1 ;STAT_1_16_09_28.MPF
N2 ;WED. 09/28/2016 11:39AM
N3 ; SIEMENS 810D
N4 ; TOOL LIST
N6 ; T58 CENTERDRILL.250 , DIAMETER = .25 , LENGTH =2.75)
N7 ; T37 DRILL.156 , DIAMETER = .1563 , LENGTH =3.125)
N8 ; T23 DRILL.204 , DIAMETER = .204 , LENGTH =3.75)
N9 ; T33 DRILL.149 , DIAMETER = .1495 , LENGTH =3.)
N5 G17 G70 G90 G94
TOOL CALL:
N7 T="CENTERDRILL.250" M06
Do you have any ideas?