3 include <moebius-core.scad>
11 pin_slot_xslop = 0.25;
13 pin_yadj_range = [ -0.50, +0.25 ];
17 pin_pin_yadj_range = pin_yadj_range + [ 0.00, 0.00 ];
23 sliceat = moebiuscore_sliceat * moebiuscore_nomsize;
24 pin_slopeheight = (pin_headwidth - pin_stemwidth)/2;
27 translate([0,0, 200-sliceat])
28 cube(center=true, 400);
38 module HalfPinHeadProfile(xslop, yadj, lenadj) {
39 sw = pin_stemwidth + xslop*2;
40 tw = pin_headwidth + xslop*2;
41 th = pin_headheight + lenadj - yadj;
44 pin_stemlen/2 + yadj + pin_slopeheight ])
47 pin_stemlen/2 + yadj ])
52 module PinStemProfile(xslop, yadj) {
53 sl = pin_stemlen + pin_headheight/2 + max(yadj * 2, 0);
55 [ pin_stemwidth + xslop*2,
59 module PinExtrudePortion(zi,zrange){
60 translate([0,0,zrange[zi]])
62 linear_extrude(height=0.1)
66 module PinExtrude(zrange,
68 yadjs=[[0,0], [0,0]], // [top[], bottom[]]
69 lenadjs=[0,0]){ // in each case: zrange[0],zrange[1]
71 mirror([0,topboti,0]){
74 PinExtrudePortion(zi,zrange)
75 HalfPinHeadProfile(xslop, yadjs[topboti][zi], lenadjs[zi]);
81 PinExtrudePortion(zi,zrange)
82 PinStemProfile(xslop, max(yadjs[zi][0], yadjs[zi][1]));
88 xslop= pin_slot_xslop,
90 [1,1] * -pin_stemlen/2 ],
91 // bigger gap in -ve y direction
92 lenadjs = [1,1] * (pin_yslop + pin_yadj_range[1]) );
96 PinExtrude([-0.5, 0.5] * pin_height,
97 xslop = -pin_pin_xslop,
98 yadjs = [pin_pin_yadj_range, pin_pin_yadj_range],
99 lenadjs = [1,1] * pin_yadj_range[1]
103 module PlacePins(pins=[0,1]){
105 translate( moebius_pin_locns[i] * moebiuscore_nomsize ) {
106 multmatrix(moebius_pin_matrix[i])
117 module Top(){ ////toplevel
129 module Bottom(){ ////toplevel
134 mirror([0,1,0]) PinCutout();
138 module Demo(){ ////toplevel
141 color("blue") PlacePins([0]) Pin();
144 module Kit(){ ////toplevel
145 off = moebiuscore_nomsize*2.5;
146 pt = pin_stemlen/2 + pin_headheight
147 + pin_pin_yadj_range[1] + pin_slopeheight;
149 translate([0,0,sliceat])
151 translate([ 0, -off, 0 ])
153 translate([0,0,sliceat])
155 for (d = [0,1] * pin_height * 2)
156 translate([ off, d, pt ])
161 module TestKit(){ ////toplevel
164 cube([500,500,15], center=true);
170 //PinExtrude([-2,10]);