What's new
What's new

Doosan SMX 2100ST Tool Offset Variables for Macro Use

Baddd

Plastic
Joined
Feb 16, 2024
Location
Richmond, BC
Hello I'm brand new here, so please be patient. I've been scouring the internet, and forums, but I haven't found a solution.

I'm trying to create a tool break detection macro for my machine to be able to run unattended, but stop if there is a broken tool. I'm using a Renishaw probe to check sizes, and a BK Micro to check for broken drills. I would like this macro to test for chipping of the threading tool, since my other detection systems can't check for small deviations inside of a thread, or on an insert.

This machine is using a 31i-B5 controller, and I've located the offset information in the EXEC MACRO screen.
17XXX is for the X-Axis
18XXX is for the Z-Axis

The problem I'm having is writing these variables into a custom variable. I've tried a few variations to get it to write into a custom variable without success.

#749=#4120 (TOOL CURRENTLY IN SPINDLE)
#750=FIX[#749/1000] (MATH TO ISOLATE TOOL NUMBER)

#751=PRM[#[#750+17000]] (CURRENT TOOL OFFSET X)
and/or #751=#[#750+17000]
and/or #751=#17032
and/or #751=PRM[#17032]

If anyone knows how to use the #17000 and #18000 variables in this control, I would appreciate your help. I'm happy to provide more information as needed.
 
Never ran that machine but I use g65 p9028 on all our Doosan’s for tool break.
Thanks for the tip, I looked into our 9000 programs, and this one doesn't exist for this machine. I think P9028 may be for milling machines, using the height setter. This is a mill turn and there is no height setter. It uses an arm to set the tools, more like a lathe.
 
I have not used this control, but I think PRM is not needed here.
Thanks Sinha,

I tried the variation #751=#17002 and the control accepts this command without an error. The problem is that there is a value in #17002, but #751 still shows 0.00.
 
I have no explanation for this. There might be something in the program.

Run #751 = 1 in MDI and check the value.
#751=1 works as expected, and puts the value of 1.

I've tried a few numbers in MDI, #751=#17002 the value doesn't match, I've tried #751=#16030 with the same result. 0.00
 
#17002 in your case and on this machine is not an executive macro. It is a system variable for tool offsets and cannot be observed like the executive macros can. They can be read though. Check your tool offset and use the attached PDF to see if you can read the tool offsets described in the PDF.

Paul
 

Attachments

  • 31iB5PLUS system variables.pdf
    664.7 KB · Views: 9
#17002 in your case and on this machine is not an executive macro. It is a system variable for tool offsets and cannot be observed like the executive macros can. They can be read though. Check your tool offset and use the attached PDF to see if you can read the tool offsets described in the PDF.

Paul
Thanks for this LockNut!

This is the portion I'm working with now.

oGEAL9rDEW2Espnp.png

I have a slight issue. I'm not sure how or why, but my machine is set to use 17001-17999 as X, and 18001-18999 as Z. There are no values in 15001-16999 stored in my machine. Do you know if this is a parameter setting that needs adjusting?


I can get my X value for T01001 by entering #751=[#_OFSRG[1]]. This should give me the value of the nose radius, but it is definitely my X value. I can work with this, but there is no address for the 18001-18999 values.
 
I want to see what the solution is to this because I thought it would be #751= [#_OFSXG[1]] instead. Isyour control that much different? or like you said maybe a parameter?
 
I want to see what the solution is to this because I thought it would be #751= [#_OFSXG[1]] instead. Isyour control that much different? or like you said maybe a parameter?
It seems very strange. I also have inquiries out to Fanuc, and DNS. If I hear from them I will post it here too!!
 
In case you didn't know Locknut worked for DNS. He is good.
"works" for DN. The issue I stated I received from an older book, maybe, and not exactly suited for an SMX. Part of the problem is that the SMX is a 2 path control and these system variables might not line up the same way as on a single path control. There may be a different set for the B Axis and another for the lower turret. I don't work with SMX's, I work on milling and 5 axis. I do sit next to our SMX guru, I will ask him.
 
"works" for DN. The issue I stated I received from an older book, maybe, and not exactly suited for an SMX. Part of the problem is that the SMX is a 2 path control and these system variables might not line up the same way as on a single path control. There may be a different set for the B Axis and another for the lower turret. I don't work with SMX's, I work on milling and 5 axis. I do sit next to our SMX guru, I will ask him.
my mistake good sir. :o
 
I made a mistake. I've been focused on the #17000, and #18000 numbers, and the #751= [#_OFSXG[1]] is giving me the correct value. I must have read the #751= [#_OFSRG[1]] wrong. I apologize for the confusion.

I've been working on my code, and using the G36/G37 to probe the tool. For some reason these codes aren't writing the measurement into the tool geometry. This is what I've got so far. Everything works, except for the geometry is not being updated.

%
O0001(UPPER TOOL OFFSET MEASURE)
(FOR BORING BAR TOOLS B-90. J1.)
(MACRO #'s USED)
(#747 - Z ALLOWABLE DEVIATION - EDITABLE)
(#748 - X ALLOWABLE DEVIATION - EDITABLE)
(#749 - TOOL CURRENTLY IN SPINDLE)
(#750 - MATH TO ISOLATE TOOL NUMBER)
(#751 - CURRENT TOOL OFFSET X)
(#752 - CURRENT TOOL OFFSET Z)
(#753 - MEASURED TOOL OFFSET X)
(#754 - MEASURED TOOL OFFSET Z)
(#755 - WEAR OFFSET X)
(#756 - WEAR OFFSET Z)
(#757 - CURRENT G57 X)
(#758 - CURRENT G57 Z)
#748=0.0010(X ALLOWABLE DEVIATION - EDIT AS NEEDED)
#747=0.0007(Z ALLOWABLE DEVIATION - EDIT AS NEEDED)
#749=#4120(TOOL CURRENTLY IN SPINDLE)
#750=FIX[#749/1000](MATH TO ISOLATE TOOL NUMBER)
#751=[#_OFSXG[#750]](CURRENT TOOL OFFSET X)
#752=[#_OFSZG[#750]](CURRENT TOOL OFFSET Z)
#755=[#_OFSXW[#750]](CURRENT WEAR OFFSET X)
#756=[#_OFSZW[#750]](CURRENT WEAR OFFSET Z)
#757=[#_WZG57[1]](CURRENT G57 X)
#758=[#_WZG57[2]](CURRENT G57 Z)
G10 L2 P4 Z1008.58084 X1022.81731 (SET G57 FOR MEASURING)
G0G18G20G40G57G80G98
M34
M134
M139

G0G28U0.V0.W0.
T[#750*1000+#750]( TOOL WITH OFFSET )

G400B-90.J1.
T[#750*1000+#750]( TOOL WITH OFFSET )
M77 (Q-SETTER ARM ADVANCE)
G01Z-1000.0X-1000.0F250. (MOVE TO SAFE POSITION)
W-0.298 (POSITION Z TO MEASURE FOR X)
F0.9
G36 U0.3 (MEASURE X)
G4P500
F250.
U-0.2 (RETRACT FROM MEASURE)
Z-1000.0X-1000.0 (MOVE TO SAFE POSITION)
U0.596 (POSITION X TO MEASURE FOR Z)
F0.9
G37 W-0.2 (MEASURE Z)
G4P500
F250.
G0 W0.2 (RETRACT FROM MEASURE)
M76 (Q-SETTER ARM RETRACT)
#753=[#_OFSXG[#750]](MEASURED TOOL OFFSET X)
#754=[#_OFSZG[#750]](MEASURED TOOL OFFSET Z)
[#_OFSXG[#750]]=#751(SET X TO ORIGINAL VALUE)
[#_OFSZG[#750]]=#752(SET Z TO ORIGINAL VALUE)
[#_OFSXW[#750]]=#755(SET WEAR OFFSET X TO ORIGINAL VALUE)
[#_OFSZW[#750]]=#756(SET WEAR OFFSET Z TO ORIGINAL VALUE)
[#_WZG57[1]]=#757(SET G57 X TO ORIGINAL VALUE)
[#_WZG57[2]]=#758(SET G57 Z TO ORIGINAL VALUE)
IF[[#751-#753]GE#748]THEN #3000=1 (X DEVIATION TOO GREAT)
IF[[#753-#751]GE#748]THEN #3000=1 (X DEVIATION TOO GREAT)
IF[[#752-#754]GE#747]THEN #3000=2 (Z DEVIATION TOO GREAT)
IF[[#754-#752]GE#747]THEN #3000=2 (Z DEVIATION TOO GREAT)

G28U0.V0.W0.M34

M30
%
 
I agree that it wouldn't be wise to use this to set tools, or change offsets. I'm only trying to check whether the tool is chipped, and then setting the offsets back to their original settings. Is there a different code, or setting that you would recommend?
 








 
Back
Top