Skip to content

Instantly share code, notes, and snippets.

@wolfmanjm
Created March 20, 2019 11:23
Show Gist options
  • Save wolfmanjm/b59984f0ad79f77fc7947723e864eb25 to your computer and use it in GitHub Desktop.
Save wolfmanjm/b59984f0ad79f77fc7947723e864eb25 to your computer and use it in GitHub Desktop.
example turtle cnc script
job= CNC.build 'plate' do
@safe_z= 2
@tool_dia= (1.0/8)*25.4 # 1/8" end mill
@doc= 0.2
@feedrate= 1000
@laser= false
# size of plate
w = 100.0
l = 25.0
m3 s:10000
g4 p:2
# center of plate
moveto x: w/2, y: l/2
# two 5mm holes 20mm apart either side of center
moveby x: -10
hole diameter: 5, depth: 4, feedrate: 800
moveby x: 20
hole diameter: 5, depth: 4, feedrate: 800
# cutout plate
moveto x: 0, y: 0
rectangle width: w, length: l, depth: 0.9
m5
# m123 1, 2, 3
# m321 a:1, b:2, c:3
end
#job.export('t.nc')
job.export
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment