Grasshopper

algorithmic modeling for Rhino

hi all,

 i am working on a gcode generator from lines for my 3-axis machine (file is attached), and it's output is like that:

...
G1 X9.69 Y10.39 Z120.00 F1000
G1 X9.89 Y10.44 Z120.00 F1000
G1 X9.67 Y10.00 Z120.00 F1000
G1 X9.85 Y10.12 Z120.00 F1000
G1 X10.14 Y10.51 Z120.00 F1000
G1 X10.50 Y10.86 Z120.00 F1000
G1 X10.81 Y11.19 Z120.00 F1000
M106 S0
G1 X8.05 Y11.97 Z120.00 F4000
M106 S255
G1 X7.71 Y11.61 Z120.00 F1000
G1 X7.37 Y11.24 Z120.00 F1000
G1 X6.97 Y10.98 Z120.00 F1000
G1 X6.49 Y10.82 Z120.00 F1000
G1 X6.33 Y10.83 Z120.00 F1000
G1 X6.72 Y11.14 Z120.00 F1000

...

but it's just an extra weight of data if it's not different than the upper line. so if z coordinate and feedrate doesn't change, better not to write them. but i dont know how to.

the thing in my mind to divide line in pieces like x coordinate, y coordinate, feedrate and make it check against upper line, if same, just use blank instead. anyone can help me on it or if any other way to get same thing?

thanks in adv

Views: 168

Attachments:

About

Translate

Search

Photos

  • Add Photos
  • View All

© 2026   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service