AcornElectron

Changeset

71:b22338192433
2016-04-11 Paul Boddie raw files shortlog changelog graph Added the alternative approach of removing the back cavity entirely in the connector section.
cartridge.scad (file)
     1.1 --- a/cartridge.scad	Mon Apr 11 12:52:23 2016 +0200
     1.2 +++ b/cartridge.scad	Mon Apr 11 13:56:43 2016 +0200
     1.3 @@ -36,6 +36,12 @@
     1.4  	FRONT_LABEL_INSET = 0; TOP_LABEL_INSET = 0;
     1.5  	GROOVE = 0; ROUND_EDGES = 0; ROUND_CONNECTING_EDGES = 0;
     1.6  
     1.7 +	To retain the back connecting piece instead, change the above to...
     1.8 +
     1.9 +	BACK_CONNECTOR_SECTION = 1;
    1.10 +	EXTERNAL_BACK_CAVITY = 0;
    1.11 +	EXTERNAL_BACK_CUTOUT = 1;
    1.12 +
    1.13  	Leave all options enabled for more capable 3D printers.
    1.14  	*/
    1.15  
    1.16 @@ -43,7 +49,10 @@
    1.17  	BACK_CONNECTOR_SECTION = 1;
    1.18  
    1.19  	/* A necessary exterior cavity to let the cartridge fit inside the slot. */
    1.20 -	BACK_CAVITY = 1;
    1.21 +	EXTERNAL_BACK_CAVITY = 1;
    1.22 +
    1.23 +	/* An alternative cutout to let the cartridge fit inside the slot. */
    1.24 +	EXTERNAL_BACK_CUTOUT = 0;
    1.25  
    1.26  	/* Optional insets for labels. */
    1.27  	FRONT_LABEL_INSET = 1;
    1.28 @@ -1082,9 +1091,9 @@
    1.29  
    1.30  					if (BACK_CONNECTOR_SECTION) {
    1.31  
    1.32 -						/* Back cavity. */
    1.33 +						/* Provide an external cavity. */
    1.34  
    1.35 -						if (BACK_CAVITY)
    1.36 +						if (EXTERNAL_BACK_CAVITY)
    1.37  							intersection() {
    1.38  
    1.39  								/* From the bottom upwards. */
    1.40 @@ -1117,7 +1126,26 @@
    1.41  												]);
    1.42  							}
    1.43  
    1.44 -						/* Inner back cavities. */
    1.45 +						/* Or remove the back section entirely. */
    1.46 +
    1.47 +						else if (EXTERNAL_BACK_CUTOUT)
    1.48 +							translate([0, back_depth, lower_extent])
    1.49 +								linear_extrude(height = back_cavity_height)
    1.50 +									translate([int_connector_left_extent, 0, 0])
    1.51 +										polygon([
    1.52 +											[back_cavity_offset_from_inner_left, 0],
    1.53 +											[inner_back_slope_min_offset,
    1.54 +												-connector_back + inner_back_slope_depth],
    1.55 +											[inner_back_slope_min_offset, -connector_back],
    1.56 +											[int_connector_width - inner_back_slope_min_offset,
    1.57 +												-connector_back],
    1.58 +											[int_connector_width - inner_back_slope_min_offset,
    1.59 +												-connector_back + inner_back_slope_depth],
    1.60 +											[back_cavity_offset_from_inner_left +
    1.61 +												back_cavity_width, 0]
    1.62 +											]);
    1.63 +
    1.64 +						/* Inner back cavities making the back thinner at the sides. */
    1.65  
    1.66  						translate([0, int_connector_back_depth, lower_extent])
    1.67  							linear_extrude(height = int_connector_height)
    1.68 @@ -1141,7 +1169,7 @@
    1.69  										[0, inner_back_slope_depth]
    1.70  										]);
    1.71  
    1.72 -						/* Inner back edge cavity. */
    1.73 +						/* Inner back edge cavity, tapering the bottom edge. */
    1.74  
    1.75  						translate([inner_back_edge_width / 2,
    1.76  							int_connector_back_depth + inner_back_edge_depth, lower_extent])