Mazak QT20 Automatic tool changer

More
19 Mar 2023 11:50 #267082 by andypugh
Replied by andypugh on topic Mazak QT20 Automatic tool changer

When I run M06 T08 the turret just keeps turning and never find T08 .
 


I think I can guess the problem. What bit-pattern is T8? I suspect that it is seen as zero and rejected.
If it is all-false can you confirm that that pattern is only seen at T8 and not in-between positions?
The following user(s) said Thank You: dctrytsman

Please Log in or Create an account to join the conversation.

More
20 Mar 2023 12:58 #267145 by dctrytsman
Replied by dctrytsman on topic Mazak QT20 Automatic tool changer
You are right ,The bit pattern for T8 is all zeros. The bit pattern does not change in between positions ,it goes directly from one to another .How can I get it to work with all zeros ?

Please Log in or Create an account to join the conversation.

More
20 Mar 2023 14:30 #267151 by andypugh
Replied by andypugh on topic Mazak QT20 Automatic tool changer
A proper fix for the general case would be to have a settable flag to define zero = 2^(sense pins)
But, in your case, you could add a line to the carousel.comp file and re-compile it just for your system.

if you open a command line and type "halcompile -h" do you get an error or a help page? If it is "command not found" then you may need to install the "linuxcnc-dev" package.
The following user(s) said Thank You: dctrytsman

Please Log in or Create an account to join the conversation.

More
22 Mar 2023 06:51 #267277 by dctrytsman
Replied by dctrytsman on topic Mazak QT20 Automatic tool changer
I get a help page when I enter that .

Please Log in or Create an account to join the conversation.

More
22 Mar 2023 09:50 #267286 by andypugh
Replied by andypugh on topic Mazak QT20 Automatic tool changer
OK, that means that you can compile HAL components.

If you download this file:
raw.githubusercontent.com/LinuxCNC/linux...onents/carousel.comp

Then open it in a text editor (such as Geany) and change line 202-204 from
for(mask = new_pos >> 1 ; mask != 0 ; mask = mask >> 1){
            new_pos ^= mask;
        }
        break;

to
for(mask = new_pos >> 1 ; mask != 0 ; mask = mask >> 1){
            new_pos ^= mask;
        }
        if (new_pos == 0) new_pos = 8;
        break;

Then save the file and use the command
sudo halcompile --install carousel.comp
The following user(s) said Thank You: dctrytsman

Please Log in or Create an account to join the conversation.

More
22 Mar 2023 11:55 #267299 by dctrytsman
Replied by dctrytsman on topic Mazak QT20 Automatic tool changer
Thanks ,everything is working now .

Please Log in or Create an account to join the conversation.

More
22 Mar 2023 13:24 #267305 by andypugh
Replied by andypugh on topic Mazak QT20 Automatic tool changer
Great. That fix is rather specific to your 8-pocket changer, so I have created this issue to track a more generic fix:
github.com/LinuxCNC/linuxcnc/issues/2404
The following user(s) said Thank You: dctrytsman

Please Log in or Create an account to join the conversation.

More
16 Apr 2025 14:48 #326463 by dctrytsman
Replied by dctrytsman on topic Mazak QT20 Automatic tool changer
The X-axis servo motor and drive failed a few months ago and I haven't touched the machine ever since. I finally got back to fixing the machine, but I want to make some tweaks to the tool changer.

Everything works ok, but I need to add a timing delay when making a tool change. The motor starts turning immediately as soon as you make a tool change, thus not allowing the tool changer to fully unclamp. This causes the tool post to move back and forth until it is unclamped and then it will do the tool change as it's supposed to. I'm sure if i keep running it like this something is eventually going to break or wear .

How do I add a time delay so that the control waits for the tool changer to fully unclamp, and then rotate to the correct position, and re-clamp.

I will attach my HAL files, I don't think I set it up 100% either.

Please Log in or Create an account to join the conversation.

More
16 Apr 2025 14:57 #326465 by dctrytsman
Replied by dctrytsman on topic Mazak QT20 Automatic tool changer
Attached HAL Files
Attachments:

Please Log in or Create an account to join the conversation.

More
18 Apr 2025 09:38 #326582 by andypugh
Replied by andypugh on topic Mazak QT20 Automatic tool changer
I would suggest that you connect iocontrol.0.tool-prepare to the turret-unclamp output pin, and then connect carousel.0.enable to the turret-unclamp-ready pin.

That way a tool change request will immediately unclamp the turret, and the carousel component will only start up once the turret is actually unclamped.

Probably, some experimentation may be needed, especially regarding how the re-clamping happens.

Please Log in or Create an account to join the conversation.

Moderators: piasdom
Time to create page: 0.283 seconds
Powered by Kunena Forum