3 include <commitid.scad>
5 include <sealing-box.scad>
7 pxp6012_rad = 22.5 / 2 + 0.5; // make circular hole this size in outer wall
8 pxp6012_rad_outer = 32.0 / 2 - 0.5;
12 s1930_y_outer = 36.4 + 0.2;
13 s1930_x_outer = 27.6 + 0.2;
33 totx_outer = totx_inner + wallthick*2;
34 toty_inner = toty_outer - wallthick*2;
35 totz_inner = totz_outer - wallthick*2;
37 sb_box_sz = [totx_outer, totz_outer, toty_inner];
39 // origin is at centre on outer face wall
40 // outside is towards positive x
41 // mounting is vertical
42 module S1930_Positive(){
43 d = s1930_recess + s1930_behind;
44 translate([-d/2, 0,0])
46 s1930_x_outer + s1930_around,
47 s1930_y_outer + s1930_around], center=true);
49 module S1930_Negative(){
50 cube([60, s1930_x, s1930_y],
53 cube([s1930_recess*2+2, s1930_x_outer, s1930_y_outer],
57 module TestWall(){ ////toplevel
58 sw_ctr = [25, wallthick, 25];
63 cube([50, wallthick, 42]);
66 translate([30, -1, 20])
68 cylinder(r = pxp6012_rad, h=10, $fn=60);
71 Commitid_BestCount([15,40]);
77 cube([50, wallthick, 50]);
94 ts_box_sz = [ts_totx, ts_toty, ts_totz_inner];
96 $sealingbox_wallth = wallthick;
97 $sealingbox_floorth = wallthick;
98 $sealingbox_ceilth = wallthick;
100 module TestSealBox(){ ////toplevel
101 $sealingbox_sz = ts_box_sz;
103 SealingBox_RectBox();
104 ts_cidoff = ($sealingbox_cnrrad * (1-.7) + wallthick * .8) * [1,1];
106 Commitid_BestCount([ts_totx,ts_toty] - 2*ts_cidoff);
109 module TestSealLid(){ ////toplevel
110 $sealingbox_sz = ts_box_sz;
113 SealingBox_RectLid();
115 translate([ts_totx * .75, ts_toty/2, 0])
116 cylinder(h=100, r=5);
118 translate([-wallthick + $sealingbox_cnrrad*.5,
119 $sealingbox_cnrrad*.5 - wallthick,
120 ts_totz_inner + $sealingbox_ceilth])
121 Commitid_BestCount([ts_totx * .75 - 2.5 - ($sealingbox_cnrrad*.5),
122 ts_toty - ($sealingbox_cnrrad*.5 - wallthick)*2]);
126 module TestSealLidPrint(){ ////toplevel
127 rotate([180,0,0]) TestSealLid();
130 module ProfileDemos(){ ////toplevel
131 $sealingbox_sz = ts_box_sz;
133 SealingBox_WallProfile();
134 color("blue") SealingBox_FloorProfile();
135 SealingBox_LidProfile();
136 color("blue") SealingBox_CeilProfile();
137 color("red") translate([-5,0]) square([1,ts_totz_inner]);
140 module Box(){ ////toplevel
141 $sealingbox_sz = sb_box_sz;
143 chargingconn_x = pxp6012_rad_outer + 1 + $sealingbox_cnrrad;
144 switch_x = chargingconn_x + pxp6012_rad_outer
145 + s1930_y_outer/2 + s1930_around;
147 strap_x_tot = strap_w + strap_pillar*2;
152 translate([-wallthick,-wallthick, -toty_inner])
153 SealingBox_RectBox();
155 translate([switch_x, toty_inner, totz_inner/2])
160 for (sx= [ 45, 80, 110 ]) {
161 for (sy= [ 10, 40 ]) {
162 translate([sx - strap_x_tot, sy, 0])
164 translate([0,0, -0.1])
165 cube([strap_x_tot, strap_pillard, strap_th + strap_over]);
166 translate([strap_pillar, -1, 0])
167 cube([strap_w, strap_pillard+2, strap_th]);
173 // charging connector
174 translate([chargingconn_x,
175 toty_inner - (pxp6012_rad_outer + 5),
177 cylinder(r= pxp6012_rad, h= totz_outer);
179 translate([switch_x, toty_inner, totz_inner/2])
189 //FArcSegment_mask(350);