2011-09-05 14:11:59 +03:00
|
|
|
SHELL=/bin/bash
|
|
|
|
|
2011-09-05 02:36:30 +03:00
|
|
|
SPOOL=/home/moko/svn.openmoko.org/developers/werner/cncmap/spool/spool
|
|
|
|
CNGT=/home/qi/cae-tools/cngt/cngt
|
|
|
|
|
2011-09-05 14:11:59 +03:00
|
|
|
.PHONY: all mill pos cng plot clean
|
2011-09-05 02:36:30 +03:00
|
|
|
|
|
|
|
all: mill.rml
|
|
|
|
|
|
|
|
front.gp: front.fpd
|
2011-09-05 14:11:59 +03:00
|
|
|
fped -g -1 front-cut $< - | ./filter !logo >$@; \
|
|
|
|
[ "$${PIPESTATUS[*]}" = "0 0" ] || { rm -f $@; exit 1; }
|
2011-09-05 02:36:30 +03:00
|
|
|
|
|
|
|
logo.gp: front.fpd
|
2011-09-05 14:11:59 +03:00
|
|
|
fped -g -1 front-cut $< - | ./filter logo >$@; \
|
|
|
|
[ "$${PIPESTATUS[*]}" = "0 0" ] || { rm -f $@; exit 1; }
|
2011-09-05 02:36:30 +03:00
|
|
|
|
|
|
|
mill.rml mill.gp: front.gp logo.gp
|
2011-09-05 04:00:48 +03:00
|
|
|
./doit BOARD_Z=1.6mm ENGRAVE_Z=0.5mm CLEARANCE=3mm || \
|
|
|
|
{ rm -rf $@; exit 1; }
|
2011-09-05 02:36:30 +03:00
|
|
|
|
2011-09-05 02:50:47 +03:00
|
|
|
mill: mill.rml
|
2011-09-05 02:36:30 +03:00
|
|
|
PORT=/dev/ttyUSB0 $(SPOOL) mill.rml
|
|
|
|
|
2011-09-05 14:11:59 +03:00
|
|
|
pos: mill.gp
|
|
|
|
$(CNGT) -57.4
|
|
|
|
|
2011-09-05 02:36:30 +03:00
|
|
|
cng: mill.gp
|
|
|
|
$(CNGT) -57.4 20 mill.gp
|
|
|
|
|
|
|
|
plot:
|
|
|
|
echo 'splot "mill.gp" with lines' | gnuplot -persist
|
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -f front.gp mill.gp mill.rml
|