MPG: axis.N.jog-vel-mode doesn't work as expected?

More
02 Mar 2016 00:58 #70880 by Sparky961
In attempting to configure my MPG/pendant, I first used the default axis.N.jog-vel-mode 0 but was concerned about safety because the axis will keep moving even though you've stopped cranking the knob. So I changed it to axis.N.jog-vel-mode 1 to see what would happen. If I crank it really fast it will keep going for a least a handful of revolutions after I've stopped turning it.

Isn't this what mode "1' is explicitly supposed to prevent?

mpg.hal:
setp axis.0.jog-vel-mode 1
setp axis.0.jog-scale 0.001
setp axis.0.jog-enable 1

net pend-counts axis.0.jog-counts <= hm2_5i25.0.7i77.0.0.enc0.count

Eventually I plan to use the scale and axis selection knobs of the MPG but for now I just have it directly connected (via HAL) to axis 0.

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

More
02 Mar 2016 02:11 #70882 by cmorley
jog-vel-mode stops as soon as possible while still honouring velocity and acceleration limits.
is your acceleration setting low?

Chris M

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

More
02 Mar 2016 03:09 #70887 by Sparky961
I don't yet know what values are reasonable for acceleration and velocity. I'm using a combination of defaults from PNCconf and possibly some changes I made for testing.

In the meantime I'll experiment with decreasing/increasing the acceleration to see if it makes a difference.

Here is a snippet from the INI file (There's likely to be some wonky stuff in here, as it's a work in progress):
[TRAJ]
AXES = 4
COORDINATES = X Y Z A
MAX_ANGULAR_VELOCITY = 360.00
DEFAULT_ANGULAR_VELOCITY = 36.00
LINEAR_UNITS = inch
ANGULAR_UNITS = degree
CYCLE_TIME = 0.010
DEFAULT_VELOCITY = 100.00
MAX_LINEAR_VELOCITY = 100.00
NO_FORCE_HOMING = 1

[AXIS_0]
TYPE = LINEAR
HOME = 0.0
FERROR = 1
MIN_FERROR = 0.5
MAX_VELOCITY = 50.0
MAX_ACCELERATION = 10.0
P = 10000.0
I = 100.0
D = 15.0
FF0 = 0.0
FF1 = 1.0
FF2 = 0.0
BIAS = 0.0
DEADBAND = 0.000015
MAX_OUTPUT = 0.0
ENCODER_SCALE = 101599.9967
OUTPUT_SCALE = 10.0
OUTPUT_MIN_LIMIT = -10.0
OUTPUT_MAX_LIMIT = 10.0
MIN_LIMIT = -999
MAX_LIMIT = 999
HOME_OFFSET = 0.0

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

More
02 Mar 2016 03:15 #70888 by Sparky961
As I'm playing around with this, I notice that if I turn the jog wheel quickly for a few seconds then the motor continues to turn for quite a few seconds (and revolutions) after I've stopped turning the jog wheel.

The speed at which it continues to rotate seems constant, rather than decelerating.

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

More
02 Mar 2016 03:32 #70889 by Sparky961
I'm beginning to wonder if this might be because I have the following error set quite high for initial testing. When I crank the jog wheel quickly I do notice the actual following error increase substantially and it's about when the following error catches up that the motor stops turning.

Is this consistent with the way it works - that accumulated following error isn't taken into consideration when attempting to stop the axis?

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

More
02 Mar 2016 03:37 #70890 by PCW
As cmorley hinted, low acceleration values can cause even velocity mode jogging to respond slowly

Your velocity and acceleration values are rather odd ( 3000 IPM velocity and 5 seconds to get there )

odd motion at this point may also be tuning related, tuning should precede any jogging tests

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

More
02 Mar 2016 03:49 #70891 by Sparky961

Your velocity and acceleration values are rather odd ( 3000 IPM velocity and 5 seconds to get there )


Indeed. If that's how it works out, those numbers are definitely wonky.

As for tuning, I could very well have some strange values in there now because it's just a free servo on the bench. I think I'll swap it with the one mounted to the rotary table so there's actually a load to tune.

I'm going to go hunting for information on determining velocity and acceleration numbers but any hints or pointers would be appreciated too.

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

More
02 Mar 2016 06:32 #70893 by PCW
Velocities in the INI/HAL files are in machine units per second
so 50 on a inch machine = 50 IPS = 3000 IPM (a scary fast machine)

Normally older mills and lathes will be in the couple of IPS region (say 120 to 600 IPM = 2 to 10 IPS)
and acceleration will be in the range of velocity*4 to velocity*10 = 8 to 100 IPS^2
(that is, acceleration will be in the range of 1/4 to 1/10 of a second to full speed)

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

More
02 Mar 2016 13:21 #70904 by andypugh

I'm beginning to wonder if this might be because I have the following error set quite high for initial testing. When I crank the jog wheel quickly I do notice the actual following error increase substantially


That's likely to be the problem. The commanded position is moving faster than the axis can track. When you stop turning the knob the commanded position stops changing, but the axis still is nowhere near the commanded position, and carries on moving until it gets there.

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

Time to create page: 0.081 seconds
Powered by Kunena Forum