Post Processor Help for Dynatorch Gantry

Post general information and questions relating to Cut2D in this Forum.
Post Reply
RawIndustrialDesign
Posts: 4
Joined: Fri Sep 26, 2014 1:18 pm
Model of CNC Machine: Dynatorch

Post Processor Help for Dynatorch Gantry

Post by RawIndustrialDesign »

Hello all,

I am new to Vectric Cut2D and am approaching the general community for help resolving some small issues with a custom post processor based of the GCode_arc_inch.pp . I currently operate a Dynatorch Super-B Plasma system and have recently adapted the gantry to accommodate a router spindle for 2.5D milling. The inherent problem is that unlike a traditional 3-Axis gantry, the Z-Axis on the Dyantorch is hardwired for a voltage feedback at the plasma torch tip to control torch cutting height. So where as a typical line of G-code would read XYZ, I must introduce a separate command for driving the Z-axis. Dynatorch has two separate commands for accomplishing this, G22 for Z-Axis Feed & G24 for Z-Axis Rapid movements.

My intention is to be able upon starting a program to rapid up to Z Home position (G24[ZH]) at 1.000" at X0.000Y0.000, move to plunge XY position, then rapid down (G24[Z]) to the SafeZ height of .250" above stock surface, then plunge (G22[Z]) -.125" into the material, before beginning the cutting path G1, then perhaps a second plunge depth if required (G22[Z]) -.250"


For Example: Stock: .500"ThkX3"SQ, Project centered on stock: 2"SQ Profile w/ 1"Dia Circular Contour Cut .250" Deep
Endmill: .250"Dia Endmill 50% Step Over, .125"Pass Depth Z Feed 10 IPM XY Feed 30 IPM.
Z-Home 1.00" Safe Z Clearance .250" above Stock.

M08 //Dynatorch Specific
G54 //Dyantorch Specific
G24Z1.000 //Rapid to ZHome//
G0X0.0000Y0.0000 //Rapid to XYHome//
G0X1.5000Y1.8750 //Rapid to XY Start Position//
G24Z0.2500 //Rapid down to SafeZ//
G22Z-0.1250F10.0 //Plunge -.125" to first depth//
G1X1.4951Y1.8750F30.0 //Begin XY Feed//

........

G22Z-0.2500F10.0 //Plunge -.250" to second depth//
G1X1.4951Y1.8750F30.0 //Begin XY Feed//
........

G24Z0.2500 //Retract to SafeZ//
G24Z1.000 //Retract to ZHome//
G0X0.0000Y0.0000 //Return to XY Home//
M09 //Dynatorch Specific
M30


The problem is that when I used the post processor I've written based off the GCode_arc_inch.pp entitled Dynatorch_GCode_Arc_Inch attached below, I see that after each linear movement, the processor generates a superfluous G22& G1 which creates a momentary pause.

I do not understand why the additional lines of G22 and G1 appear after each XY linear motion, as if the post is searching for the next Z-Axis motion. But from the below, I do not understand how this can occur.

+---------------------------------------------------
+ Commands output for the first feed rate move
+---------------------------------------------------

begin FIRST_FEED_MOVE

"G22[Z][F]"
"G1[X][Y][F]"


+---------------------------------------------------
+ Commands output for feed rate moves
+---------------------------------------------------

begin FEED_MOVE

"[X][Y]"


I have attached the processor. Please help me to eliminate these unnecessary lines of code.

Thank you,
Chris
Attachments
Dynatorch_GCode_Arc_Inch.pp
(3.81 KiB) Downloaded 314 times

RawIndustrialDesign
Posts: 4
Joined: Fri Sep 26, 2014 1:18 pm
Model of CNC Machine: Dynatorch

Re: Post Processor Help for Dynatorch Gantry

Post by RawIndustrialDesign »

I am so close to the desired post processor, and I could really use some help getting one line of code to work. I've attached the post I wrote, along with the code it generates "Wrong" and the code I modified manually entitled "Goal" You'll see that all I'm after is a G24[Z][F] to rapid retract Z-Axis for tabs. If I actually put G24[Z][F] in the Feed_Move section the gantry jerks hard!. Let me know what you think. I've given up on trying to remove all the unnecessary G22 commands.

The only change I'm seeking is that the Z-.500 which indicates the retract for tabs, becomes G24Z-.500

So when I modify:

+---------------------------------------------------
+ Commands output for feed rate moves
+---------------------------------------------------

begin FEED_MOVE

"[X][Y]"
"[Z][F]"

To:

+---------------------------------------------------
+ Commands output for feed rate moves
+---------------------------------------------------

begin FEED_MOVE

"[X][Y]"
"G24[Z][F]"

is when I experience the jerking motion, might there be just a better location for the G24[Z][F] command than in the Feed_Move section? Should the retract really be part of the Feed_Move anyways? What about even writing a separate line that inserts a G24 in front whenever the post detects an isolated Z value? Otherwise I am even considering importing the G-Code through C++ to detect and revise the post as I need. Ultimately if I break the contours where I desire a tab to be or manually add G24 where I need like I've been doing, it will work. But on a more complex jobs this will be extremely laborious.

Does anyone have any C++ experience in order to accomplish this:

Compare the two text files Wrong vs Goal. I am hoping to write a C++ file that I can import the g-code text, and it will remove any instances of a empty "G1" "G22" & "G24" when they are not followed immediately by any other text . I also need the program to insert a G24 directly before any stand alone Z command such as Z-.500

For example:

G22Z-1.0000F10.0
G1
G22F40.0
G1X1.5000
G2X1.6250Y1.5000I0.0000J-0.1250
G22
G1Y1.2359

Z-0.5000
Y0.7359

G22Z-1.0000F10.0
G1
G22F40.0
G1Y0.5000
G2X1.5000Y0.3750I-0.1250J0.0000
G22
G1X1.2472

Should Read:

G22Z-1.0000F10.0
G22F40.0
G1X1.5000
G2X1.6250Y1.5000I0.0000J-0.1250
G1Y1.2359

G24Z-0.5000
Y0.7359

G22Z-1.0000F10.0
G22F40.0
G1Y0.5000
G2X1.5000Y0.3750I-0.1250J0.0000
G1X1.2472

Thank you,
Chris
Attachments
Dynatorch_GCode_Arc_Inch_Test.pp
(3.88 KiB) Downloaded 296 times
Sample.crv
(28 KiB) Downloaded 224 times
Wrong.txt
(920 Bytes) Downloaded 293 times
Goal.txt
(932 Bytes) Downloaded 281 times

RawIndustrialDesign
Posts: 4
Joined: Fri Sep 26, 2014 1:18 pm
Model of CNC Machine: Dynatorch

Re: Post Processor Help for Dynatorch Gantry

Post by RawIndustrialDesign »

Getting closer here guys . . .

I realized how to remove all of the extraneous lines of G1 and G22, which was to replace the G22[Z] in the Feed_Move with:

+---------------------------------------------------
+ Commands output for rapid moves
+---------------------------------------------------

begin RAPID_MOVE

"G0[X][Y]"
"G24[Z]"

+---------------------------------------------------
+ Commands output for Plunge Moves
+---------------------------------------------------
begin PLUNGE_MOVE

"G22[Z][F]"

+---------------------------------------------------
+ Commands output for the first feed rate move
+---------------------------------------------------

begin FIRST_FEED_MOVE

"G1[X][Y][F]"

I am still having an issue getting the G24[Z] retract, and perhaps I am just not using it in the correct location:

+---------------------------------------------------
+ Commands output for the first feed rate move
+---------------------------------------------------

begin FIRST_FEED_MOVE

"G1[X][Y][F]"

+---------------------------------------------------
+ Commands output for Retract Moves
+---------------------------------------------------
begin RETRACT_MOVE

"G24[Z]"

I've attached the latest Dynatorch Post Processor, you can simulate with the original Sample.crv file to obtain the attached G-Code Profile 4.tap I am using the Shopsabre_Plasma_Arc_MM.pp as a reference.
Attachments
Dynatorch_GCode_Arc_Inch_Getting Closer.pp
(4.21 KiB) Downloaded 284 times
Profile 4.txt
(768 Bytes) Downloaded 288 times

User avatar
martin54
Vectric Archimage
Posts: 7354
Joined: Fri Nov 09, 2012 2:12 pm
Model of CNC Machine: Gerber 48, Triac PC, Isel fixed gantry
Location: Kirkcaldy, Scotland

Re: Post Processor Help for Dynatorch Gantry

Post by martin54 »

Have you tried speaking to vectric support about this? They would probably be able to help you sort this & get it working how you want. Worth sending an email to them to find out.

RawIndustrialDesign
Posts: 4
Joined: Fri Sep 26, 2014 1:18 pm
Model of CNC Machine: Dynatorch

Re: Post Processor Help for Dynatorch Gantry

Post by RawIndustrialDesign »

Contacting support was the first step I made. Though responsive, they were ultimately unable to provide any assistance. Anyways attached is the final version of the Dynatorch Post Processor. It will perform exactly as desired except for one catch, on the last pass that generates tabs on the part, the Z axis input for the retract motion lacks a "G24" command. It is on a separate line and easy to locate near the end of the post, so "G24" can be written in manually. If anyone has any specific questions regarding adapting a Dynatorch Plasma System to a CNC router, use this thread or message me.

Regards,

Chris
Attachments
Dynatorch_GCode_Arc_Inch.pp
(4.01 KiB) Downloaded 304 times

Post Reply