Re:DIgitizing a part with no probe
- prcdslnc13
- Offline
- Junior Member
Less
More
- Posts: 25
- Thank you received: 0
25 Apr 2011 15:48 #9310
by prcdslnc13
DIgitizing a part with no probe was created by prcdslnc13
I posted this on CNCzone a while back with no avail so ill try it here
Back when I used to program CNC routers for my job we had a router that we could lay a cardboard template down, drive the machine manually and place the axis where we wanted and hit a button and create a point. The software that drive the machine (windows based if I remember right,this was 7ish years ago and it was old then though) would output a dxf which we could open in autocad and create curves off the point cloud.
Im looking to something similar with my router and Emc. Im currently using ubuntu vs 8.04 and I think EMC 2.3. I dont currently have anything special set up in my config file, I dont even have my limit switches wired in yet Im using the probotix stepper drivers and breakout board for my electronics.
Im not at a point where I want to create a probe sequnce or even really make a probe, I would be happy with manually jogging the machine with a fine point bit and pushing a button when I get where I want to be. Really I would be perfectly happy with EMC creating a text file with the coordinates I need. So jog to a point, click a button, Coordinate output. Anyone have any ideas, I need to do this tonight, so simple is great
Back when I used to program CNC routers for my job we had a router that we could lay a cardboard template down, drive the machine manually and place the axis where we wanted and hit a button and create a point. The software that drive the machine (windows based if I remember right,this was 7ish years ago and it was old then though) would output a dxf which we could open in autocad and create curves off the point cloud.
Im looking to something similar with my router and Emc. Im currently using ubuntu vs 8.04 and I think EMC 2.3. I dont currently have anything special set up in my config file, I dont even have my limit switches wired in yet Im using the probotix stepper drivers and breakout board for my electronics.
Im not at a point where I want to create a probe sequnce or even really make a probe, I would be happy with manually jogging the machine with a fine point bit and pushing a button when I get where I want to be. Really I would be perfectly happy with EMC creating a text file with the coordinates I need. So jog to a point, click a button, Coordinate output. Anyone have any ideas, I need to do this tonight, so simple is great
Please Log in or Create an account to join the conversation.
- BigJohnT
- Offline
- Administrator
Less
More
- Posts: 7106
- Thank you received: 1177
25 Apr 2011 22:42 #9315
by BigJohnT
Replied by BigJohnT on topic Re:DIgitizing a part with no probe
Jog to your point copy the numbers from the DRO into your g-code program... simple, tonight.
John
John
Please Log in or Create an account to join the conversation.
- andypugh
- Away
- Moderator
Less
More
- Posts: 23314
- Thank you received: 4861
26 Apr 2011 10:49 - 26 Apr 2011 10:49 #9326
by andypugh
Replied by andypugh on topic Re:DIgitizing a part with no probe
One way might be to create a PyVCP button that calls an MDI_COMMAND calls a subroutine which logs the current XY
I combination of
linuxcnc.org/docs/html/gcode_main.html#sub:Probe-Logging
linuxcnc.org/docs/html/gui_halui.html#sub:MDI
linuxcnc.org/docs/html/hal_pyvcp.html
The docs say that the behaviour is to truncate the log file if it is already open. But I am not entirely sure if this is true, or even what it means.
Experimentation might be needed. You might need a separate button to open a new logging file.
You will probably need something like
(.ini file)
MDI_COMMAND o<logpoint> CALL.
Then in your PROGRAM_PREFIX directory (probably home/emc2/nc_files)
a file called logpoint.ngc containing
o<logpoint> sub
(logopen, logfile.txt)
G92 x0 y0 (store position)
g92.2
(log, #5211 #5212)
g92.1
o<logpoint> endsub
m2
The above work with any EM2 version. With the unrleased 2.5 version you could use this variation as current position is available as a parameter
o<logpoint> sub
(logopen, logfile.txt)
(log, #5420 #5421)
o<logpoint> endsub
m2
And in the even more unreleased 2.6 version:
o<logpoint> sub
(logopen, logfile.txt)
(log, #<_X> #<_Y>)
o<logpoint> endsub
m2
I combination of
linuxcnc.org/docs/html/gcode_main.html#sub:Probe-Logging
linuxcnc.org/docs/html/gui_halui.html#sub:MDI
linuxcnc.org/docs/html/hal_pyvcp.html
The docs say that the behaviour is to truncate the log file if it is already open. But I am not entirely sure if this is true, or even what it means.
Experimentation might be needed. You might need a separate button to open a new logging file.
You will probably need something like
(.ini file)
MDI_COMMAND o<logpoint> CALL.
Then in your PROGRAM_PREFIX directory (probably home/emc2/nc_files)
a file called logpoint.ngc containing
o<logpoint> sub
(logopen, logfile.txt)
G92 x0 y0 (store position)
g92.2
(log, #5211 #5212)
g92.1
o<logpoint> endsub
m2
The above work with any EM2 version. With the unrleased 2.5 version you could use this variation as current position is available as a parameter
o<logpoint> sub
(logopen, logfile.txt)
(log, #5420 #5421)
o<logpoint> endsub
m2
And in the even more unreleased 2.6 version:
o<logpoint> sub
(logopen, logfile.txt)
(log, #<_X> #<_Y>)
o<logpoint> endsub
m2
Last edit: 26 Apr 2011 10:49 by andypugh.
Please Log in or Create an account to join the conversation.
- prcdslnc13
- Offline
- Junior Member
Less
More
- Posts: 25
- Thank you received: 0
26 Apr 2011 14:24 #9336
by prcdslnc13
Replied by prcdslnc13 on topic Re:DIgitizing a part with no probe
THANK YOU!!
That is exactly the kind of info Im looking for. write now im jogging to a location, then writing down the coordinates by hand. Not exactly the best method. This could be useful for a ton of reasons. Ill post up when I make some progress.
That is exactly the kind of info Im looking for. write now im jogging to a location, then writing down the coordinates by hand. Not exactly the best method. This could be useful for a ton of reasons. Ill post up when I make some progress.
Please Log in or Create an account to join the conversation.
- Oops
- Offline
- New Member
Less
More
- Posts: 13
- Thank you received: 1
27 Dec 2024 15:51 #317483
by Oops
Replied by Oops on topic Re:DIgitizing a part with no probe
I am looking to use Axis 2.5.4 to digitize a paper plot or 2D template on a small gantry router.
Is there a simple to implement (my programming skills are weak) solution for writing current machine XY or XYZ position to a file? I am imaging a small pointed probe, aligning it visually, and a keystroke or GUI button to log data.
Thanks!
Is there a simple to implement (my programming skills are weak) solution for writing current machine XY or XYZ position to a file? I am imaging a small pointed probe, aligning it visually, and a keystroke or GUI button to log data.
Thanks!
Please Log in or Create an account to join the conversation.
- Aciera
- Away
- Administrator
Less
More
- Posts: 3969
- Thank you received: 1717
27 Dec 2024 23:04 - 27 Dec 2024 23:08 #317515
by Aciera
Replied by Aciera on topic Re:DIgitizing a part with no probe
2.5 is quite ancient. Maybe have a look at
github.com/jethornton/position-logger
Or simply the subroutine posted above:
github.com/jethornton/position-logger
Or simply the subroutine posted above:
o<logpoint> sub
(logopen, logfile.txt)
(log, #5420 #5421 #5422)
o<logpoint> endsub
m2
Last edit: 27 Dec 2024 23:08 by Aciera.
The following user(s) said Thank You: Oops
Please Log in or Create an account to join the conversation.
- Oops
- Offline
- New Member
Less
More
- Posts: 13
- Thank you received: 1
28 Dec 2024 00:15 - 28 Dec 2024 00:26 #317523
by Oops
Replied by Oops on topic Re:DIgitizing a part with no probe
I added this to my g540.ini file in the HALUI section
MDI_COMMAND o<logpoint> CALL.
Then in in my PROGRAM_PREFIX directory (home//linuxcnc/nc_files)
I wrote logpoint.ngc containing:
o<logpoint> sub
(logopen, logfile.txt)
(log, #5420 #5421 #5422)
o<logpoint> endsub
m2
and created an empty file logfile.txt in the nc_files folder
What do I do to actually run the command? I get an 'unknown word' error typing logpoint into the MDI window. If I run the logpoint.ngc file from the main page nothing seems to happen.
I trried the links in Andy's post above and they went to 404 error pages.
Thanks. Like I said, I am no whiz at this stuff...
MDI_COMMAND o<logpoint> CALL.
Then in in my PROGRAM_PREFIX directory (home//linuxcnc/nc_files)
I wrote logpoint.ngc containing:
o<logpoint> sub
(logopen, logfile.txt)
(log, #5420 #5421 #5422)
o<logpoint> endsub
m2
and created an empty file logfile.txt in the nc_files folder
What do I do to actually run the command? I get an 'unknown word' error typing logpoint into the MDI window. If I run the logpoint.ngc file from the main page nothing seems to happen.
I trried the links in Andy's post above and they went to 404 error pages.
Thanks. Like I said, I am no whiz at this stuff...
Last edit: 28 Dec 2024 00:26 by Oops.
Please Log in or Create an account to join the conversation.
Time to create page: 0.059 seconds