Retrofit Gloria Europa 2/40 machining centre

More
27 Jun 2016 11:03 #76700 by backtime
Ok, now everything is working, but I have problems with ferror, I tested three different configurations.

Since the loop is closed on the driver I tried pure stepper configuration, this is an excerpt.
setp hm2_5i25.0.stepgen.00.control-type 0
net x-pos-cmd <= axis.0.motor-pos-cmd
net x-pos-cmd => hm2_5i25.0.stepgen.00.position-cmd
net x-pos-fb => axis.0.motor-pos-fb
net x-pos-fb <= hm2_5i25.0.stepgen.00.position-fb
this configuration is fully functional and has no ferror issue.

Then I tried the setup with the feedback encoder without PID, I know that this setup does not give good results, I tried it out of curiosity.
setp hm2_5i25.0.stepgen.00.control-type 0
net x-pos-cmd <= axis.0.motor-pos-cmd
net x-pos-cmd => hm2_5i25.0.stepgen.00.position-cmd
net x-pos-fb => axis.0.motor-pos-fb
net x-pos-fb <= hm2_5i25.0.encoder.00.position
In fact, with this configuration, the ferror value is very high (more than 10) also at medium speed.

The final configuration should be the most correct, PID with encoder and velocity control type.
setp hm2_5i25.0.stepgen.00.control-type 1
net x-pos-cmd <= axis.0.motor-pos-cmd
net x-pos-cmd => pid.x.command
net x-vel-cmd <= axis.0.joint-vel-cmd
net x-vel-cmd => pid.x.command-deriv
net x-pos-fb => pid.x.feedback
net x-pos-fb <= hm2_5i25.0.encoder.00.position
net x-pos-fb => axis.0.motor-pos-fb
net x-output => pid.x.output
net x-output <= hm2_5i25.0.stepgen.00.velocity-cmd
Unfortunately the ferror value remains high especially at high speed and during
the accelerations. The value then drops during the movements but only at low speed.

At high speed PID is not able to correct the error quickly enough so that it remains high (not below 4/5).

These are the acceleration, maximum speed and PID parameters:
MAX_VELOCITY = 500.0
MAX_ACCELERATION = 2000.0
STEPGEN_MAXVEL = 625.00
STEPGEN_MAXACCEL = 2500.00

P = 1000.0
I = 0.0
D = 0.0
FF0 = 0.0
FF1 = 1.0
FF2 = 0.0
BIAS = 0.0
DEADBAND = 0.0
MAX_OUTPUT = 0.0

I searched the forums to find configurations similar to my driver, but I could not find anything.
Maybe I have not looked properly. If anyone has any advice I would be happy.

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

More
27 Jun 2016 12:51 - 27 Jun 2016 14:01 #76705 by PCW
Are the encoder counts per machine unit and steps per machine unit identical?
if so are the INPUT_SCALE and OUTPUT_SCALE identical as well?

edit:
if they are not identical , the INPUT_SCALE and OUTPUT_SCALE parameters must be scaled to match
Last edit: 27 Jun 2016 14:01 by PCW.

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

More
27 Jun 2016 13:56 #76708 by backtime
Hi PCW, i have this configuration:

  • 10mm pitch ball screw
  • steps for rev: 10000
  • encoder counts for rev: 2500

So if I'm not wrong, we have:

10000/10 = 1000 step for mm
2500*4/10 = 1000 pulse per mm

but in my ini file i don't have INPUT_SCALE and OUTPUT_SCALE parameters, i have

ENCODER_SCALE = 4000.0
STEP_SCALE = 1000.0

But now I see that the ENCODER_SCALE is wrong, I have to put 1000.0 in this parameter right? I must have been out of my mind.

Which configuration is best to use of the three I tested? The one with encoder, PID and StepGen in velocity mode seems to me the best, can you confirm that?

Thank you.

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

More
27 Jun 2016 15:05 #76709 by PCW
Yes, for step dir drives with encoders this is the best way

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

More
30 Jun 2016 07:28 #76822 by backtime
I modified the INI file to have the correct values for ENCODER_SCALE and STEP_SCALE. Now they are both at 1000.0.

We ran some tests with centesimal gauges, machine movements are correct as final coordinates, but the ferror value
remains very high (> 10) at the beginning and during the high-speed movement, then to zero at the end of the movement.

I do not know what else I could do, maybe changing the PID parameters can improve but I'm not sure of being able to
correct such a high error.

Another problem is related to a small oscillation axis, it is a swing of 0.001 / 0.002mm therefore very small. The problem
is solved by setting DEADBAND = 0.000125. It is a correct solution or is it better to lower the P gain (actually I have P=1000)?

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

More
30 Jun 2016 09:50 #76823 by andypugh

the ferror value
remains very high (> 10) at the beginning and during the high-speed movement, then to zero at the end of the movement.


Is that 10mm? That does seem high, even for rapid movements.

However, if the position doesn't over-shoot it might be something you can live with, as the machine will not engage the work during a rapid move.

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

More
30 Jun 2016 13:46 #76838 by PCW
Can you post your complete HAL and INI files?
This sounds like a setup error of some kind

Also a halscope plot of the commanded and actual position during a move would help diagnose the issue

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

More
30 Jun 2016 13:57 #76839 by backtime

Is that 10mm? That does seem high, even for rapid movements.


I think 10 is 10mm, the value is taken from halshow, and in any case I had to put FERROR = 10 in INI file
to avoid error message on jogging.

However, if the position doesn't over-shoot it might be something you can live with, as the machine will not engage the work during a rapid move.


Position doesn't over-shot, the big problem is to find the max speed for working movements which ensures a low enough
FERROR value, the 10mm ferror occurs at max speed (30mt/s) but the error is directly proportional to the speed so at 4/5mt/s
I get errors > 1/1.5 mm, at 1,5/2mt/s the error is > 0.5/1mm and so on.

These values all seem very high compared to default FERROR and MIN_FERROR values in INI file (0.01 and 0.001),
so I'm not sure what is the maximum safe speed for machining.

Still do not know what else to do, I will try to play with the PID values and then I will do some interpolation tests to verify the actual error.

Thank you for your time.

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

More
30 Jun 2016 14:02 #76840 by backtime

Can you post your complete HAL and INI files?
This sounds like a setup error of some kind

Also a halscope plot of the commanded and actual position during a move would help diagnose the issue


Hi PCW, thanks for your help.
I'm off to work until Monday, when I will be back I will send the configuration files and plots of halshow
I hope you see what I can not see :(

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

More
30 Jun 2016 14:30 #76843 by PCW
is the PID MAX_ERROR 0? (it should be)

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

Moderators: cncbasher
Time to create page: 0.109 seconds
Powered by Kunena Forum