Error in ANGULAR mode?

More
11 May 2013 05:50 #33909 by Mike_Eitel
Hi

I have problems with the acceleration of my 4t'h axis A.
Ubuntu 10, linuxcnc 2.5.2, 7i43, 4 stepper....

Axis X, X, Z... All fine, but
.
Can not get axis A to accelerate fast enough.
Getting strange behaviour when modifying MAX_ACCELERATION = 6000
to f.x small values =3... Result -> following error, and
to values > 100 -> no visible higher speed.

Is there eventually a bug in the ANGULAR implementation?
Or what is wrong in my implementation?

THX

............................................................. HAL.....

#*******************
# AXIS A
#*******************

# Step Gen signals/setup
setp hm2_7i43.0.stepgen.03.dirsetup [AXIS_3]DIRSETUP
setp hm2_7i43.0.stepgen.03.dirhold [AXIS_3]DIRHOLD
setp hm2_7i43.0.stepgen.03.steplen [AXIS_3]STEPLEN
setp hm2_7i43.0.stepgen.03.stepspace [AXIS_3]STEPSPACE
setp hm2_7i43.0.stepgen.03.position-scale [AXIS_3]STEP_SCALE
setp hm2_7i43.0.stepgen.03.step_type [AXIS_3]STEP_TYPE
setp hm2_7i43.0.stepgen.03.control-type [AXIS_3]CONTROL_TYPE
setp hm2_7i43.0.stepgen.03.maxaccel [AXIS_3]MAX_ACCELERATION
setp hm2_7i43.0.stepgen.03.maxvel [AXIS_3]MAX_VELOCITY

net a-pos-fb axis.3.motor-pos-fb <= hm2_7i43.0.stepgen.03.position-fb
net a-pos-cmd axis.3.motor-pos-cmd => hm2_7i43.0.stepgen.03.position-cmd
net a-enable axis.3.amp-enable-out => hm2_7i43.0.stepgen.03.enable

# ---setup home / limit switch signals---
net home-a => axis.3.home-sw-in
net a-neg-limit => axis.3.neg-lim-sw-in
net a-pos-limit => axis.3.pos-lim-sw-in

.............................................INI.......

#********************
# Axis A
#********************
[AXIS_3]
TYPE = ANGULAR
STEP_SCALE = 43.3333
MIN_LIMIT = -9999.0
MAX_LIMIT = 9999.0
MAX_VELOCITY = 300
MAX_ACCELERATION = 6000
BACKLASH = 0.00
FERROR = 0.05
MIN_FERROR = 0.0005

DIRSETUP =5000
DIRHOLD = 5000
STEPLEN = 5000
STEPSPACE = 5000
STEP_TYPE = 0
CONTROL_TYPE = FALSE

HOME = 0.0 # Position to finalize after homing
HOME_OFFSET = 0.0 # 125 # Location of the switch
HOME_SEARCH_VEL = 20 # Speed to find switch first time
HOME_LATCH_VEL = 10 # Speed for precise tripping switch
HOME_FINAL_VEL = 480 # Speed to move automaticaly to home position
HOME_IGNORE_LIMITS = 0 # Use the same switch for limit and alarm
HOME_IS_SHARED = 0 # No as there are seperate inputs for switches
HOME_SEQUENCE = 0 # Sequenze of homing the axes
HOME_USE_INDEX = 2 # Normal behaviour
VOLATILE_HOME = 0 # Stays home after E-Stop
#*******************

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

More
11 May 2013 06:00 - 11 May 2013 06:00 #33910 by PCW
Replied by PCW on topic Error in ANGULAR mode?
One possible issue:
When you change MAX_ACCEL, you must also change STEPGEN_MAXACCEL
STEPGEN_MAXACCEL must be approximately 25% more than the MAXACCEL value (for the corresponding axis)
for acceleration headroom or you will get a following error.
The same is true of STEPGEN_MAXVEL and MAXVEL though
in this case setting STEPGEN_MAXVEL to 0 (no limit)is OK
Last edit: 11 May 2013 06:00 by PCW.

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

More
11 May 2013 16:37 #33921 by Mike_Eitel
Replied by Mike_Eitel on topic Error in ANGULAR mode?
THX PCW

Just for my understanding ( As I like clearly and fully declared code that I fully understand )

You see my link of MAX_ACCELERATION to
hm2_7i43.0.stepgen.03.maxaccel [AXIS_3]MAX_ACCELERATION
( maybe wrong parameter and here should be the STEPGEN... one ? )

but I do not see a link posibility for second parameter STEPGEN_MAXACCEL

What part in the docs I do not see.

THX Mike

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

More
11 May 2013 23:23 #33930 by PCW
Replied by PCW on topic Error in ANGULAR mode?
MAX_ACCELERATION is used by the trajectory planner. It sets a limit to the acceleration that the trajectory planner can use (see the AXIS section on the integrators manual).

The hardware stepgen maxaccel limit is similar but needs to be about 25% more to accommodate clock timing differences and jitter in linuxCNC (it needs headroom to operate)
so they cannot share the same INI file parameter.

Take a look at the hm2-stepper.hal and 5i20.ini files in the ~/linuxcnc/configs/hm2-stepper director for an example.

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

More
11 May 2013 23:31 #33931 by pws
Replied by pws on topic Error in ANGULAR mode?
I agree with Mike - this is a point that I am stuck on also! I fail to see where you use MAX_ACCEL if you are using STEPGEN_MAX_ACC (also VEL) !

In other words, for the X Axis, if you have:

In the INI:

[AXIS_0]
...
STEPGEN_MAX_VEL = 2.1
STEPGEN_MAX_ACC = 2.5

And in the HAL:

setp hm2_[HOSTMOT2](BOARD).0.stepgen.00.maxvel [AXIS_0]STEPGEN_MAX_VEL
setp hm2_[HOSTMOT2](BOARD).0.stepgen.00.maxaccel [AXIS_0]STEPGEN_MAX_ACC

Would you need to have a MAX_ACCELERATION / MAX_VELOCITY also?

If so, what do you link it to or is it just a parameter that LinuxCNC EXPECTS?

Thanks for the assistance!

Paul

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

More
11 May 2013 23:47 #33933 by Mike_Eitel
Replied by Mike_Eitel on topic Error in ANGULAR mode?
Hi
Yes now things start to make sense. My INI file is not complete. I'll study manuals, fill up and test.

But I wonder how the planer is able to seperate linear and angular acceleration?
Or must I decide to have only one of them correct? Probably I have to use the higher of the A axis.

Keep you informed
THX Mike

[TRAJ]
AXES = 4
COORDINATES = X Y Z A
CYCLE_TIME = 0.010
HOME = 0 0 0 0
LINEAR_UNITS = mm
DEFAULT_VELOCITY = 4.0
DEFAULT_ACCELERATION = 20.0
MAX_LINEAR_VELOCITY = 150.00
ANGULAR_UNITS = degree
DEFAULT_ANGULAR_VELOCITY = 300.00
DEFAULT_ANGULAR_ACCELERATION = 1200.0
MAX_ANGULAR_VELOCITY = 3600.00
NO_FORCE_HOMING = 1
#POSITION_FILE=position.txt

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

More
12 May 2013 00:18 #33935 by Mike_Eitel
Replied by Mike_Eitel on topic Error in ANGULAR mode?
In the meantime I'm quite sure that something is different from what I expected

DEFAULT_ACCELERATION This is the parameter that shows reaction
DEFAULT_ANGULAR_ACCELERATION This does NOT shows differences
MAX_ACCELERATION First I wrote high value in but no result

Is something bugy or what do I missinterprete ?

THX Mike

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

More
12 May 2013 22:55 #33954 by pws
Replied by pws on topic Error in ANGULAR mode?
I want to thank PCW and Mike for this thread as it was full of information that I previously couldn't grasp - and needed to finalize my own files! The issues I was having are now gone!! My Mesa 6i25/Gecko G540 on the new computer hardware is now back on track for progress!

Regards, Paul

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

More
14 May 2013 04:01 #34035 by andypugh
Replied by andypugh on topic Error in ANGULAR mode?

DEFAULT_ACCELERATION This is the parameter that shows reaction
DEFAULT_ANGULAR_ACCELERATION This does NOT shows differences
MAX_ACCELERATION First I wrote high value in but no result


It is a little complicated…

Solving the equations of motion when rotary axes are included is not easy, because the G-code interpreter doesn't actually know what the working radius of the tool-tip is from the axis of rotation of the rotary.
So, during coordinated moves I acually have no idea how it handles the acceleration of the rotary axes.

Different limits apply during free jogging, coordinated movements and world-mode jogging with non-trivial kinematics.
www.linuxcnc.org/docs/html/config/ini_co...tml#sub:TRAJ-section
Gives some clues when you know that there are three different situations to cover.

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

Time to create page: 0.547 seconds
Powered by Kunena Forum