adding an automatic tool number after homing

More
28 Oct 2022 15:34 #255303 by hitchhiker
i love u andy! :)
The following user(s) said Thank You: tommylight

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

More
28 Oct 2022 20:32 #255331 by Wusel
I spent some more time on the toolchanger and I get at least something moving, but I am still missing a vital part.
Attached find the ini file and the toolchange ngc. I tried to remap the M6 command. It takes the current tool and the selected one, calculates the difference and the necessary angle of rotation and rotates the revolver and afterwards some reversal for locking it. That part is ok, -
The sequence currently is as followed: I home all axis, set the tool to eg 1 via M61 Q1, then type T5 for selecting tool 5 and the M6 for the actual tool change. After hitting T5 Linux seems to be waiting for something. One can see in the yellow light for tool change request and in the file section most of the entries are inactiv (grey). Only when I press ESC the yellow LEDs come off and when I hit M6 now, the revolver rotates as desired but leaving the movement without changing the tool numer and again with tool change Request 'on'. To my understanding I only wanted to remap M6 but if I use only M6 in the toolchange macro I get the error message that a new tool has to ber prepared even though in the hal monitor I see a new tool prepared. Any suggestions on that?

regards
Rainer

File Attachment:

File Name: LuxTurn_LT...0-28.ini
File Size:5 KB

File Attachment:

File Name: toolchange.ngc
File Size:0 KB
Attachments:

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

More
28 Oct 2022 21:18 #255338 by andypugh
In the HAL check the connections for iocontrol.0.tool-prepare and iocontrol.0.tool-prepared.

For the moment they probably need to be connected together, something like

net prepare-loop iocontrol.0.tool-prepare => iocontrol.0.tool-prepared.

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

More
01 Nov 2022 19:14 #255684 by Wusel
I used the weekend to play a bit further and finally I have a result I am happy with. The tool changer rotates as required and sets the right tool numer and uses the tool offset data from the tool table. The first tool is set after homing the TC - all in all- thanks for your help.
I quite like LinuxCNc with all the knowledge behind shared by so many kompetent users but as often with open source software, it seems to me that I have been reinventing the wheel with my tiny project. I am sure that hundreds have done it before but I don't seem to find a pool of example machines. There are bits in the WIKI though. Anyhow, I am quite happy to share my hal and ini and TC macro. If there is a suitable place to store it so others can find it feel free to move them there or let me know where to put them

regards
Rainer
Is there

File Attachment:

File Name: LuxTurn_LT...1-01.hal
File Size:14 KB

File Attachment:

File Name: toolchange...1-01.ngc
File Size:1 KB

File Attachment:

File Name: LuxTurn_LT...1-01.ini
File Size:5 KB
Attachments:

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

Time to create page: 0.168 seconds
Powered by Kunena Forum