Hello Guest it is September 16, 2019, 07:07:07 AM

Author Topic: how to reduce the code  (Read 1342 times)

0 Members and 1 Guest are viewing this topic.

how to reduce the code
« on: September 28, 2015, 10:53:37 AM »
Hello, there's a piece of programme developed  in the following program Visuall Mill.
(Work Zero)
M6 T4
M03 S12000 Z2
X14.6644 Z-0.0033 A152.683 F350.
X14.7510 Z-0.0067 A149.331
X14.8376 Z-0.0103 A145.982
X14.9243 Z-0.0141 A142.634
X15.0109 Z-0.0180 A139.286
X15.0975 Z-0.0221 A135.936
X15.1842 Z-0.0261 A132.582
X15.2708 Z-0.0301 A129.226
X15.3575 Z-0.0339 A125.866
X15.4441 Z-0.0376 A122.505
X15.5308 Z-0.0412 A119.143
X15.6174 Z-0.0446 A115.781
X15.7040 Z-0.0480 A112.419
X15.7907 Z-0.0513 A109.060
X15.8773 Z-0.0547 A105.702
X15.9640 Z-0.0582 A102.346
Z2.0004 A102.346 F624.
M5 M9
M30
The program will be launched by Mach3.
In this program every line will be in progress in series from (X14.6644 Z-0.0033 A152.683 F350.) to (X15.9640 Z-0.0582 A102.346) … the question is if it's possibleto shorten the number of lines if the original coordinates and the end coordinates are known. For example with the help of interpolation if it's possible in Mach3. If it's not what options should be changed in Visual Mill?
« Last Edit: September 28, 2015, 11:03:26 AM by dimxvin »
Re: how to reduce the code
« Reply #1 on: September 28, 2015, 02:09:07 PM »
If it's a straight line the code could be more concise, but is it?
You don't say

Offline ger21

*
  • *
  •  6,288 6,288
    • View Profile
    • The CNC Woodworker
Re: how to reduce the code
« Reply #2 on: September 28, 2015, 02:32:44 PM »
Run this code and see if the results are the same.

(Work Zero)
M6 T4
M03 S12000 Z2
X14.6644 Z-0.0033 A152.683 F350.
X15.9640 Z-0.0582 A102.346
Z2.0004 A102.346 F624.
M5 M9
M30
Gerry

2010 Screenset
http://www.thecncwoodworker.com/2010.html

JointCAM Dovetail and Box Joint software
http://www.g-forcecnc.com/jointcam.html
Re: how to reduce the code
« Reply #3 on: September 28, 2015, 06:00:13 PM »
I gave you only a piece of code. The programme itself has a large data size. If I follow your instructions, it will take me too long to edit it and correcting mistakes after that.. Is it possible to customize mach3 that the controller itself run the program with line skipping? And if it's possible what attributes should be run to lounch the generation of post processing in visual mill?
Re: how to reduce the code
« Reply #4 on: September 28, 2015, 06:04:13 PM »
it is not a straight line but a spiral, length 16 mm ..

Offline ger21

*
  • *
  •  6,288 6,288
    • View Profile
    • The CNC Woodworker
Re: how to reduce the code
« Reply #5 on: September 28, 2015, 06:09:26 PM »
Nothing you can do in Mach3 to skip code.
You need to ask Mecsoft if there's any way to get fewer lines of code from Visual Mill.
Gerry

2010 Screenset
http://www.thecncwoodworker.com/2010.html

JointCAM Dovetail and Box Joint software
http://www.g-forcecnc.com/jointcam.html
Re: how to reduce the code
« Reply #6 on: September 28, 2015, 06:11:34 PM »
Thank you good man)