more designs
This commit is contained in:
127
bus_cabinet_door_1.scad
Normal file
127
bus_cabinet_door_1.scad
Normal file
@@ -0,0 +1,127 @@
|
|||||||
|
// Door measurements
|
||||||
|
width = 516;
|
||||||
|
height = 766;
|
||||||
|
thickness = 18;
|
||||||
|
|
||||||
|
// Pattern parameters
|
||||||
|
border_margin = 80;
|
||||||
|
border_width = 40;
|
||||||
|
// border_angle = 30;
|
||||||
|
border_depth = 10;
|
||||||
|
border_depth_2 = 4;
|
||||||
|
|
||||||
|
small_border_width = 4;
|
||||||
|
small_border_thickness = 2;
|
||||||
|
|
||||||
|
outside_border_width = border_width / 2;
|
||||||
|
outside_border_depth_2 = 2;
|
||||||
|
|
||||||
|
inner_depth = 2;
|
||||||
|
|
||||||
|
// Technical params
|
||||||
|
mill_diameter = 8;
|
||||||
|
|
||||||
|
module door(){
|
||||||
|
difference(){
|
||||||
|
cube(size=[width, height, thickness], center=false);
|
||||||
|
translate([border_margin, border_margin, thickness+0.01])
|
||||||
|
union(){
|
||||||
|
borders(height-2*border_margin, width-2*border_margin, border_width, border_depth, border_depth_2);
|
||||||
|
outside_borders(height-2*border_margin, width-2*border_margin, border_width, border_depth, border_depth_2);
|
||||||
|
}
|
||||||
|
translate([border_margin-outside_border_width, 0, thickness-small_border_thickness+0.01])
|
||||||
|
cube(size=[small_border_width, height, small_border_thickness], center=false);
|
||||||
|
translate([width-border_margin-small_border_width+outside_border_width, 0, thickness-small_border_thickness+0.01])
|
||||||
|
cube(size=[small_border_width, height, small_border_thickness], center=false);
|
||||||
|
|
||||||
|
translate([border_margin, border_margin, thickness-inner_depth])
|
||||||
|
cube(size=[width-2*border_margin, height-2*border_margin, 10], center=false);
|
||||||
|
// Custom small border
|
||||||
|
// translate([border_margin-border_depth_2, border_margin-border_depth_2, thickness-border_depth_2])
|
||||||
|
// cube(size=[width-2*border_margin+2*border_depth_2, height-2*border_margin+2*border_depth_2, border_depth_2+0.01], center=false);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module border(length, width, depth1, depth2, mill_dia){
|
||||||
|
points = [[0,depth2], [0,0], [width,0], [width, depth1], [width-mill_dia, depth1]];
|
||||||
|
rotate([-90,0,0])
|
||||||
|
linear_extrude(height=length){
|
||||||
|
polygon(points=points);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module outside_border(length, width, depth1, depth2) {
|
||||||
|
translate([0, length, 0])
|
||||||
|
rotate([0,0,180])
|
||||||
|
border(length, width, depth1, depth2, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
module borders(length_border, width_border, width, depth1, depth2){
|
||||||
|
union(){
|
||||||
|
translate([width_border-width, 0, 0])
|
||||||
|
border(length_border, width, depth1, depth2, mill_diameter);
|
||||||
|
translate([width, length_border, 0])
|
||||||
|
rotate([0,0,180])
|
||||||
|
border(length_border, width, depth1, depth2, mill_diameter);
|
||||||
|
translate([0, width, 0])
|
||||||
|
rotate([0,0,-90])
|
||||||
|
border(width_border, width, depth1, depth2, mill_diameter);
|
||||||
|
translate([width_border, length_border-width, 0])
|
||||||
|
rotate([0,0,90])
|
||||||
|
border(width_border, width, depth1, depth2, mill_diameter);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module outside_border_corner(length_border, width_border, width, depth1, depth2){
|
||||||
|
intersection(){
|
||||||
|
translate([-outside_border_width+0.01, length_border+outside_border_width, 0])
|
||||||
|
rotate([0,0,180])
|
||||||
|
outside_border(length_border+2*outside_border_width, outside_border_width, depth1, depth2);
|
||||||
|
translate([-outside_border_width, -outside_border_width+0.01, 0])
|
||||||
|
rotate([0,0,-90])
|
||||||
|
outside_border(width_border+2*outside_border_width, outside_border_width, depth1, depth2);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module outside_borders(length_border, width_border, width, depth1, depth2){
|
||||||
|
union(){
|
||||||
|
translate([width_border+outside_border_width-0.01, 0, 0])
|
||||||
|
outside_border(length_border, outside_border_width, depth1, outside_border_depth_2);
|
||||||
|
translate([-outside_border_width+0.01, length_border, 0])
|
||||||
|
rotate([0,0,180])
|
||||||
|
outside_border(length_border, outside_border_width, depth1, outside_border_depth_2);
|
||||||
|
translate([0, -outside_border_width+0.01, 0])
|
||||||
|
rotate([0,0,-90])
|
||||||
|
outside_border(width_border, outside_border_width, depth1, outside_border_depth_2);
|
||||||
|
translate([width_border, length_border+outside_border_width-0.01, 0])
|
||||||
|
rotate([0,0,90])
|
||||||
|
outside_border(width_border, outside_border_width, depth1, outside_border_depth_2);
|
||||||
|
|
||||||
|
// Now add the corners
|
||||||
|
outside_border_corner(length_border, width_border, width, depth1, outside_border_depth_2);
|
||||||
|
|
||||||
|
translate([width_border,0,0])
|
||||||
|
rotate([0,0,90])
|
||||||
|
outside_border_corner(length_border, width_border, width, depth1, outside_border_depth_2);
|
||||||
|
|
||||||
|
translate([width_border,length_border,0])
|
||||||
|
rotate([0,0,180])
|
||||||
|
outside_border_corner(length_border, width_border, width, depth1, outside_border_depth_2);
|
||||||
|
|
||||||
|
translate([0,length_border,0])
|
||||||
|
rotate([0,0,-90])
|
||||||
|
outside_border_corner(length_border, width_border, width, depth1, outside_border_depth_2);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
color(c = [0.9, 0.9, 0.9]){
|
||||||
|
door();
|
||||||
|
}
|
||||||
|
// door();
|
||||||
|
|
||||||
|
// rotate([90,0,0])
|
||||||
|
// outside_border(500, border_width, border_depth, border_depth_2);
|
||||||
|
|
||||||
|
// outside_borders(height-2*border_margin, width-2*border_margin, border_width, border_depth, border_depth_2);
|
||||||
|
|
||||||
|
// borders(height, width, border_width, border_depth);
|
||||||
259
bus_cabinet_door_2.scad
Normal file
259
bus_cabinet_door_2.scad
Normal file
@@ -0,0 +1,259 @@
|
|||||||
|
// Door measurements
|
||||||
|
width = 516;
|
||||||
|
height = 767;
|
||||||
|
thickness = 18;
|
||||||
|
|
||||||
|
// Pattern parameters
|
||||||
|
border_margin = 60;
|
||||||
|
border_width = 40;
|
||||||
|
// border_angle = 30;
|
||||||
|
border_depth = 8;
|
||||||
|
border_depth_2 = 4;
|
||||||
|
|
||||||
|
small_border_width = 4;
|
||||||
|
small_border_thickness = 2;
|
||||||
|
|
||||||
|
outside_border_width = border_width / 2;
|
||||||
|
outside_border_depth_2 = 2;
|
||||||
|
|
||||||
|
inner_depth = 8;
|
||||||
|
|
||||||
|
round_radius = 8;
|
||||||
|
|
||||||
|
// Technical params
|
||||||
|
mill_diameter = 8;
|
||||||
|
|
||||||
|
module door(){
|
||||||
|
difference(){
|
||||||
|
cube(size=[width, height, thickness], center=false);
|
||||||
|
translate([border_margin, border_margin, thickness+0.01])
|
||||||
|
|
||||||
|
// outside_borders(height-2*border_margin, width-2*border_margin, border_width, border_depth, border_depth_2);
|
||||||
|
translate([border_margin-outside_border_width, 0, thickness-small_border_thickness+0.01])
|
||||||
|
cube(size=[small_border_width, height, small_border_thickness], center=false);
|
||||||
|
|
||||||
|
// lines
|
||||||
|
translate([width/2,border_margin+10,10.01])
|
||||||
|
carving_pattern(width-2*border_margin, height-2*border_margin-20, 10, 40);
|
||||||
|
|
||||||
|
translate([border_margin, border_margin, thickness-inner_depth])
|
||||||
|
cube(size=[width-2*border_margin, height-2*border_margin, 10], center=false);
|
||||||
|
|
||||||
|
// round inner edges
|
||||||
|
translate([width/2, height/2, thickness-round_radius])
|
||||||
|
rounded_square_cutter(width-2*border_margin, height-2*border_margin, round_radius);
|
||||||
|
|
||||||
|
// Custom small border
|
||||||
|
// translate([width-border_margin-small_border_width+outside_border_width, 0, thickness-small_border_thickness+0.01])
|
||||||
|
// cube(size=[small_border_width, height, small_border_thickness], center=false);
|
||||||
|
// translate([border_margin-border_depth_2, border_margin-border_depth_2, thickness-border_depth_2])
|
||||||
|
// cube(size=[width-2*border_margin+2*border_depth_2, height-2*border_margin+2*border_depth_2, border_depth_2+0.01], center=false);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module border(length, width, depth1, depth2, mill_dia){
|
||||||
|
points = [[0,depth2], [0,0], [width,0], [width, depth1], [width-mill_dia, depth1]];
|
||||||
|
rotate([-90,0,0])
|
||||||
|
linear_extrude(height=length){
|
||||||
|
polygon(points=points);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module outside_border(length, width, depth1, depth2) {
|
||||||
|
translate([0, length, 0])
|
||||||
|
rotate([0,0,180])
|
||||||
|
border(length, width, depth1, depth2, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
module borders(length_border, width_border, width, depth1, depth2){
|
||||||
|
union(){
|
||||||
|
translate([width_border-width, 0, 0])
|
||||||
|
border(length_border, width, depth1, depth2, mill_diameter);
|
||||||
|
translate([width, length_border, 0])
|
||||||
|
rotate([0,0,180])
|
||||||
|
border(length_border, width, depth1, depth2, mill_diameter);
|
||||||
|
translate([0, width, 0])
|
||||||
|
rotate([0,0,-90])
|
||||||
|
border(width_border, width, depth1, depth2, mill_diameter);
|
||||||
|
translate([width_border, length_border-width, 0])
|
||||||
|
rotate([0,0,90])
|
||||||
|
border(width_border, width, depth1, depth2, mill_diameter);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module outside_border_corner(length_border, width_border, width, depth1, depth2){
|
||||||
|
intersection(){
|
||||||
|
translate([-outside_border_width+0.01, length_border+outside_border_width, 0])
|
||||||
|
rotate([0,0,180])
|
||||||
|
outside_border(length_border+2*outside_border_width, outside_border_width, depth1, depth2);
|
||||||
|
translate([-outside_border_width, -outside_border_width+0.01, 0])
|
||||||
|
rotate([0,0,-90])
|
||||||
|
outside_border(width_border+2*outside_border_width, outside_border_width, depth1, depth2);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module outside_borders(length_border, width_border, width, depth1, depth2){
|
||||||
|
union(){
|
||||||
|
translate([width_border+outside_border_width-0.01, 0, 0])
|
||||||
|
outside_border(length_border, outside_border_width, depth1, outside_border_depth_2);
|
||||||
|
translate([-outside_border_width+0.01, length_border, 0])
|
||||||
|
rotate([0,0,180])
|
||||||
|
outside_border(length_border, outside_border_width, depth1, outside_border_depth_2);
|
||||||
|
translate([0, -outside_border_width+0.01, 0])
|
||||||
|
rotate([0,0,-90])
|
||||||
|
outside_border(width_border, outside_border_width, depth1, outside_border_depth_2);
|
||||||
|
translate([width_border, length_border+outside_border_width-0.01, 0])
|
||||||
|
rotate([0,0,90])
|
||||||
|
outside_border(width_border, outside_border_width, depth1, outside_border_depth_2);
|
||||||
|
|
||||||
|
// Now add the corners
|
||||||
|
outside_border_corner(length_border, width_border, width, depth1, outside_border_depth_2);
|
||||||
|
|
||||||
|
translate([width_border,0,0])
|
||||||
|
rotate([0,0,90])
|
||||||
|
outside_border_corner(length_border, width_border, width, depth1, outside_border_depth_2);
|
||||||
|
|
||||||
|
translate([width_border,length_border,0])
|
||||||
|
rotate([0,0,180])
|
||||||
|
outside_border_corner(length_border, width_border, width, depth1, outside_border_depth_2);
|
||||||
|
|
||||||
|
translate([0,length_border,0])
|
||||||
|
rotate([0,0,-90])
|
||||||
|
outside_border_corner(length_border, width_border, width, depth1, outside_border_depth_2);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module carving_face() {
|
||||||
|
difference(){
|
||||||
|
square(size=[10, 4], center=true);
|
||||||
|
|
||||||
|
translate([-4.5, -2, 0])
|
||||||
|
circle(r=4, $fn=50);
|
||||||
|
|
||||||
|
translate([4.5, -2, 0])
|
||||||
|
circle(r=4, $fn=50);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module carving_tip(){
|
||||||
|
translate([0,0,-2])
|
||||||
|
difference(){
|
||||||
|
rotate_extrude() {
|
||||||
|
difference(){
|
||||||
|
carving_face();
|
||||||
|
translate([0,-5,0])
|
||||||
|
square(size=[10, 10], center=false);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
translate([0,5,0])
|
||||||
|
cube(size=[10, 10, 10], center=true);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module carving(length) {
|
||||||
|
translate([0,length,0])
|
||||||
|
rotate([0,0,180])
|
||||||
|
carving_tip();
|
||||||
|
carving_tip();
|
||||||
|
translate([0,length,-2])
|
||||||
|
rotate([90,0,0])
|
||||||
|
linear_extrude(height=length){
|
||||||
|
carving_face();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module carving_pattern(width, height, inter_dist_small, inter_dist_large) {
|
||||||
|
max_iter = floor(width/(2*(inter_dist_small+inter_dist_large)))+1;
|
||||||
|
for(i=[-max_iter:max_iter]) {
|
||||||
|
translate([i*inter_dist_large,0,0])
|
||||||
|
union(){
|
||||||
|
translate([-inter_dist_small/2,0,0])
|
||||||
|
carving(height);
|
||||||
|
translate([inter_dist_small/2,0,0])
|
||||||
|
carving(height);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module round_cutter(radius){
|
||||||
|
difference(){
|
||||||
|
square(size=[radius, radius], center=false);
|
||||||
|
circle(r=radius, $fn=50);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module round_long_cutter(length, radius){
|
||||||
|
translate([0, length, 0])
|
||||||
|
rotate([90,0,0]){
|
||||||
|
linear_extrude(height=length)
|
||||||
|
round_cutter(radius);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module round_corner(radius){
|
||||||
|
rotate_extrude(angle=90) {
|
||||||
|
translate([-radius,0,0])
|
||||||
|
round_cutter(radius);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module rounded_cutter(length, radius) {
|
||||||
|
translate([0, -length/2, 0])
|
||||||
|
union(){
|
||||||
|
translate([radius, length, 0])
|
||||||
|
rotate([0,0,180])
|
||||||
|
round_long_cutter(length, radius);
|
||||||
|
rotate([0,0,90])
|
||||||
|
round_corner(radius);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module rounded_square_cutter(width, height, radius) {
|
||||||
|
union(){
|
||||||
|
translate([width/2, 0, 0])
|
||||||
|
rounded_cutter(height, radius);
|
||||||
|
|
||||||
|
translate([0, height/2, 0])
|
||||||
|
rotate([0,0,90])
|
||||||
|
rounded_cutter(width, radius);
|
||||||
|
|
||||||
|
translate([-width/2, 0, 0])
|
||||||
|
rotate([0,0,180])
|
||||||
|
rounded_cutter(height, radius);
|
||||||
|
|
||||||
|
translate([0, -height/2, 0])
|
||||||
|
rotate([0,0,270])
|
||||||
|
rounded_cutter(width, radius);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
color(c = [0.9, 0.9, 0.9]){
|
||||||
|
door();
|
||||||
|
}
|
||||||
|
// door();
|
||||||
|
|
||||||
|
// rotate([90,0,0])
|
||||||
|
// outside_border(500, border_width, border_depth, border_depth_2);
|
||||||
|
|
||||||
|
// outside_borders(height-2*border_margin, width-2*border_margin, border_width, border_depth, border_depth_2);
|
||||||
|
|
||||||
|
// borders(height, width, border_width, border_depth);
|
||||||
|
|
||||||
|
|
||||||
|
// carving_pattern(width, height, 20, 60);
|
||||||
|
|
||||||
|
// translate([width/2,border_margin,10])
|
||||||
|
// carving_pattern(width-2*border_margin, height-2*border_margin, 20, 80);
|
||||||
|
|
||||||
|
// carving_tip();
|
||||||
|
// carving(100);
|
||||||
|
|
||||||
|
// round_corner(5);
|
||||||
|
|
||||||
|
// round_long_cutter(100,5);
|
||||||
|
|
||||||
|
// rounded_cutter(200,5);
|
||||||
|
// rounded_square_cutter(200, 100, 5);
|
||||||
|
|
||||||
|
// translate([width/2, height/2, 0])
|
||||||
|
// rounded_square_cutter(width-2*border_margin, height-2*border_margin, 5);
|
||||||
72
bus_cabinet_side_panels.scad
Normal file
72
bus_cabinet_side_panels.scad
Normal file
@@ -0,0 +1,72 @@
|
|||||||
|
thickness = 18;
|
||||||
|
|
||||||
|
height = 1980;
|
||||||
|
width = 600;
|
||||||
|
|
||||||
|
step = 30;
|
||||||
|
|
||||||
|
points_panel_1_top = [120, 110, 100, 90, 75, 60, 50 ,30, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20];
|
||||||
|
points_panel_1_side = [120, 110, 100, 90, 75, 60, 50 ,30, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20];
|
||||||
|
|
||||||
|
|
||||||
|
module top_diff(width, points, step){
|
||||||
|
max_iter = floor(width/step);
|
||||||
|
mymax = max(points);
|
||||||
|
echo(max_iter);
|
||||||
|
poly = [
|
||||||
|
for(i = [0:max_iter]) [(i)*step, points[i]-mymax],
|
||||||
|
[width, 0.01],
|
||||||
|
[0, 0.01]
|
||||||
|
];
|
||||||
|
|
||||||
|
polygon(poly);
|
||||||
|
}
|
||||||
|
|
||||||
|
module side_diff(width, points, step){
|
||||||
|
max_iter = len(points)-1;
|
||||||
|
height = step*max_iter;
|
||||||
|
mymax = max(points);
|
||||||
|
echo(max_iter);
|
||||||
|
poly = [
|
||||||
|
for(i = [0:max_iter]) [width-points[i],-(i)*step],
|
||||||
|
[width + 0.01, -height],
|
||||||
|
[width + 0.01, 0]
|
||||||
|
];
|
||||||
|
|
||||||
|
polygon(poly);
|
||||||
|
}
|
||||||
|
|
||||||
|
module door_top(width, height, thickness, points, step){
|
||||||
|
difference(){
|
||||||
|
translate([0, -height, 0])
|
||||||
|
cube(size=[width, height, thickness], center=false);
|
||||||
|
|
||||||
|
translate([0,0,-0.005])
|
||||||
|
linear_extrude(thickness+0.01)
|
||||||
|
top_diff(width, points, step);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module door_side(width, height, thickness, points, step){
|
||||||
|
difference(){
|
||||||
|
translate([0, -height, 0])
|
||||||
|
cube(size=[width, height, thickness], center=false);
|
||||||
|
|
||||||
|
translate([0,0,-0.005])
|
||||||
|
linear_extrude(thickness+0.01)
|
||||||
|
side_diff(width, points, step);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module door_complete(width, height, thickness, points_top, points_side, step){
|
||||||
|
intersection(){
|
||||||
|
door_top(width, height, thickness, points_top, step);
|
||||||
|
door_side(width, height, thickness, points_side, step);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// top_diff(width, points_panel_1_top, step);
|
||||||
|
// door_top(width, height, thickness, points_panel_1_top, step);
|
||||||
|
// side_diff(width, points_panel_1_side, step);
|
||||||
|
// door_side(width, height, thickness, points_panel_1_side, step);
|
||||||
|
door_complete(width, height, thickness, points_panel_1_top, points_panel_1_side, step);
|
||||||
142
cnc_shoe_mount.scad
Normal file
142
cnc_shoe_mount.scad
Normal file
@@ -0,0 +1,142 @@
|
|||||||
|
// spindle params
|
||||||
|
inner_dia = 80;
|
||||||
|
dia_offset = 1;
|
||||||
|
|
||||||
|
// threaded insert params
|
||||||
|
insert_height = 7;
|
||||||
|
insert_dia = 5;
|
||||||
|
insert_bottom_dia = 4.2;
|
||||||
|
|
||||||
|
// magnet params
|
||||||
|
magnet_dia = 3;
|
||||||
|
magnet_height = 1;
|
||||||
|
magnet_number = 10;
|
||||||
|
|
||||||
|
// shape params
|
||||||
|
extra_offset = 4;
|
||||||
|
width = magnet_dia+extra_offset;
|
||||||
|
wedge_size = insert_dia + 3;
|
||||||
|
thickness = insert_dia + 3;
|
||||||
|
wedge_width = insert_height;
|
||||||
|
spacing_distance = 5;
|
||||||
|
|
||||||
|
$fn=100;
|
||||||
|
|
||||||
|
module ring(){
|
||||||
|
difference(){
|
||||||
|
linear_extrude(height=thickness, center=false, convexity=10, twist=0) {
|
||||||
|
difference(){
|
||||||
|
union(){
|
||||||
|
radius = (inner_dia+dia_offset)/2+width;
|
||||||
|
circle(r=radius);
|
||||||
|
|
||||||
|
squ_width = wedge_size+width;
|
||||||
|
squ_height = 2*wedge_width + spacing_distance + 1;
|
||||||
|
translate([-wedge_size/2-radius,0,0])
|
||||||
|
square(size=[squ_width, squ_height], center=true);
|
||||||
|
}
|
||||||
|
|
||||||
|
union(){
|
||||||
|
radius = (inner_dia+dia_offset)/2;
|
||||||
|
circle(r=radius);
|
||||||
|
|
||||||
|
squ_width = wedge_size+width+20;
|
||||||
|
squ_height = spacing_distance + 1;
|
||||||
|
translate([-wedge_size/2-radius,0,0])
|
||||||
|
square(size=[squ_width, squ_height], center=true);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
for(i = [0:magnet_number]){
|
||||||
|
rotate([0,0,i*36])
|
||||||
|
translate([0, (inner_dia+dia_offset)/2+width/2-0.5, -0.01])
|
||||||
|
cube(size=[15, 5, 3], center=true);
|
||||||
|
}
|
||||||
|
|
||||||
|
// threaded insert hole
|
||||||
|
translate([-(inner_dia+dia_offset)/2-width-wedge_size/1.5, (spacing_distance + 1)/2-0.005, thickness/2])
|
||||||
|
threaded_insert();
|
||||||
|
|
||||||
|
// bolt hole
|
||||||
|
translate([-(inner_dia+dia_offset)/2-width-wedge_size/1.5, -(spacing_distance + 1)/2+0.005, thickness/2])
|
||||||
|
rotate([90,0,0])
|
||||||
|
cylinder(h=insert_height+0.01, r=3.5/2, center=false);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module threaded_insert(){
|
||||||
|
rotate([-90,0,0])
|
||||||
|
cylinder(h=insert_height+0.01, r1=insert_bottom_dia/2, r2=insert_dia/2, center=false);
|
||||||
|
}
|
||||||
|
|
||||||
|
// vacuum params
|
||||||
|
vacuum_pipe_dia_start = 32;
|
||||||
|
vacuum_pipe_dia_end = 30;
|
||||||
|
pipe_thickness = 2;
|
||||||
|
pipe_length = 50;
|
||||||
|
rotation_angle = 60;
|
||||||
|
|
||||||
|
pipe_height = 50;
|
||||||
|
|
||||||
|
module pipe(){
|
||||||
|
// hollow pipe for vacuum cleaner
|
||||||
|
rotate([0,rotation_angle,0])
|
||||||
|
difference(){
|
||||||
|
cylinder(h=pipe_length, r1=vacuum_pipe_dia_end/2+pipe_thickness, r2=vacuum_pipe_dia_start/2+pipe_thickness, center=false);
|
||||||
|
translate([0,0,-0.005])
|
||||||
|
cylinder(h=pipe_length+0.01, r1=vacuum_pipe_dia_end/2, r2=vacuum_pipe_dia_start/2, center=false);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module vacuum_vent() {
|
||||||
|
rotate([180,0,0])
|
||||||
|
difference(){
|
||||||
|
linear_extrude(height=pipe_height, center=false, convexity=10, twist=0) {
|
||||||
|
difference(){
|
||||||
|
union(){
|
||||||
|
radius = (inner_dia+dia_offset)/2+width;
|
||||||
|
circle(r=radius);
|
||||||
|
}
|
||||||
|
|
||||||
|
union(){
|
||||||
|
radius = (inner_dia+dia_offset)/2+2;
|
||||||
|
circle(r=radius);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
for(i = [0:magnet_number]){
|
||||||
|
rotate([0,0,i*36])
|
||||||
|
translate([0, (inner_dia+dia_offset)/2+width/2, -0.01])
|
||||||
|
cylinder(r=(magnet_dia+0.5)/2, h=magnet_height+0.5, center=false);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Ring for metal
|
||||||
|
translate([0,0,-8])
|
||||||
|
cylinder(r=(inner_dia+dia_offset)/2+6, h=10, center=false);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
ring();
|
||||||
|
// pipe_x = cos(rotation_angle)*(vacuum_pipe_dia_end+pipe_thickness)/2;
|
||||||
|
// difference(){
|
||||||
|
// vacuum_vent();
|
||||||
|
// translate([-pipe_x+(inner_dia+dia_offset)/2+2,0,-30])
|
||||||
|
// hull(){pipe();}
|
||||||
|
|
||||||
|
// // threaded insert holes
|
||||||
|
// for(i = [0:magnet_number]){
|
||||||
|
// rotate([0,0,i*36])
|
||||||
|
// translate([0, (inner_dia+dia_offset)/2+width+0.9-7, -pipe_height+5])
|
||||||
|
// rotate([0,0,0])
|
||||||
|
// threaded_insert();
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// difference(){
|
||||||
|
// translate([-pipe_x+(inner_dia+dia_offset)/2+2,0,-30])
|
||||||
|
// pipe();
|
||||||
|
// translate([0,0,-pipe_height/2])
|
||||||
|
// cylinder(r=(inner_dia+dia_offset)/2+2, h=pipe_height, center=true);
|
||||||
|
// }
|
||||||
26
pencil_hanger.scad
Normal file
26
pencil_hanger.scad
Normal file
@@ -0,0 +1,26 @@
|
|||||||
|
inner_dia = 17;
|
||||||
|
thickness = 1.6;
|
||||||
|
outer_dia = inner_dia + 2*thickness;
|
||||||
|
|
||||||
|
module ring(){
|
||||||
|
translate([0,-outer_dia/2,0])
|
||||||
|
linear_extrude(height=2)
|
||||||
|
difference(){
|
||||||
|
union(){
|
||||||
|
circle(r=inner_dia/2+thickness);
|
||||||
|
translate([-outer_dia/2,0,0])
|
||||||
|
square(size=[outer_dia, outer_dia/2], center=false);
|
||||||
|
}
|
||||||
|
circle(r=inner_dia/2);
|
||||||
|
|
||||||
|
squ_height = 15;
|
||||||
|
translate([0,-squ_height/2,0])
|
||||||
|
square(size=[inner_dia-thickness, squ_height], center=true);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
union(){
|
||||||
|
ring();
|
||||||
|
translate([0,thickness/2,0])
|
||||||
|
cube(size=[outer_dia, thickness, outer_dia], center=true);
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user