Compensating for delays between joints

12 Jun 2018 20:05 #112261 by mechatroptik rainer

in my machine, I combine stepper- and servodrives. After having done lots of tests, i conclude that the stepper joint is by some milliseconds earlier than then the servo joint. The delay seems to be constant, no matter what path or feed i'm going. I ruled out effects of acceleration or of PID parameters. I suspect the servodriver to have an input filter that causes the phenomenon.

I'd like to set a delay for the stepper joint to comensate for that. How can I do that? Are there some parameters to set a delay (I couldn't find any)? Can it be done in kinematics? Shall I write a special HAL component? - if so - is there some related HAL component I can build on?

Thank you in advance!

12 Jun 2018 21:46 #112263 by PCW
Not sure how portable it is but machinekit has a component for this:
13 Jun 2018 17:20 #112297 by andypugh

Looks like it ought to compile / install with halcompile.
15 Aug 2018 19:51 #116095 by mechatroptik rainer
Thank you for the answers.
I tried to implement the machinekit delayline and got the impression, that it would not work in the relatively slow servo thread.
I'm using mesa-cards, hostmot2 and chinese servocontrollers that are controlled by step/dir.

The deay I want to achieve is about 8.5 ms, my highest pulse frequency is about 200 kHz.

Do I think correctly about the problem with threadspeed?
Is there any cofiguration in Hostmot that could help?

Thank you.
15 Aug 2018 21:46 #116102 by PCW
I guess it depends on how accurate a delay you need.

With a 1 ms servo thread, you can get within +- 500 usec of any desired delay
or +-125 usec at a 4 KHz servo thread.
15 Aug 2018 21:50 #116103 by mechatroptik rainer
hm, the pulses are 2 ┬Ás long - isn't this a problem as delayline is sampling in range of milliseconds? So within one cycle of servothrad it can be hundreds of step pulses.
So maybe I misunderstood the concept. What kind of signals are passed to delayline?
15 Aug 2018 22:24 #116105 by PCW
The commanded position...
16 Aug 2018 22:04 #116186 by philipp
Hey there!
I'm working on the mill with Rainer.

delayline seems to be exactly what we are looking for.
Unfortunately, halcompile fails and we don't seem to get dependencies right.

delayline.c depends on
hal_ring.h depends on
ring.h, which seems to be part of machinekit libs and close to their rtapi.

Before starting to dig deeper - does anybody have an offhand hint on how to get it working?

Thank you!

Time to create page: 0.097 seconds
Powered by Kunena Forum