Machsupport Forum

Mach Discussion => General Mach Discussion => Topic started by: billooms on May 02, 2012, 05:27:06 PM

Title: Question on behavior of rotary axis and rollover
Post by: billooms on May 02, 2012, 05:27:06 PM
I'm new to Mach3, so forgive the beginner question. I searched the forums, but was unable to find a description on the proper behavior of a rotary axis with the "Rot 360 rollover" and "Ang Short Rot on G0" boxes checked. Heres a simple g-code file:

g93 g1 x0.0 z0.0 c0 f20
g93 g1 x1.0 z0.1 c90 f20
g93 g1 x0.5 z0.2 c380 f20
g93 g1 x0.0 z0.0 c10 f20
g93 g1 x0.0 z0.0 c0 f20

The rotation goes to 90 degrees, then continues in a positive direction to 380 degrees. But then it goes backward a full turn plus. From the description in the Install-Config guide, I would have expected that after going to 380 degrees it would consider that the same as +20 degrees (that's what modulo 360 would mean) and only go backward 10 degrees. What am I missing here?

In truth, it behaves exactly the same way when the "Rot 360 rollover" box is not checked except for the DRO display. I conclude from this that the "Rot 360 rollover" box does nothing more than effect the appearance of the DRO. Is this correct?

In a second example:

g93 g1 x0.0 z0.0 c0 f20
g93 g1 x1.0 z0.1 c90 f20
g93 g1 x0.5 z0.2 c380 f20
g0 x0 z0 c0

The last line of g-code does in fact take the short route to zero as expected. However, I'm mystified about the behavior when the code is run a second time -- the C-axis unwraps a full turn on the first line of g-code. The Diagnostics tab does not show any offsets after the program has run, yet there must be some "hidden" offset somewhere that causes the C-axis to do a full negative rotation the next time the program is run. Can anyone explain why this is happening? Is there a way to clear whatever "hidden offset" is causing this to happen?

My application is a computerized ornamental lathe (hence the XZ coordinates) with a stepper driving the spindle for very precise control of the spindle rotation (wired to the C-axis driver).

Title: Re: Question on behavior of rotary axis and rollover
Post by: RICH on May 03, 2012, 05:43:44 PM
Rot 360 rollover – if checked the A axis DRO will display from 0 to 360 degrees and then start over at 0. If not checked the A axis DRO will be additive such that 2 revolutions will display as 720 degrees.

Ang Short Rot on G0 – The axis will move in the shortest possible move to a new position. So if at 0 degrees and you jogged  to 359 deg then it would just rotate  -1 degree.

Rotational Soft Limits – if checked will apply software limit switches to the rotary axis.


Hope the above helps,

RICH
Title: Re: Question on behavior of rotary axis and rollover
Post by: billooms on May 03, 2012, 06:46:26 PM
Thanks for the reply. That clarifies it.

Bill