poszukuje się fontów liniowych - grawerowanie wychodzi szybciej niż ttfów
ciekawym programikiem do generowania gcodu napisów jest skrypt pod linuxcnc
Text Engraving Softwarehttp://wiki.linuxcnc.org/cgi-bin/wiki.pl?Simple_LinuxCNC_G-Code_Generators#Text_Engraving_Softwarefajny kod generuje ten skrypt:
( Code generated by engrave-11.py widget )
( by Lawrence Glaister VE7IT - 2008 )
( Engraving: "ALA" at 0.0 degrees)
( Fontfile: /usr/share/qcad/fonts/romanc.cxf )
#1000 = 0.1000 ( Safe Z )
#1001 = -0.0100 ( Engraving Depth Z )
#1002 = 1.0000 ( X Start )
#1003 = 2.0000 ( Y Start )
#1004 = 0.0400 ( X Scale )
#1005 = 0.0400 ( Y Scale )
#1006 = 0.0000 ( Angle )
(===================================================================)
(Subroutine to handle x,y rotation about 0,0)
(input x,y get scaled, rotated then offset )
( [#1 = 0 or 1 for a G0 or G1 type of move], [#2=x], [#3=y])
o9000 sub
#28 = [#2 * #1004] ( scaled x )
#29 = [#3 * #1005] ( scaled y )
#30 = [SQRT[#28 * #28 + #29 * #29 ]] ( dist from 0 to x,y )
#31 = [ATAN[#29]/[#28]] ( direction to x,y )
#32 = [#30 * cos[#31 + #1006]] ( rotated x )
#33 = [#30 * sin[#31 + #1006]] ( rotated y )
o9010 if [#1 LT 0.5]
G00 X[#32+#1002] Y[#33+#1003]
o9010 else
G01 X[#32+#1002] Y[#33+#1003]
o9010 endif
o9000 endsub
(===================================================================)
G17 G20 G90 G64 P0.003 M3 S3000 M7 F5
G0 Z#1000
(character 'A')
G0 Z#1000
o9000 call [0] [2.4828] [5.7931]
G1 Z#1001
o9000 call [1] [0.5517] [0.0000]
G0 Z#1000
o9000 call [0] [2.4828] [5.7931]
G1 Z#1001
o9000 call [1] [4.4138] [0.0000]
G0 Z#1000
o9000 call [0] [2.4828] [4.9655]
G1 Z#1001
o9000 call [1] [4.1379] [0.0000]
G0 Z#1000
o9000 call [0] [1.1034] [1.6552]
G1 Z#1001
o9000 call [1] [3.5862] [1.6552]
G0 Z#1000
o9000 call [0] [0.0000] [0.0000]
G1 Z#1001
o9000 call [1] [1.6552] [0.0000]
G0 Z#1000
o9000 call [0] [3.3103] [0.0000]
G1 Z#1001
o9000 call [1] [4.9655] [0.0000]
(character 'L')
G0 Z#1000
o9000 call [0] [7.7931] [5.7931]
G1 Z#1001
o9000 call [1] [7.7931] [0.0000]
G0 Z#1000
o9000 call [0] [8.0690] [5.7931]
G1 Z#1001
o9000 call [1] [8.0690] [0.0000]
G0 Z#1000
o9000 call [0] [6.9655] [5.7931]
G1 Z#1001
o9000 call [1] [8.8966] [5.7931]
G0 Z#1000
o9000 call [0] [6.9655] [0.0000]
G1 Z#1001
o9000 call [1] [11.1034] [0.0000]
o9000 call [1] [11.1034] [1.6552]
o9000 call [1] [10.8276] [0.0000]
(character 'A')
G0 Z#1000
o9000 call [0] [15.5862] [5.7931]
G1 Z#1001
o9000 call [1] [13.6552] [0.0000]
G0 Z#1000
o9000 call [0] [15.5862] [5.7931]
G1 Z#1001
o9000 call [1] [17.5172] [0.0000]
G0 Z#1000
o9000 call [0] [15.5862] [4.9655]
G1 Z#1001
o9000 call [1] [17.2414] [0.0000]
G0 Z#1000
o9000 call [0] [14.2069] [1.6552]
G1 Z#1001
o9000 call [1] [16.6897] [1.6552]
G0 Z#1000
o9000 call [0] [13.1034] [0.0000]
G1 Z#1001
o9000 call [1] [14.7586] [0.0000]
G0 Z#1000
o9000 call [0] [16.4138] [0.0000]
G1 Z#1001
o9000 call [1] [18.0690] [0.0000]
G0 Z#1000
M5 M9 M2
pokazany gcode dotyczy implementacji dostępnej w linuxcnc
i robi napis "ALA"