!CheckDone

Moderators: TomKerekes, dynomotion

Post Reply
CNC_Machines
Posts: 60
Joined: Fri Apr 27, 2018 10:43 pm

!CheckDone

Post by CNC_Machines » Tue Aug 28, 2018 5:46 pm

Greetings,

I am writing a C program that has multiple moves of an axis. I noticed in the examples that whenever there is a movement it is followed by a while loop to wait until motion is complete. I am wondering what would happen if I ignored the loop? If I command an axis to position A, and before it reaches position what if I change the command to position B? Will this foul something up, or will it just update and move to B instead of A?

The reason I ask is I have this in a forever loop and I dont want to lock it up with the !CheckDone while loop.

Thanks,

Scott

User avatar
TomKerekes
Posts: 2677
Joined: Mon Dec 04, 2017 1:49 am

Re: !CheckDone

Post by TomKerekes » Tue Aug 28, 2018 6:16 pm

Hi Scott,

You can command a new Move/Jog while a previous Move/Jog is in progress. KFLOP will compute a blended motion toward the new command. However you may not command new Moves/Jogs continuously or KFLOP will be totally consumed with blending motions. Motions of at least 50ms should be allowed without changes at frequent intervals.

There are techniques of waiting for motions to finish within a loop while not blocking the loop. See this article.
Regards,

Tom Kerekes
Dynomotion, Inc.

Post Reply