From 6e6b11af6a4bb8644f1a293490760996312c5340 Mon Sep 17 00:00:00 2001 From: Tom Short Date: Sun, 2 Apr 2017 15:09:06 -0400 Subject: [PATCH] Changes for patching to script other sizes --- 0001-Changes-for-5x6.patch | 42 ++++++++++++++++++++++++++++++++++++++ create-models.sh | 22 ++++++++++---------- 2 files changed, 53 insertions(+), 11 deletions(-) create mode 100644 0001-Changes-for-5x6.patch diff --git a/0001-Changes-for-5x6.patch b/0001-Changes-for-5x6.patch new file mode 100644 index 0000000..760c0d6 --- /dev/null +++ b/0001-Changes-for-5x6.patch @@ -0,0 +1,42 @@ +From cf28ce0da510b4342d2e6602ee422c13a41a46e1 Mon Sep 17 00:00:00 2001 +From: Tom Short +Date: Sun, 2 Apr 2017 14:06:18 -0400 +Subject: [PATCH] Changes for 5x6 + +--- + src/dactyl_keyboard/dactyl.clj | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) + +diff --git a/src/dactyl_keyboard/dactyl.clj b/src/dactyl_keyboard/dactyl.clj +index 816bff8..0e5bd10 100644 +--- a/src/dactyl_keyboard/dactyl.clj ++++ b/src/dactyl_keyboard/dactyl.clj +@@ -13,13 +13,13 @@ + ;; Shape parameters ;; + ;;;;;;;;;;;;;;;;;;;;;; + +-(def nrows 4) +-(def ncols 5) ++(def nrows 5) ++(def ncols 6) + + (def α (/ π 12)) ; curvature of the columns + (def β (/ π 36)) ; curvature of the rows + (def centerrow (- nrows 3)) ; controls front-back tilt +-(def centercol 3) ; controls left-right tilt / tenting (higher number is more tenting) ++(def centercol 2) ; controls left-right tilt / tenting (higher number is more tenting) + (def tenting-angle (/ π 12)) ; or, change this for more precise tenting control + (def column-style + (if (> nrows 5) :orthographic :standard)) ; options include :standard, :orthographic, and :fixed +@@ -32,7 +32,7 @@ + + (def thumb-offsets [6 -3 7]) + +-(def keyboard-z-offset 9) ; controls overall height; original=9 with centercol=3; use 15 for centercol=2 ++(def keyboard-z-offset 16) ; controls overall height; original=9 with centercol=3; use 15 for centercol=2 + + (def extra-width 2.5) ; extra space between the base of keys; original= 2 + (def extra-height 1.0) ; original= 0.5 +-- +2.10.2.windows.1 + diff --git a/create-models.sh b/create-models.sh index 0c911fa..da1e00c 100644 --- a/create-models.sh +++ b/create-models.sh @@ -5,18 +5,18 @@ cp things/right-plate.scad things/right-4x5-plate.scad openscad -o things/right-4x5.stl things/right-4x5.scad >/dev/null 2>&1 & openscad -o things/left-4x5.stl things/left-4x5.scad >/dev/null 2>&1 & openscad -o things/right-4x5-plate.dxf things/right-4x5-plate.scad >/dev/null 2>&1 & + +git am < 0001-Changes-for-5x6.patch +lein run src/dactyl_keyboard/dactyl.clj +cp things/right.scad things/right-5x6.scad +cp things/left.scad things/left-5x6.scad +cp things/right-plate.scad things/right-5x6-plate.scad +openscad -o things/right-5x6.stl things/right-5x6.scad >/dev/null 2>&1 & +openscad -o things/left-5x6.stl things/left-5x6.scad >/dev/null 2>&1 & +openscad -o things/right-5x6-plate.dxf things/right-5x6-plate.scad >/dev/null 2>&1 & +git apply -R < 0001-Changes-for-5x6.patch + # git add things/*-4x5.stl # git add things/right-4x5-plate.dxf # git commit -m "Add CAD files" - -# git checkout 5x6 -# lein run src/dactyl_keyboard/dactyl.clj -# cp things/right.scad things/right-5x6.scad -# cp things/left.scad things/left-5x6.scad -# cp things/right-plate.scad things/right-5x6-plate.scad -# openscad -o things/right-5x6.stl things/right-5x6.scad & -# openscad -o things/left-5x6.stl things/left-5x6.scad & -# openscad -o things/right-5x6-plate.dxf things/right-5x6-plate.scad & -# git checkout mine/master - wait \ No newline at end of file