- Posts: 1943
- Thank you received: 0
Tool table in CAM, LinuxCNC & pockets in a non-random tool changer
Please Log in to join the conversation.
- My tool changer needs to put the tool in the same pocket again from which it was loaded (!random)
- My tool changer has 9 pocket, ID 1 to 9, which I fill manually with tools, tool IDs between 1 and 50
- Therefore a pocket btw. 1-9 shall only be used once in the tool table, because physically there cannot be 2 tools in 1 pocket
- Exception for me: pocket 0 means not in the tool changer at all.
Example:
Tool 17 was in pocket 3 and actually loaded in spindle.
Tool 5 is in pocket 9.
M6 T5 is called.
Algo is like this:
--> search t17 in tool table, get pocket no 3
--> tool changer is moved to pocket 3
--> tool 17 is unloaded
--> search T5 in tool table, get pocket no 9
--> tool changer is moved to pocket 9
--> tool 5 is loaded
Please Log in to join the conversation.
mydani wrote: I have to say I disagree.
- My tool changer needs to put the tool in the same pocket again from which it was loaded (!random)
- My tool changer has 9 pocket, ID 1 to 9, which I fill manually with tools, tool IDs between 1 and 50
- Therefore a pocket btw. 1-9 shall only be used once in the tool table, because physically there cannot be 2 tools in 1 pocket
- Exception for me: pocket 0 means not in the tool changer at all.
Example:
Tool 17 was in pocket 3 and actually loaded in spindle.
Tool 5 is in pocket 9.
M6 T5 is called.
Algo is like this:
--> search t17 in tool table, get pocket no 3
--> tool changer is moved to pocket 3
--> tool 17 is unloaded
--> search T5 in tool table, get pocket no 9
--> tool changer is moved to pocket 9
--> tool 5 is loaded
That is a random toolchanger. Pockets in random toolchanger and non-random toolchanger are handled differently.
Please Log in to join the conversation.
"RANDOM_TOOLCHANGER = 1 - This is for machines that cannot place the tool back into the pocket it came from. For example, machines that exchange the tool in the active pocket with the tool in the spindle."
My tool changer can and must place the tool back into the pocket it came from.
So I think I am right by saying, as per this documentation, I do not have a random toolchanger.
Please Log in to join the conversation.
mydani wrote: This is what the documentation says :
"RANDOM_TOOLCHANGER = 1 - This is for machines that cannot place the tool back into the pocket it came from. For example, machines that exchange the tool in the active pocket with the tool in the spindle."
My tool changer can and must place the tool back into the pocket it came from.
So I think I am right by saying, as per this documentation, I do not have a random toolchanger.
Yeah that's a non-random. I misunderstood your explanation.
Please Log in to join the conversation.
mydani wrote: I have to say I disagree.
- My tool changer needs to put the tool in the same pocket again from which it was loaded (!random)
- My tool changer has 9 pocket, ID 1 to 9, which I fill manually with tools, tool IDs between 1 and 50
- Therefore a pocket btw. 1-9 shall only be used once in the tool table, because physically there cannot be 2 tools in 1 pocket
- Exception for me: pocket 0 means not in the tool changer at all.
Example:
Tool 17 was in pocket 3 and actually loaded in spindle.
Tool 5 is in pocket 9.
M6 T5 is called.
Algo is like this:
--> search t17 in tool table, get pocket no 3
--> tool changer is moved to pocket 3
--> tool 17 is unloaded
--> search T5 in tool table, get pocket no 9
--> tool changer is moved to pocket 9
--> tool 5 is loaded
So your manually changing the pockets in the tool table when you add a tool that does not have a pocket that equals the tool number.
I don't see any other way around it. Thats why if you could have same pocket #'s for different tools, then you could handle that in the remap code and only have to just swap out tools out of the magazine and not have to deal wioth the tool table. Thats all I was saying.
Please Log in to join the conversation.
If you have 4 tools that you put in pocket 5, then put them in the tool table in pockets 5, 15, 25.
Then, simply pass T-number MOD 10 to whatever drives the tool changer logic.
Though I agree that neither tool number or pocket number should have to be unique. (though most databases need some unique key, so even the database schema I came up with had such an identifier:
wiki.linuxcnc.org/cgi-bin/wiki.pl?ToolDatabase
In that case you would switch tool "sets" by changing the active "magazine"
Please Log in to join the conversation.
Guess the uniqueness thing is a matter of taste - coming from some decades of development, a tool and a pocket is a physically existing unique thing, and therefore - imho - should be represented only once also within the SW. I understand that the experiences or limitations of the current implementation leads to the wish to have it otherwise.
I will stick my nose in the code some more and change the interpreter accordingly...
Cheers
Daniel
Please Log in to join the conversation.
andypugh wrote: One way round the more-tools-than-pockets thing is to do something clever with the pocket numbers in your tool changer HAL or remap.
If you have 4 tools that you put in pocket 5, then put them in the tool table in pockets 5, 15, 25.
Then, simply pass T-number MOD 10 to whatever drives the tool changer logic.
Though I agree that neither tool number or pocket number should have to be unique. (though most databases need some unique key, so even the database schema I came up with had such an identifier:
wiki.linuxcnc.org/cgi-bin/wiki.pl?ToolDatabase
In that case you would switch tool "sets" by changing the active "magazine"
Is your DB interface working? Can I query it, write to a record and read a field within python during a remap?
Please Log in to join the conversation.
bevins wrote: Is your DB interface working? Can I query it, write to a record and read a field within python during a remap?
In a word, "No"
I didn't manage to persuade anyoen else to even try the experimental branch, so it has been fallow for several years.
github.com/LinuxCNC/linuxcnc/commits/andypugh/tooltable
Look for commits around July 2013 for the files that were changed.
Looking back at it I think that there might be a sample config, but not a lot of docs. (any, in fact)
That version attempts to have a user-editable python interface interacting with a usr-defined tool database.
I don't think any of the samples there actually use the proposed schema.
Please Log in to join the conversation.
