Hello Guest it is October 15, 2019, 03:39:06 PM

Author Topic: g code from touch probe?  (Read 14076 times)

0 Members and 1 Guest are viewing this topic.

g code from touch probe?
« on: November 30, 2009, 05:04:52 PM »
It was suggested that I pose this question here on the video probing forum even though I'm using a touch probe..

Thanks!

I'm looking for a way to edit the code generated by the digitizing wizard (not plug-in) to a more usable format.  The file Mach generates is missing the x, y and z characters and simply separates the coordinates with a comma.

I could generate a point cloud in my cad program if the code was simply edited to include the X, Y and Z letters in each line..

Here's an example

Here's what I have to start with from Mach

-6.032136,1.419120,0.835333
-5.907102,1.419120,0.822000
-5.782069,1.419120,0.803333
-5.657035,1.419120,0.776000


This is what it needs to end up as so my cad/cam can read it.

X-6.032136,Y1.419120,Z0.835333
etc..

Any suggestions?
Re: g code from touch probe?
« Reply #1 on: December 06, 2009, 09:39:08 AM »
You could use a word processor.

Replace all the "-" with "X-"

Replace all the ",1" with "Y1"

Replace all the ",0" with "Z0"

Of course this only works if the first number for Y is different than the first for Z.

Ron

Offline spunk

*
  •  56 56
    • View Profile
Re: g code from touch probe?
« Reply #2 on: December 07, 2009, 06:25:22 AM »
if you're any good with Excell you could write a macro to do this automatically... splitting it up after every comma...

Offline Tweakie.CNC

*
  • *
  •  7,947 7,947
  • Super Kitty
    • View Profile
    • Tweakie.CNC
Re: g code from touch probe?
« Reply #3 on: December 14, 2009, 11:48:55 AM »
Al Lenz has written a brilliant little VB program to do just this. It is called XYZ Converter.exe and can be downloaded from this page.

http://www.machsupport.com/forum/index.php/topic,13301.msg87229.html#msg87229

Tweakie.
Success consists of going from failure to failure without loss of enthusiasm.  Winston Churchill.
Re: g code from touch probe?
« Reply #4 on: January 03, 2010, 07:12:37 PM »
I can write a simple C program do do that, but how do you get if from a triplet to a usable mesh?

Update: I have written a Windows CPP app for this. Now what?

Update: nevermind, found MachCloud
« Last Edit: January 03, 2010, 11:04:22 PM by JayC »
Re: g code from touch probe?
« Reply #5 on: June 25, 2010, 12:13:36 PM »
I am not in front of my machine right now, but I think in one of the preferences or settings you can turn on/off having the coordinate letter or not.

Rick
Re: g code from touch probe?
« Reply #6 on: June 25, 2010, 01:10:49 PM »
Rick is right......if this is what you need.
Ports and Pins / Mill Options