- Posts: 2203
- Thank you received: 0
How to make a tool changer move to home
Aciera wrote: No need to alter the comp. We need to alter the M6 remap. that is a .ngc file. So see if you can find that and attach it please.
[edit]
Which GUI are you using? Axis or gmoccapy?
Thanks
Here is the remap:-
Attachment not found
This is the complere config:-
Attachment not found
Please Log in to join the conversation.
Like so:
Then start linuxcnc and load a tool. When you close Linuxcnc it should save the current tool number in the var file beside the parameter number 5400. Now start linuxCNC again and see if the toolnumber shows up in the status section.
I use gmoccapy and that loads the last used tool automatically.
Please Log in to join the conversation.
Aciera wrote: You know what, let's do a little experiment. Open your linuxcnc.var file and add parameter 5400 to the end of the parameter list:
Like so:
Code:5383 0.000000 5384 0.000000 5385 0.000000 5386 0.000000 5387 0.000000 5388 0.000000 5389 0.000000 5390 0.000000 5400 0.000000
Then start linuxcnc and load a tool. When you close Linuxcnc it should save the current tool number in the var file beside the parameter number 5400. Now start linuxCNC again and see if the toolnumber shows up in the status section.
I use gmoccapy and that loads the last used tool automatically.
OK Yes put 5400 into the var file and Yes on shutdown it shows the tool number in the var file.
but on start up the var file shows the tool number BUT you still have to input the tool into the MDI for the first run.
ie if it was tool 5 that showed in the var but if you then ran code with a different tool it would fail. Unless you had entered tool 5 at the start
Please Log in to join the conversation.
This should pop up a message in Axis after joint 0 is homed.
Do you want the tool to get loaded automatically when you start up or do you just want to be reminded to load the correct one (ie the one displayed in the status section?
Please Log in to join the conversation.
Aciera wrote: Ok. So as for the message you could put this into your .hal file:
Code:loadrt message names=msg.checktool messages="Check ATC for proper tool!" addf msg.checktool servo-thread net msg-checktool <= halui.joint.0.is-homed => msg.checktool.trigger
This should pop up a message in Axis after joint 0 is homed.
Do you want the tool to get loaded automatically when you start up or do you just want to be reminded to load the correct one (ie the one displayed in the status section?
There is already a msg that pops up saying something like load the tool number that is in place first.
This is after homing :-
Attachment not found
So it would be good if it could load the tool number from the var file at start up after homing
This is what happens to the status bar after putting M6T2 in MDI
Attachment not found
Then when any code is run it is fine even if different code is loaded as the system keeps track ok
Please Log in to join the conversation.
Can you try that in MDI after starting linuxcnc and see how that works?
Please Log in to join the conversation.
Aciera wrote: So after starting linuxcnc we could maybe issue:
Code:T#5400 M6
Can you try that in MDI after starting linuxcnc and see how that works?
Ok started with T1 in position homed then issued T#5400 M6 got the normal moment of the X and Z but No rotation of the turret. Status bar says NO TOOL checked the var value = 0
Then put m6t1 in MDI (no movement) Status bar says TOOL 1 checked the var value = 0
Then put m6t2 in MDI went to T2 Status bar says TOOL 2 checked the var value = 1
Then put m6t5 in MDI went to T5 Status bar says TOOL 2 checked the var value = 2
Shut down. and checked var file value = 5
Restarted-- var = 5. Homed . var = 5 Status = NO TOOL then issued T#5400 M6 got the normal moment of the X and Z but no rotation of the turret. Status bar says NO TOOL checked the var value = 0
Then put m6t5 in MDI went to T5 Status bar says TOOL 5 checked the var value = 0
Then put M6T6 in MDI went to T6 Status bar says TOOL 6 checked the var value = 5
Shut down VAR=6
Does the above help
Please Log in to join the conversation.
[edit]
need to have a look at it on a sim config tomorrow.
[edit2]
Just had an idea, instead of T#5400 M6 try:
[edit3]
just came across this:
forum.linuxcnc.org/38-general-linuxcnc-q...mory?start=10#130061
This looks like a very clever way of doing exactly what you want, I hope. It basically gets the M6 routine to write it's own subroutine for the next startup in a separate file in your config.
Please Log in to join the conversation.
Was you thinking about this one :- forum.linuxcnc.org/38-general-linuxcnc-q...mory?start=20#131272
or A Pugh forum.linuxcnc.org/38-general-linuxcnc-q...mory?start=10#130062
But If it can't be done then I will have to remember to input the tool at start-up.
Please Log in to join the conversation.
So try the m61 q#5400 and report back.
Please Log in to join the conversation.
