Add some notes

This commit is contained in:
Adam Goldsmith 2018-06-11 21:25:43 -04:00
parent c5e3afbd95
commit 57fbc2997f
1 changed files with 8 additions and 1 deletions

View File

@ -4,6 +4,12 @@ import os
import re
import sys
# Based off of notes from
# https://github.com/fellesverkstedet/gcc-laserpro-driver
# and http://www.wiki.cl.cam.ac.uk/rowiki/CompArch/HardwareLab/LaserCutter
# and src/core/path_gcc.c from
# https://github.com/fellesverkstedet/fabmodules
def write_pen_values(values, char):
return "!v64" + char + "".join(["{:04d}".format(value) for value in values])
@ -32,7 +38,7 @@ def pre_content(filename, power, speed, rate, pen_settings):
# Select first (and only) pen (commented out in original source)
# outString += "!v1D"
# outString += "!m2A" # might cause autofocus?
# outString += "!m2A" # triggers autofocus
# Use same value for all 16 pens
# doesn't seem to affect vector settings
@ -52,6 +58,7 @@ def set_vector_pens(content, pen_settings):
power=pen_settings['power'][num],
speed=pen_settings['speed'][num],
penNum=num+1) for num in range(0, 16)])
# TODO: find out why slow movement in PU (pen up) until first PD (pen down)
content = re.sub(
"FS\d{1,4};VS\d{1,4};SP1;",
settings + "SP1;",