chiark / gitweb /
Merge commit '875be22af707972efae3359b08ec78a328c91f59'
[reprap-play.git] / fairphone4-case-tripod.scad
index dbe876249598bf5c89aed227f39e4276de2374ab..b244673c86af0054eac31053348a17bce58af773 100644 (file)
@@ -2,23 +2,33 @@
 
 include <camera-mount.scad>
 
-cube_sz = [12, 12, 12];
+tr_cube_offset = 20;
+tr_cube_sz = [20, 20, 15];
+tr_around = 10;
 
 module Mount(){
+  translate([0,  - tr_cube_sz[1], 0])
   difference(){
-    translate([0, cube_sz[1]/2, cube_sz[2]/2])
-      cube(cube_sz, center=true);
-    translate([0, 0, cube_sz[2]/2])
-      rotate([90,0,0])
-      render() CameraMountThread(cube_sz[1]);
+    translate([0, tr_cube_sz[1]/2 - tr_cube_offset/2, tr_cube_sz[2]/2])
+      cube(tr_cube_sz + [0, tr_cube_offset, 0], center=true);
+    translate([0, tr_cube_sz[1]/2 - tr_cube_offset, 0])
+      rotate([180,0,0])
+      render() CameraMountThread(tr_cube_sz[2] + 1);
   }
 }
 
 module CaseMounted(){ ////toplevel
-  render() Case();
-  translate([ phone_width * 0.15,
-             -phone_height - cube_sz[1],
+  difference(){
+    render() Case();
+    translate([ phone_width/2, -phone_height/2 ])
+      linextr(-50, 50)
+      square([phone_width, phone_height] - tr_around * 2 * [1,1],
+            center=true);
+  }
+  translate([ phone_width,
+             -phone_height + tr_cube_sz[0] * 0.7,
              epp3[1] - case_th_bottom ])
+    rotate([0,0,90])
     Mount();
 }