- fixed GCode generated with HPGL preprocessor to output only integer coordinates

- fixed the HPGL2 import parsing for absolute linear movements
This commit is contained in:
Marius Stanciu
2019-12-16 21:20:08 +02:00
committed by Marius
parent 0574f7a039
commit f857326687
3 changed files with 44 additions and 12 deletions

View File

@@ -111,9 +111,9 @@ class HPGL2:
self.initialize_re = re.compile(r'^(IN);?$')
# Absolute linear interpolation
self.abs_move_re = re.compile(r"^PA\s*(-?\d+\.?\d+?),?\s*(-?\d+\.?\d+?)*;?$")
self.abs_move_re = re.compile(r"^PA\s*(-?\d+\.?\d*),?\s*(-?\d+\.?\d*)*;?$")
# Relative linear interpolation
self.rel_move_re = re.compile(r"^PR\s*(-?\d+\.\d+?),?\s*(-?\d+\.\d+?)*;?$")
self.rel_move_re = re.compile(r"^PR\s*(-?\d+\.?\d*),?\s*(-?\d+\.?\d*)*;?$")
# Circular interpolation with radius
self.circ_re = re.compile(r"^CI\s*(\+?\d+\.?\d+?)?\s*;?\s*$")