exec.Code("G1 X10");
while (exec.IsMoving());
exec.Setvar(exec.Getfielddouble(226),500); (Set #500 to the value of the Xpos DRO)
exec.Code("G1 X10");
double newY = some terrible and long calculation, maybe with some data read from a file;
while (exec.IsMoving());
exec.Code("G1 Y" + newY.ToString());
while (exec.IsMoving());
Vmax549 wrote:Lets take Ian's example. WHY would I want teh message to display BEFORE the motion line actually finished?
exec.Code("G31 Z-1.0000 F25"); // Send command to the motion controller
while(exec.IsMoving()); // Wait for the controller to finish
if (exec.Ismacrostopped()) // If there was a STOP do something
{
exec.AddStatusmessage("Probe stopped!");
return false;
}
// code continues
Line1 exec.Code("G1 X10");
Line2 double newY = some terrible and long calculation, maybe with some data read from a file;
Line3 while (exec.IsMoving());
Line4 exec.Code("G1 Y" + newY.ToString());
Line5 while (exec.IsMoving());
Return to Ask a question from support here
Users browsing this forum: No registered users and 17 guests