|
68 | 68 |
|
69 | 69 | ; this is the function that puts the key switch holes
|
70 | 70 | ; based on the row and the column.
|
| 71 | + |
| 72 | + |
71 | 73 | (defn key-place
|
72 | 74 | "Puts the keys' shape to its place based on it's column and row."
|
73 | 75 | [c column row shape]
|
|
136 | 138 | hide-pinky (fn [column row]
|
137 | 139 | (not (and (= last-row-count :full)
|
138 | 140 | hide-last-pinky?
|
139 |
| - (last-pinky-location column row)))) |
140 |
| - ] |
| 141 | + (last-pinky-location column row))))] |
141 | 142 | (apply
|
142 | 143 | union
|
143 | 144 | (for [column (if use-inner-column? (range -1 ncols) (columns ncols))
|
|
200 | 201 | hide-pinky (fn [column row]
|
201 | 202 | (not (and (= last-row-count :full)
|
202 | 203 | hide-last-pinky?
|
203 |
| - (last-pinky-location column row)))) |
204 |
| - ] |
| 204 | + (last-pinky-location column row))))] |
205 | 205 | (union
|
206 | 206 | (apply
|
207 | 207 | union
|
|
317 | 317 | x-rotation (if (= thumb-count :five) 10 -6)
|
318 | 318 | y-rotation (if (= thumb-count :five) -23 -34)
|
319 | 319 | z-rotation (if (= thumb-count :five) 25 48)
|
320 |
| - movement (if (= thumb-count :five) [-23 -34 -6] [-29 -40 -13]) ] |
| 320 | + movement (if (= thumb-count :five) [-23 -34 -6] [-29 -40 -13])] |
321 | 321 | (->> shape
|
322 | 322 | (rotate (deg2rad x-rotation) [1 0 0])
|
323 | 323 | (rotate (deg2rad y-rotation) [0 1 0])
|
|
355 | 355 | z-rotation (if (= thumb-count :five) 35 52)
|
356 | 356 | movement (if (= thumb-count :five) [-51 -25 -11.5] [-56.3 -43.3 -23.5])]
|
357 | 357 | (->> shape
|
358 |
| - (rotate (deg2rad x-rotation) [1 0 0]) |
359 |
| - (rotate (deg2rad y-rotation) [0 1 0]) |
360 |
| - (rotate (deg2rad z-rotation) [0 0 1]) |
361 |
| - (translate (thumborigin c)) |
362 |
| - (translate movement)))) |
| 358 | + (rotate (deg2rad x-rotation) [1 0 0]) |
| 359 | + (rotate (deg2rad y-rotation) [0 1 0]) |
| 360 | + (rotate (deg2rad z-rotation) [0 0 1]) |
| 361 | + (translate (thumborigin c)) |
| 362 | + (translate movement)))) |
363 | 363 |
|
364 | 364 | (defn thumb-1x-layout [c shape]
|
365 | 365 | (let [thumb-count (get c :configuration-thumb-count)]
|
|
449 | 449 | (key-place c 2 cornerrow web-post-bl)
|
450 | 450 | (key-place c 2 lastrow web-post-tr)
|
451 | 451 | (key-place c 2 cornerrow web-post-br)
|
452 |
| - (key-place c 3 cornerrow web-post-bl)) ))) |
| 452 | + (key-place c 3 cornerrow web-post-bl))))) |
453 | 453 |
|
454 | 454 | (defn thumb-connector-three [c]
|
455 | 455 | (let [row-count (get c :configuration-last-row-count)
|
|
862 | 862 | lastrow (flastrow nrows)
|
863 | 863 | cornerrow (fcornerrow nrows)
|
864 | 864 | row-count (get c :configuration-last-row-count)
|
865 |
| - thumb-tr-post (if (= (get c :configuration-thumb-count) :five ) web-post-br thumb-post-br)] |
| 865 | + thumb-tr-post (if (= (get c :configuration-thumb-count) :five) web-post-br thumb-post-br)] |
866 | 866 | (union
|
867 | 867 | (wall-brace (partial thumb-tr-place c) 0 -1 thumb-tr-post
|
868 | 868 | (partial (partial key-place c) 3 (case row-count :zero cornerrow lastrow)) 0 -1 web-post-bl)
|
|
1156 | 1156 | 5 -1
|
1157 | 1157 | 6 -2
|
1158 | 1158 | -3)]
|
1159 |
| - ( key-position c 1 0 (map - (wall-locate2 0 y-addition) [0 (/ mount-height 2) 0])))) |
| 1159 | + (key-position c 1 0 (map - (wall-locate2 0 y-addition) [0 (/ mount-height 2) 0])))) |
1160 | 1160 |
|
1161 | 1161 | (defn trrs-usb-holder-position [c]
|
1162 | 1162 | (map + [17 19.3 0] [(first (trrs-usb-holder-ref c)) (second (trrs-usb-holder-ref c)) 2]))
|
|
1440 | 1440 | screw-insert-outers)
|
1441 | 1441 | (translate [0 0 -10] screw-insert-screw-holes))))))
|
1442 | 1442 |
|
1443 |
| - |
1444 | 1443 | #_(spit "things/left.scad"
|
1445 | 1444 | (write-scad (mirror [-1 0 0] model-right)))
|
1446 | 1445 |
|
|
0 commit comments