Sidebar

Home



Knowledge Base


Guides & Tutorials

Projects

Samples

  G-Code
   Square
   Arcs
   Mickey
   Arrow
   Bear
   Ball In Cage

  Dialogs
   Square
   Rounded Square
   Guess The Number

  O-Words
   Polygon

  Subprocedures
   Lissajous

   Lissajous (sub..endsub..call)
   Lissajous (call..sub..endsub)

   Lissajous (exec..O..M99)

   Lissajous (G65)
   Lissajous (G65 with GOTO)

   Palindrome
   PrimeFactors
   Fibonacci

  Splines
   Butterfly

  G06
   arrchr

  Dynamic
   Clock
   DateTime

  Python
   Lissajous Python

  3D Models
   3D CNC
   3dModel_TableA.txt

  Notepad++ Plugin
   Examples


kb:samples:rounded_square

Rounded Square

(name,Rounded Square)
 
(dlgname,Rounded Square)
(dlg,Size, dec=2, def=30, min=0, max=1000, store, param=size)
(dlg,Radius, dec=2, def=5, min=0, max=250, store, param=rad)
(dlg,Speed, dec=1, def=1000, min=1, max=50000, store, param=speed)
(dlg,Loop, dec=0, def=1, min=1, max=100, store, param=loop)
(dlgshow)
 
;Uniform circular motion
 
;The acceleration due to change in the direction is:
;a = v^2 / r
 
;Radius that machine can make without lowering speed is:
;r = v^2 / a
 
;Note that both speed and acceleration must use same units.
;Normally speeds are set in units/minute and need to be converted to units/second.
 
(clear)
#<s> = [#<speed> / 60]
#<a> = [#<s>*#<s> / #<rad>]
(print,The acceleration due to change in the direction at)
(print,  speed #<speed,1>#<_unitsname>/min and radius #<rad,2>#<_unitsname> is #<a,3>#<_unitsname>/s^2)
 
#<r> = [#<s>*#<s> / #<_motion_maxacc>]
(print,Radius that machine can make without lowering speed at)
(print,  speed #<speed,1>#<_unitsname>/min and acceleration #<_motion_maxacc,3>#<_unitsname>/s^2 is #<r,3>#<_unitsname>)
 
#<v> = [SQRT[#<_motion_maxacc> * #<rad>] * 60]
(print,Speed that machine can run radius #<rad,3>#<_unitsname> without lowering speed at)
(print,  acceleration #<_motion_maxacc,3>#<_unitsname>/s^2 is #<v,3>#<_unitsname>/min)
 
 
F#<speed>
G00 X[#<rad>] Y0
 
o<loop> repeat[#<loop>]
  G01 X[#<size>] Y0
  G03 X[#<size>+#<rad>] Y[#<rad>] J[#<rad>]
  G01 Y[#<size>]
  G03 X[#<size>] Y[#<size>+#<rad>] I-[#<rad>]
  G01 X[#<rad>]
  G03 X0 Y[#<size>] J-[#<rad>]
  G01 Y[#<rad>]
  G03 X[#<rad>] Y0 I[#<rad>]
o<loop> endrepeat
 
M02
kb/samples/rounded_square.txt · Last modified: 2024/04/03 09:14 by 127.0.0.1

Page Tools