5-axis kinematics

More
24 Oct 2011 12:42 #14165 by hempul
5-axis kinematics was created by hempul
I try to integrate a home made 5-axis milling machine with a A-joint stacked
on a B-joint for a tilting head. I understand how the distance between the toolholder
and the A-joint and the distance between the A-joint and the B-joint is received
from a HAL-file for use in the kinematic module. The kinematic module is however
required to know the current tool length as well, activated by the G43 command
in order to tilt around the tool tip but I don´t understand how to get it. Help!

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

More
24 Oct 2011 12:52 #14166 by andypugh
Replied by andypugh on topic Re:5-axis kinematics
git.linuxcnc.org/gitweb?p=emc2.git;a=blo...c01726a50440f6045d8d

Uses a HAL pin to provide the tool length.
I assume that the idea is to link that to motion.tooloffset.z in the HAL file.
linuxcnc.org/docs/html/config_emc2hal.html

I think this is the only way, as no tool information is passed to the kinematics code.

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

More
24 Oct 2011 13:32 #14168 by hempul
Replied by hempul on topic Re:5-axis kinematics
When I try

struct haldata {
hal_float_t *ab; /* a-joint to b-joint length */
hal_float_t *ah; /* a-joint pivot length excl. tool length */
hal_float_t *ht; /* tool length */
} *haldata;

in the kintematics
and then in the Hal-file

setp tdankins.AB 85.0
setp tdankins.AH 75.0
setp tdankins.HT motion.tooloffset.z

I got
value ´motion.tooloffset.z´ invalid for float

Wat´s wrong?

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

More
24 Oct 2011 14:08 #14170 by andypugh
Replied by andypugh on topic Re:5-axis kinematics
hempul wrote:

setp tdankins.AB 85.0
setp tdankins.AH 75.0
setp tdankins.HT motion.tooloffset.z

I got
value ´motion.tooloffset.z´ invalid for float

Wat´s wrong?


motion.tooloffset.z is a pin name. Setp requires a numeric value.
You need net tool-length tdankins.HT <= motion.tooloffset.z
Then the value of the tool length will be continually written to your tdankins.HT pin.

This assumes you also added a hal_pin_float_new function for the new pin to the kins file (and that it is a pin, not a param)

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

More
28 Oct 2011 16:46 #14346 by hempul
Replied by hempul on topic Re:5-axis kinematics
My kinematic module is now able to let the tool bend around the tool tip,
and the motion.tooloffset.z value is received by the kinematics but each time
G43 or G49 is executed the machine stops with joint 0 following error.
How is that message supposed to be understood.

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

More
28 Oct 2011 18:54 #14351 by andypugh
Replied by andypugh on topic Re:5-axis kinematics
hempul wrote:

My kinematic module is now able to let the tool bend around the tool tip,
and the motion.tooloffset.z value is received by the kinematics but each time
G43 or G49 is executed the machine stops with joint 0 following error.
How is that message supposed to be understood.


What this indicates is that the required position for the X axis with the new Z-length is further from the current position than the machine following-error limit.

Do you get this message even with the head vertical, so that the tool length is parallel to the Z axis?

Unfortunately I don't think that EMC2 expects to see a shift in the X axis when a tool offset with no X-offset value in it is specified. I am not sure if this counts as a bug or not.

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

More
28 Oct 2011 20:02 #14355 by andypugh
Replied by andypugh on topic Re:5-axis kinematics
OK, having talked to the author of the kinematics file, I have been giving you bad advice.

Sorry.

You need to remove that link to the 5axiskins.tooloffset.z pin. That pin should be left unconnected and not used.

You need to setp the 5axiskins.pivot-length pin to the correct number in the HAL file, then not change it.

Your tool-table needs to put the actual tool lengths in the W column. You should then find that it all works OK.

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

More
29 Oct 2011 05:18 #14360 by hempul
Replied by hempul on topic Re:5-axis kinematics
It seems like the move after the G43 or G49 could involve any axis provided that
the Z-axis is one of them and G90 is on, but both A and B axis must be zero before
the G43 or G49 is executed.

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

More
29 Oct 2011 11:18 #14369 by andypugh
Replied by andypugh on topic Re:5-axis kinematics
I think perhaps my correct reply got lost in the page-break.

Did you see the message about putting tool-length in W?

Incidentally, working that way you should be able to drill angled holes using W-axis moves.

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

More
29 Oct 2011 15:15 #14381 by hempul
Replied by hempul on topic Re:5-axis kinematics
I can't find much information about the coordinate systems and how to use all info in
the .var-file in a smart way. I don´t know how to read this info in other way than using
the G5x or the G92 command.
A CAM software is probably quite happy with my five joints, but I find it joyful to do
complicated tool geometrics with the macro interpreter, so my simple solution is as follows.
I have set up my ini and hal-file to activate all nine axis and the AXIS display seems to
know what I want to do. The kinematics however do noting for the u,v,w-axes. What
I have to do is thus code for the transformation to the joints according to the current
plane set by the G5x or the G92 command. Here comes my problem. How to get the
plane parameters. Hopefully there is a simple answer to this, but if not I can first position
the tool in front of the wanted plane, execute G92 X0 Y0 Z0 A0 B0 C0 and then execute
G0 C [value + 360] . The kinematics can detect the large C-value and lock the
transformation parameters until C sets lower than 360. There is no C joint so
the value is only used to turn the tool coordinate system. It looks kind of stupid but
Please describe a more elegant solution. I have no professional cnc experience so I
have really no idea how this is supposed to be done. I just think this is a lot of fun.

How can I read the tool diameter or should I put the diameter in another row as well
so it can be read the same way as motion.tooloffset.z ?

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

Time to create page: 0.156 seconds
Powered by Kunena Forum