Hello Guest it is April 18, 2024, 01:15:13 PM

Author Topic: code - while ismoving  (Read 2123 times)

0 Members and 1 Guest are viewing this topic.

code - while ismoving
« on: December 08, 2018, 02:35:12 AM »
Sorry for asking this, but the forums search only returns an error each time I search.

I have a script running with multiple code statements following each other, like (just a sample code)

code "G1 X200"
code "G1 Y300"

now it appears, that sometimes the milling path behaves unexpected and is not following the GCode, and I have no clue why.
I am assuming that this might happen because there is no while...ismoving loop between the commands.
The strange part is that in most cases everything works fine even with very long machine movements like 3000mm (5 seconds move)

So, my question would be, how MACH3 handles multiple "code" statements following each other. Means: what happens if I would fire eg 1000 "code" statements from a script. Will MACH3 handle the correct execution ? Do I need to take care about buffer size, or when do I need to place a while ismoving loop inbetween code statements with no other script statement between them ?

Offline Tweakie.CNC

*
  • *
  •  9,198 9,198
  • Super Kitty
    • View Profile
Re: code - while ismoving
« Reply #1 on: December 08, 2018, 02:46:57 AM »
Quote
do I need to place a while ismoving loop in between code statements with no other script statement between them ?

Yes.

From my experience and to be on the safe side the;

While IsMoving()
Wend

statements should follow every Code statement.

Tweakie.
PEACE