screws.scad 966 Bytes

module screw6x50() {
  color("#ccc") translate([0,0,-0.3]) {
    cylinder(d=0.58,h=5, $fn=10);
    translate([0,0,-0.3]) {
      cylinder(d=1,h=0.3,$fn=6);
    }
  }
}

module shim() {
  color("#eee") cylinder(d=1.3,h=0.1);
}

module nut() {
  color("#aaa") cylinder(d=1,h=0.3,$fn=6);
}

module cornerscrew(z) {
  translate([0,0,2]) shim();
  translate([0,0,1.7]) nut();
  translate([0,0,-0.30]) shim();
  translate([0,0,-0.30+strength+0.1]) shim();
  translate([0,0,-0.30+strength+0.2]) nut();
  screw6x50();
}

module cornerscrews(z) {

  translate([2.4
             , 0.8
             , z - 2.36
             ])
    cornerscrew(z);

  translate([0.8
             , 2.4
             , z - 2.36
             ])
    cornerscrew(z);
}


module screws(x,y,z) {
  cornerscrews(22);
  mirror([0,1,0]) translate([0,-y,0]) cornerscrews(22);
  mirror([1,0,0]) translate([-x,0,0]) cornerscrews(22);
  mirror([1,0,0]) translate([-x,y,0]) mirror([0,1,0]) cornerscrews(22);
}