svenhb / GRBL-Plotter

A GCode sender (not only for lasers or plotters) for up to two GRBL controller. SVG, DXF, HPGL import. 6 axis DRO.
https://grbl-plotter.de/
GNU General Public License v3.0
696 stars 176 forks source link

Inport from DXF #407

Closed voleoo closed 5 months ago

voleoo commented 5 months ago

I have issue with draw after importing from DXF on the screen it looks good but g-code is wrong. G-code path not includes radiuses. Also if i change point to start drawing is changed to broken (looks without radius)

photo_2024-06-18_19-18-05

DXF

0
SECTION
2
HEADER
9
$INSUNITS
70
4
9
$ACADVER
1
AC1014
9
$HANDSEED
5
FFFF
0
ENDSEC
0
SECTION
2
TABLES
0
TABLE
2
VPORT
5
8
100
AcDbSymbolTable
0
ENDTAB
0
TABLE
2
LTYPE
5
5
100
AcDbSymbolTable
0
LTYPE
5
14
100
AcDbSymbolTableRecord
100
AcDbLinetypeTableRecord
2
BYBLOCK
70
0
0
LTYPE
5
15
100
AcDbSymbolTableRecord
100
AcDbLinetypeTableRecord
2
BYLAYER
70
0
0
ENDTAB
0
TABLE
2
LAYER
5
2
100
AcDbSymbolTable
70
2
0
LAYER
5
50
100
AcDbSymbolTableRecord
100
AcDbLayerTableRecord
2
0
70
0
6
CONTINUOUS
0
ENDTAB
0
TABLE
2
STYLE
5
3
100
AcDbSymbolTable
70
1
0
STYLE
5
11
100
AcDbSymbolTableRecord
100
AcDbTextStyleTableRecord
2
STANDARD
70
0
0
ENDTAB
0
TABLE
2
VIEW
5
6
100
AcDbSymbolTable
70
0
0
ENDTAB
0
TABLE
2
UCS
5
7
100
AcDbSymbolTable
70
0
0
ENDTAB
0
TABLE
2
APPID
5
9
100
AcDbSymbolTable
70
2
0
APPID
5
12
100
AcDbSymbolTableRecord
100
AcDbRegAppTableRecord
2
ACAD
70
0
0
ENDTAB
0
TABLE
2
DIMSTYLE
5
A
100
AcDbSymbolTable
70
1
0
ENDTAB
0
TABLE
2
BLOCK_RECORD
5
1
100
AcDbSymbolTable
70
1
0
BLOCK_RECORD
5
1F
100
AcDbSymbolTableRecord
100
AcDbBlockTableRecord
2
*MODEL_SPACE
0
BLOCK_RECORD
5
1B
100
AcDbSymbolTableRecord
100
AcDbBlockTableRecord
2
*PAPER_SPACE
0
ENDTAB
0
ENDSEC
0
SECTION
2
BLOCKS
0
BLOCK
5
20
100
AcDbEntity
100
AcDbBlockBegin
2
*MODEL_SPACE
0
ENDBLK
5
21
100
AcDbEntity
100
AcDbBlockEnd
0
BLOCK
5
1C
100
AcDbEntity
100
AcDbBlockBegin
2
*PAPER_SPACE
0
ENDBLK
5
1D
100
AcDbEntity
100
AcDbBlockEnd
0
ENDSEC
0
SECTION
2
ENTITIES
0
LWPOLYLINE
5
100
100
AcDbEntity
8
0
100
AcDbPolyline
90
8
70
1
43
0.0
10
1833.5539360848202
20
3445.1441088344554
42
0.41421356237309509
10
1948.5539360848197
20
3560.1441088344545
10
1948.553936084819
20
3770.1441088344541
42
0.41421356237309509
10
1833.5539360848197
20
3885.1441088344536
10
1773.5539360848197
20
3885.1441088344541
42
0.41421356237309359
10
1658.5539360848206
20
3770.1441088344541
10
1658.5539360848202
20
3560.1441088344545
42
0.41421356237309509
10
1773.5539360848202
20
3445.1441088344545
0
LINE
5
101
100
AcDbEntity
8
0
100
AcDbLine
10
1803.5539360848202
20
3515.1441088344541
30
0
11
1803.5539360848202
21
3485.1441088344541
31
0
0
LINE
5
102
100
AcDbEntity
8
0
100
AcDbLine
10
1818.5539360848202
20
3500.1441088344541
30
0
11
1788.5539360848202
21
3500.1441088344541
31
0
0
LINE
5
103
100
AcDbEntity
8
0
100
AcDbLine
10
1803.5539360848197
20
3845.1441088344541
30
0
11
1803.5539360848197
21
3815.1441088344541
31
0
0
LINE
5
104
100
AcDbEntity
8
0
100
AcDbLine
10
1818.5539360848197
20
3830.1441088344541
30
0
11
1788.5539360848197
21
3830.1441088344541
31
0
0
LINE
5
105
100
AcDbEntity
8
0
100
AcDbLine
10
2103.5539360848197
20
3845.1441088344541
30
0
11
2103.5539360848197
21
3815.1441088344541
31
0
0
LWPOLYLINE
5
106
100
AcDbEntity
8
0
100
AcDbPolyline
90
8
70
1
43
0.0
10
2073.5539360848197
20
3885.1441088344541
10
2133.5539360848197
20
3885.1441088344536
42
-0.41421356237309509
10
2248.5539360848188
20
3770.1441088344541
10
2248.5539360848197
20
3560.1441088344545
42
-0.41421356237309509
10
2133.5539360848202
20
3445.1441088344554
10
2073.5539360848202
20
3445.1441088344545
42
-0.41421356237309509
10
1958.5539360848202
20
3560.1441088344545
10
1958.5539360848202
20
3770.1441088344541
42
-0.41421356237309359
0
LINE
5
107
100
AcDbEntity
8
0
100
AcDbLine
10
2118.5539360848197
20
3830.1441088344541
30
0
11
2088.5539360848197
21
3830.1441088344541
31
0
0
LINE
5
108
100
AcDbEntity
8
0
100
AcDbLine
10
2103.5539360848202
20
3515.1441088344541
30
0
11
2103.5539360848202
21
3485.1441088344541
31
0
0
LINE
5
109
100
AcDbEntity
8
0
100
AcDbLine
10
2118.5539360848202
20
3500.1441088344541
30
0
11
2088.5539360848202
21
3500.1441088344541
31
0
0
ENDSEC
0
SECTION
2
OBJECTS
0
DICTIONARY
5
C
100
AcDbDictionary
3
ACAD_GROUP
350
D
3
ACAD_MLINESTYLE
350
17
0
DICTIONARY
5
D
100
AcDbDictionary
0
DICTIONARY
5
1A
330
C
100
AcDbDictionary
0
DICTIONARY
5
17
100
AcDbDictionary
0
ENDSEC
0
EOF

No issue with SWG The same result with DXF_2000 DXF_2013 DXF_2018

svenhb commented 5 months ago

If I import your DXF code, it looks good: I used this settings: image

image

svenhb commented 5 months ago

Perhaps there is a problem with tangential axis - I need to check, please try "avoid G2/G3"; image

voleoo commented 5 months ago

Perhaps there is a problem with tangential axis - I need to check, please try "avoid G2/G3"; image

That helps me, thank you