Rotary "A" won't reset to zero after 360 degrees

More
08 Nov 2011 11:50 #14672 by jeff_HATC
I am cutting a part for a career fair. It is basically a round peice on a rotary table and it is cut into 4 slices like a pie. I cut each quarter then rotate the table 90 degrees. I run through this cycle 4 times

The program is something like this. (I am using AXIS)

repeat 4 times
cut section 1
rotate A90
cut section 2
rotate A180
cut section 3
rotate A 270
cut section 4
rotate 360. (My table is now physically back to zero its starting palce)
G92 A0 (but my display is at 360, so I force it to zero)
endrepeat
G92.1 A0 (trying to clean out register 5241 from 1,440 degrees to zero back to zero)
(that is 90 degrees x 4 slices= 360 x 4 repeats = 1440 degrees total)
G00 X0 Y0 Z1.0 A0

Ok here is the problem. After the 4th rotate, I want A to go back to zero. Why run the rotary table 360 degrees backwards, when it can just rotate forward 90 deglees forward? But when I do that, the display accumulates from 360 to 360+90=450. So I put the G92 in to set A back to zero after each 4 quarters are cut. Ok, fine so far. But at the end of the 4th repeat, I ussue G92.1 to set the register 5241 back to zero...as I know it is accumulating the G92's. The display then says A=1440 and runs the table back to zero for 1440 degrees...kind of defeating the whole purpose and wasting a lot of step motor time.

This is what I would like to do (in this order)
1) At the end of the 4th quarter I would like to home A to Zero. Can this be done by issuing some type of G code?

2) G10 sets variables to certain values for the cordinate system. Can it do this for register 5241?

3) I am not sure why a rotary table would be allowed to go past 360 anyways. Any way to force it to see 360 and zero as the same position?

Jr

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

More
08 Nov 2011 13:19 #14673 by andypugh
Replied by andypugh on topic Re:Rotary
jeff_HATC wrote:

2) G10 sets variables to certain values for the cordinate system. Can it do this for register 5241?

#5241 is the X-position of Coordinate System 2. Are you sure that is the one you want to set?
EMC2 will accumulate rotations in the motor position registers, that is just the way it is. it won't cause any problem until you get to several billion revolutions. It needs to do this to correctly sequence the step generator.

3) I am not sure why a rotary table would be allowed to go past 360 anyways.

. Milling spirals is one example, you could legitimately G1 X50 A3600 to make a 10-turn 3mm pitch spiral.

Any way to force it to see 360 and zero as the same position?

Yes, see WRAPPED_ROTARY in www.linuxcnc.org/docview/html/config_ini...b:%5BAXIS%5D-section

Whilst it makes sense to wrap a rotary if you are doing a position then mill sequence, if you are doing machining cuts using the rotary you almost certainly don't want to wrap.

I think you want to use G10 L20 A0 at the start of your cycle, and accept that the axis offset value will accumulate.
(doing it at the start means that the value in that parameter file will be reset on the first run after a restart.). The data types used mean that there is no danger of overflow.

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

More
08 Nov 2011 22:34 #14704 by jeff_HATC
Replied by jeff_HATC on topic Re:Rotary
Sorry Andy,
It was register 5214. Little dislexic.

I understand about the spiral. I was not thinking that far outside the box.

I see the WRAPPED ROTARY. That will probably work for me in my particular situation.

I guess I was unclear about the G10 usage.

In the example in the manual it gives G10 L20 P(something) (axis)...

In your example you left P blank. Does this assume coordinate system G53....or would leaving P blank assume what ever coordinate system was current at that time.


Thanks!

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

More
08 Nov 2011 22:53 #14706 by andypugh
Replied by andypugh on topic Re:Rotary
jeff_HATC wrote:

In your example you left P blank. Does this assume coordinate system G53....or would leaving P blank assume what ever coordinate system was current at that time.

I am pretty sure that if you omit P then the current coordinate system is assumed, but check the docs.

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

More
09 Nov 2011 04:21 - 09 Nov 2011 04:23 #14709 by cmorley
Replied by cmorley on topic Re:Rotary
P0 is the way to go (in EMC 2.5)
Last edit: 09 Nov 2011 04:23 by cmorley.

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

Time to create page: 0.075 seconds
Powered by Kunena Forum