Hello Guest it is March 28, 2024, 05:47:26 AM

Author Topic: Using M7 without interrupting G01  (Read 5381 times)

0 Members and 1 Guest are viewing this topic.

Using M7 without interrupting G01
« on: November 15, 2011, 06:52:39 PM »
I would like to use the M7 and M9 commands without pausing or stopping the g01 travel. What is the correct code order to achieve this?

Thanks,
-jim

Offline BR549

*
  •  6,965 6,965
    • View Profile
Re: Using M7 without interrupting G01
« Reply #1 on: November 15, 2011, 06:56:31 PM »
In Gcode just add the M7/9 where ever you want it to occur.

G01 x10 y10 M7
code
code
code
G01 X1 Y1 M9

(;-) TP
Re: Using M7 without interrupting G01
« Reply #2 on: November 15, 2011, 07:31:45 PM »
I guess I was not entirely clear. I need to have the M7 and M9 commands happen WHILE the cutter moves along the X or y axis. It must start and stop while the mill head advances without pausing. Specifically, I need the M7 command to happen at the beginning of an G01 command and then the M9 command to happen before the end of the g01 run, IE without stopping the movement of the mill head along the X or Y axis.

I am not using the M7 and M9 for cutting fluid, -it is for a different application. When I add the M7 or M9 commands anywhere in the code, the mill head stops momentarily while the commands are carried out. Is there a way to avoid this?
thanks,
-jim
Re: Using M7 without interrupting G01
« Reply #3 on: November 15, 2011, 07:45:56 PM »
G-code is executed one block at a time, and the currently executing block must complete before the next one will be executed.  So, what you're asking for can't be done.

Regards,
Ray L.
Regards,
Ray L.

Offline BR549

*
  •  6,965 6,965
    • View Profile
Re: Using M7 without interrupting G01
« Reply #4 on: November 15, 2011, 07:54:22 PM »
Is this a large application or something simple with a few lines of code. IF it is a simple application it may be possible to monitor Key postion points with a macropump watching the dros and have it cycle the M9 off mid line .

(;-) TP
Re: Using M7 without interrupting G01
« Reply #5 on: November 15, 2011, 08:37:43 PM »
It is a simple bit of code. Basically it does a rectangle shape repeatedly. The m7-m9 commands occur at the beginning few centimeters of each corner of the rectangular path. I am not familiar with the technique you mentioned so I'll need instructions aimed at a relative neophyte.
thanks,
-jim

Offline BR549

*
  •  6,965 6,965
    • View Profile
Re: Using M7 without interrupting G01
« Reply #6 on: November 15, 2011, 09:27:12 PM »
OK Just tested a simple macropump BUT it is too slow. I tested a Brain and it will work.

You will have to learn how to program a brain and then develope a strategy to toggle off the M9 when it crosses the trigger points in your Gcode.

a simple brain would be like this     (oemDro(0) )-------->  If >5.00 ------------------> Dobutton(113).

It monitors the DRO and when the value crosses the 5.00 threshold it then toggles OFF the Coolant(M9)

You will need to develope a ladder structure to comply with all the way points BUT still allow the program to function.


Can you post an example of the needed Gcode that drives the function. It may be possible to rearrange the gcode to get it to do what you need rather than the Brains approach.


Hope that helps, (;-) TP

Re: Using M7 without interrupting G01
« Reply #7 on: November 15, 2011, 09:54:08 PM »
Here is the basic block of the code:

f500
m7 g01 x9
m9 g01 x44.18
m7 g01 y-9
m9 g01 y-30
m7 g01 x35.18
m9 g01 x0
m7 g01 y-21
m9 g01 y0

This is repeated several times. If you can re-create this using your recommended technique so that there is no pause during the M7-M9 cycle, it would be great. Thanks for accepting this unusual request!

-jim

Offline BR549

*
  •  6,965 6,965
    • View Profile
Re: Using M7 without interrupting G01
« Reply #8 on: November 15, 2011, 11:37:38 PM »
Here is the test Gcode and the BRAIN. Load up the brain and run the Gcode. It move until it gets to the target point then shuts off the mist. At the next corner the Mist turns on with the Gcode and then when it gets to the target point it shuts off the mist, etc,etc

f100
m7 g01 x44.18
m7 g01 y-30
m7 g01 x0
m7 g01 y0
m30

Hope that helps, (;-)TP

Offline BR549

*
  •  6,965 6,965
    • View Profile
Re: Using M7 without interrupting G01
« Reply #9 on: November 16, 2011, 12:09:53 AM »
If you want to try the macropump version this is the code to add to the macropump

If GetDro(1)=0 And GetDro(0)>9.000 Then
DoOemButton(114)
Else
If GetDro(0)= 44.18 And GetDro(1)> -9.000 Then
DoOemButton(114)
Else
If GetDro(1)=-30.000 And GetDro(0)< 35.18 Then
DoOemButton(114)
Else
If Getdro(0)=0 And Getdro(1)>-21.00 Then
DoOemButton(114)
End If

End

(;-) TP