Tool Changer

More
29 Apr 2011 15:16 #9510 by ArcEye
Replied by ArcEye on topic Re:Tool Changer
Thank you John, I'll be *****ed!

All I did was cut and paste from the first page into gedit, but there must have been something there, because I just repeated the process and got a file exactly the same length, but this time it compiles!!!!!!!!!

I will check it loads and I can see the pins etc in a while, but have no reason to suspect that it won't.

The answer is often simple AFTER you have found it!

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

More
29 Apr 2011 15:26 #9511 by BigJohnT
Replied by BigJohnT on topic Re:Tool Changer
I'm glad you finally got that sorted out.

John

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

More
29 Apr 2011 15:44 #9514 by andypugh
Replied by andypugh on topic Re:Tool Changer
I would guess there is a closing brace missing at the end of the comp. Get_data_size is tagged on at the end by comp, it sounds like execution is running straight through.

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

More
02 May 2011 11:47 - 02 May 2011 16:01 #9534 by ArcEye
Replied by ArcEye on topic Re:Tool Changer
Hi again

Having got this working I was inspired to try to write my own component to suit my particular toolchanger. ( Boxford 240F)

It works well except for one thing, I cannot find find a way of connecting to stepgen.3.position-cmd
because it is already linked earlier in the .hal file (net apos-cmd axis.3.motor-pos-cmd => stepgen.3.position-cmd).

The stepper rotating the ATC is notionally axis A which allows me to jog it and move it in gcode.

I can track the commanded and actual position through pins linkages to the component but can't find a way to set it

I also seem to recall that in M6 moves, all jogging and other axis movement at a higher level is suspended until M6 is complete, which presumably means the stepper can only be moved by directly accessing the stepgen.

Can you enlighten me as to how this is best achieved?

regards

PS

Think I have answered my own question

I unlinked stepgen.3.position-cmd and stepgen.3.position-fb from axis.3 and linked them to the relevant pins in my toolchanger component, which operated the ATC in simulation.
Looks like there can only be one source of position commands for an axis.

I could run a script which linked them back to axis.3 when manual control was required, or perhaps have 2 stepgens and switch between them, have to investigate further.
Last edit: 02 May 2011 16:01 by ArcEye.

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

More
02 May 2011 11:52 - 02 May 2011 12:25 #9535 by Robin
Replied by Robin on topic Re:Tool Changer
I have the loadrt and addf

but now i got the set all the Inputs and outputs

someone know what is the best way to do it and can someone help me getting started with it

greetings Robin
Attachments:
Last edit: 02 May 2011 12:25 by Robin.

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

More
02 May 2011 15:30 #9544 by BigJohnT
Replied by BigJohnT on topic Re:Tool Changer
Robin,

Is your configuration from the StepConf Wizard?

Also read this short chapter on HAL.

www.linuxcnc.org/docview/html/hal_basic_hal.html

John

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

More
03 May 2011 10:40 #9551 by Robin
Replied by Robin on topic Re:Tool Changer
yeah all configuration is from stepconf, but i modified several things so it works good.
now i got to start to configure the toolchanger pins, but never did it before and quit hard for me but i'm going to try it with the help of the guide.

Robin

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

More
03 May 2011 12:43 - 03 May 2011 12:44 #9555 by BigJohnT
Replied by BigJohnT on topic Re:Tool Changer
If you make your connections in the custom.hal file they won't get overwritten by the wizard.

I would make one connection at a time then see if EMC loads to see if you have made a mistake.

John
Last edit: 03 May 2011 12:44 by BigJohnT.

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

More
03 May 2011 13:14 #9557 by ArcEye
Replied by ArcEye on topic Re:Tool Changer
The .hal configuration will be something like this

loadrt toolchanger
addf toolchanger.0 servo-thread

net tool-change iocontrol.0.tool-change => toolchanger.0.toolchange-req
net tool-changed iocontrol.0.tool-changed <= toolchanger.0.toolchange-ack
net tool-number iocontrol.0.tool-prep-number => toolchanger.0.tool-number
net atc-index toolchanger.0.index <= parport.N.pin-N-in
net pos-cmd toolchanger.0.position-cmd => stepgen.N.position-cmd
net tool-prepare-loopback iocontrol.0.tool-prepare => iocontrol.0.tool-prepared


You will need to specify which stepgen and which parport and pin the index signal is on

you also may need to change some of the default params on the fly to get the desired result
eg setp toolchanger.0.windback 4 if it doesn't go back enough
then you can put them in the comp when resolved

Read the manual on iocontrol and stepgen and the hal linkages should become clearer

regards

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

More
11 May 2011 11:51 #9722 by andypugh
Replied by andypugh on topic Re:Tool Changer
ArcEye wrote:

you also may need to change some of the default params on the fly to get the desired result
eg setp toolchanger.0.windback 4 if it doesn't go back enough
then you can put them in the comp when resolved

This would be a slightly odd way to do it. If the default value of a paramete ris not correct, then the normal solution is to have a setp command in the HAL file.

If you want to be extra-neat then you could add a [TOOLCHANGER] section to your INI file, like this:

[TOOLCHANGER]
WINDBACK=4

And then have a setp command in the HAL file:

setp toolchanger.0.windback [TOOLCHANGER]WINDBACK

But I would probably just put setp toolchanger.0.windback = 4 in the HAL file after the loadrt toolchanger line.

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

Time to create page: 0.107 seconds
Powered by Kunena Forum