Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
69 changes: 56 additions & 13 deletions body/board_case.scad
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,12 @@ features todo:
- [x] magnetic fixation of the keyboard
- [x] additional pads fixation for the keyboard
- [x] rubber perimeter for better stability
- [ ] make maglet holders 3dprint friendly

*/

cut_angle = [-7, 14, 0];
magnet_radius = 4 / 2 + 0.05;
cut_angle = [-6, 13, 0];
magnet_radius = 4 / 2 + 0.1;
holder_thickness = 0.8;

module column3() {
Expand Down Expand Up @@ -81,8 +82,8 @@ module base_centered() {
}

module cut_centered() {
rotate([1, -1.5, 0])
translate([-70, 48, -8])
rotate([1, -1.0, 0])
translate([-70, 48, -8.35])
//hull() {
import("corne_shape_with_stands.stl");
//}
Expand All @@ -108,7 +109,7 @@ module shell() {
difference() {
minkowski() {
outline();
sphere(r=4);
sphere(r=4.2);
}

minkowski() {
Expand All @@ -135,6 +136,50 @@ module one_half() {

double_magnet_plane(magnet_radius, 2, 0.1);
}

intersection() {
minkowski() {
outline();
sphere(r=4);
}
rotate(cut_angle) {
print_helpers();
}
}
}

module print_helpers() {
translate([30, 35.6, 2.7])
hull() {
cylinder(h=0.5, r=magnet_radius + holder_thickness, $fn=50);

translate([3, 15, 20])
cylinder(h=0.5, r=magnet_radius + holder_thickness, $fn=50);
}

translate([-30, -35.6, 2.7])
hull() {
cylinder(h=0.5, r=magnet_radius + holder_thickness, $fn=50);

translate([0, -10, 10])
cylinder(h=0.5, r=magnet_radius + holder_thickness, $fn=50);
}

translate([-33, 50, 2.7])
hull() {
cylinder(h=0.5, r=magnet_radius + holder_thickness, $fn=50);

translate([0, 5, 10])
cylinder(h=0.5, r=magnet_radius + holder_thickness, $fn=50);
}

translate([33, -50, 2.7])
hull() {
cylinder(h=0.5, r=magnet_radius + holder_thickness, $fn=50);

translate([0, -5, 10])
cylinder(h=0.5, r=magnet_radius + holder_thickness, $fn=50);
}
}

one_half();
Expand All @@ -159,7 +204,7 @@ module rubber_cuts() {
rotate([0, 0, 22.9])
cube([20, 1.8, 1.8], center=true);

translate([44, 32.5, 0])
translate([44, 33.5, 0])
rotate([0, 0, -22])
cube([20, 1.8, 1.8], center=true);

Expand Down Expand Up @@ -187,7 +232,7 @@ module double_angled_cuts() {

module magnets_plane(radius, height, voffset) {

translate([34, -49.9, voffset])
translate([33, -49.9, voffset])
cylinder(h=height * 2 + voffset * 2, r=radius, $fn=50, center=true);

translate([30, 35.6, voffset])
Expand Down Expand Up @@ -237,12 +282,10 @@ module test_magnet() {

//corne_centered();

/*
translate([0, 0, -40])
rotate([0, 180, 0])
scale([1, -1, 1])
corne_centered();
*/
//translate([0, 0, -40])
// rotate([0, 180, 0])
// scale([1, -1, 1])
// corne_centered();

/*
difference() {
Expand Down
Binary file modified body/board_case.stl
Binary file not shown.
207 changes: 4 additions & 203 deletions body/body_with_stands.scad
Original file line number Diff line number Diff line change
@@ -1,205 +1,6 @@
$fn = 50;
include <corne_body_models.scad>;

/**
* Corne Chocoflan case body with stands and magnet holes
*
* Based on corne_chocoflan_basic.stl
*
* todo:
* - move two stands 0.5mm up
* - make magnet holes
*
*/
body();

magnet_radius = 4 / 2 + 0.2;

magnet1_pos = [8.8, -21.5, 9.4];
magnet2_pos = [8.8, -56.9, 9.4];
magnet3_pos = [91.5, -85.0, 8.4];
magnet4_pos = [101, -14.5, 8.2];

module body() {
difference() {

union() {
import("corne_chocoflan_basic.stl");
thicknessCubes();
innerStands();

translate(magnet1_pos)
cylinder(h=2.14, r=magnet_radius + 0.5);

translate(magnet2_pos)
cylinder(h=2.14, r=magnet_radius + 0.5);

translate(magnet3_pos)
cylinder(h=2.14, r=magnet_radius + 0.5);

translate(magnet4_pos)
cylinder(h=2.14, r=magnet_radius + 0.5);
}
//import("corne_chocoflan_basic.stl");

translate(magnet1_pos)
cylinder(h=4.04, r=magnet_radius);

translate(magnet2_pos)
cylinder(h=4.04, r=magnet_radius);

translate(magnet3_pos)
cylinder(h=4.04, r=magnet_radius);

translate(magnet4_pos)
cylinder(h=4.04, r=magnet_radius);

rotate([0, 1, 0])
linearCuts();

// standCuts();
//cube([25,250,100], center=true);
}
}

//rotate([0,1,0])
//linearCuts();

//translate([8.1,-16.1, 8.5])
//rotate([0,0.6,0])
// cube([150,150,0.5]);

module stand() {
difference() {
union() {
cylinder(h=3, r1=1.5, r2=1.5);
cylinder(h=2, r1=4.5, r2=4);
}
cylinder(h=4, r=1);
}
}

module innerStands1() {
//cube([18.5,18.5,2]);
translate([18.5, 0, 0])
stand();
}

module innerStands2() {
//cube([18.5,19,2]);
translate([18.5, 19, 0])
stand();
}

module innerStands3() {
//cube([94.75,17,2]);
translate([94.75, 0, 0])
stand();
}

module innerStands4() {
//cube([23.5,64.5,2]);
translate([0, 0, 0])
stand();
}

module innerStands() {
translate([6.1, -32.6, 9.427])
innerStands1();

translate([6.1, -70.5, 9.427])
innerStands2();

translate([6.1, -29.4, 9.427])
innerStands3();

translate([114.4, -77.0, 9.427])
innerStands4();
}

module bottomCube2() {
//cube([3,3,1]);
translate([0, -6, 0])
cube([38, 6, 1.5]);
}

module bottomCube1() {
//cube([10,10,1]);
translate([0, 10, 0])
cube([38, 6, 1.5]);
}

module thicknessCubes() {
translate([6, -70, 9.2])
bottomCube1();

translate([6, -18, 9.2])
bottomCube2();
}

module standCut() {
cylinder(h=1, r=3, center=true);
difference() {
cylinder(h=1, r=5.5, center=true);
cylinder(h=3, r=3.5, center=true);
}
}

module linearCut() {
cube([30, 1.6, 1.6]);
translate([0, 1.6 * 2, 0])
cube([30, 1.6, 1.6]);
}

module linearCuts() {

depth = 8.3;

translate([12, -23.5, depth])
linearCut();

translate([12, -59.5, depth])
linearCut();

translate([95, -80, depth])
rotate([0, 0, -15])
linearCut();

translate([100, -25.5, depth])
linearCut();
}

//linearCuts();

module standCuts() {
zoffset = 9;
translate([24.5, -52, zoffset]) standCut();
translate([24.5, -32.5, zoffset]) standCut();

translate([120, -84, zoffset]) standCut();
translate([130, -25, zoffset]) standCut();
}

module body_solid() {

union() {
import("corne_shape.stl");

rotate([0, 0.7, 0])
linearCuts();

translate([0, 0, -6.8]) {
translate(magnet1_pos)
cylinder(h=6.04, r=magnet_radius);

translate(magnet2_pos)
cylinder(h=6.04, r=magnet_radius);

translate(magnet3_pos)
cylinder(h=6.04, r=magnet_radius);

translate(magnet4_pos)
cylinder(h=6.04, r=magnet_radius);
}
}
}

body_solid();
// corne shape with stands
// body_solid();
Binary file modified body/body_with_stands.stl
Binary file not shown.
Loading
Loading