Compare commits

...

2 Commits

Author SHA1 Message Date
Matt McWilliams c6b8592490 Enlarge case and add bolt 2023-03-15 21:35:35 -04:00
Matt McWilliams f67e011d5e Canon EOS M50 mount design 2023-03-15 21:35:23 -04:00
2 changed files with 85 additions and 19 deletions

View File

@ -4,6 +4,8 @@ BaseZ = 10; //debug
BaseX = 91.4; BaseX = 91.4;
BaseY = 97.6; BaseY = 97.6;
function hypotenuese(X) = sqrt(pow(X, 2) + pow(X, 2));
module base_void (pos = [0, 0, 0]) { module base_void (pos = [0, 0, 0]) {
$fn = 50; $fn = 50;
D = 9.5; D = 9.5;
@ -31,9 +33,9 @@ module base (pos = [0, 0, 0]) {
} }
} }
module sensor (pos = [0, 0, 0]) { module sensor (pos = [0, 0, 0], LENGTH = 1) {
X = 22.3; X = 22.3;
Y = 1; Y = LENGTH;
Z = 14.9; Z = 14.9;
translate(pos) { translate(pos) {
cube([X, Y, Z], center = true); cube([X, Y, Z], center = true);
@ -57,7 +59,7 @@ module canon_rebel_t3i (pos = [0, 0, 0]) {
color("azure", 0.25) { color("azure", 0.25) {
cage_cube(X, Y, Z); cage_cube(X, Y, Z);
} }
color("green") sensor([0, 0, 0]); color("green") sensor([0, 0, 0]); //160
} }
} }
@ -83,8 +85,38 @@ module canon_m_50 (pos = [0, 0, 0]) {
} }
} }
color("red") base(); module canon_m_50_mount () {
canon_rebel_t3i_mount([0, 20, 33]); X = 60;
canon_rebel_t3i([0, 20+52.5, 66 + (99.5/2)]); Y = 60;
Z = 71.75;
SPACING = 40;
ACCESS = 15;
DIAG = hypotenuese(ACCESS);
translate([0, 0, Z/2]) {
difference () {
cube([X, Y, Z], center = true);
cube([X + 1, Y-40, Z-20], center = true);
cube([X + 1, Y-20, Z-40], center = true);
canon_m_50([0, 0, 120]); //void around camera bolt
translate([0, 0, (Z/2) - 20]) cylinder(r = R(30), h = 20, center = true, $fn = 100);
//void for camera bolt
translate([0, 0, (Z/2)]) cylinder(r = R(5), h = 20 + 1, center = true, $fn = 60);
//void for base bolts
//translate([0, SPACING/2, -(Z/2) + 10]) cylinder(r = R(9), h = 40, center = true, $fn = 60);
//translate([0, -SPACING/2, -(Z/2) + 10]) cylinder(r = R(9), h = 40, center = true, $fn = 60);
//bolt access
//translate([0, 0, -10]) rotate([0, 45, 0]) cube([ACCESS, Y + 1, ACCESS], center = true);
//translate([0, 0, -10 - (ACCESS/2) + (10/4)])cube([DIAG, Y + 1, 10], center = true);
}
}
}
//color("red") base();
//canon_rebel_t3i_mount([0, 20, 33]);
//canon_rebel_t3i([0, 20+52.5, 66 + (99.5/2)]);
//canon_m_50([0, 0, 115.75]);
canon_m_50_mount();

View File

@ -2,20 +2,22 @@ include <./arduino.scad>;
include <./common/common.scad>; include <./common/common.scad>;
DEBUG = false; DEBUG = false;
PART = "case_bottomx"; PART = "case_bottom";
CaseX = 40; CaseX = 40;
CaseY = 75; CaseY = 85;
CaseZ = 30; CaseZ = 35;
CaseD = 8; CaseD = 8;
CaseSplitZ = 25; CaseSplitZ = 30;
ESP32Position = [0, -7, -5]; ESP32Position = [0, -7-5, -5];
ESP32Size = [25.85, 53.8, 1.5]; ESP32Size = [25.85, 53.8, 1.5];
ButtonPosition = [0, CaseY/2, 3]; ButtonPosition = [9, CaseY/2, 0];
LEDPosition1 = [10, CaseY/2, 3]; LEDPosition1 = [-3, CaseY/2, 0];
LEDPosition2 = [-10, CaseY/2, 3]; LEDPosition2 = [-11, CaseY/2, 0];
BoltY = 25;
module pin_debug (pos = [0, 0, 0]) { module pin_debug (pos = [0, 0, 0]) {
translate(pos) cube([.6, .6, 6.26], center = true); translate(pos) cube([.6, .6, 6.26], center = true);
@ -50,8 +52,11 @@ module esp32_debug () {
module debug () { module debug () {
//translate(ESP32Position) rotate([180, 0, 0]) esp32_debug(); //translate(ESP32Position) rotate([180, 0, 0]) esp32_debug();
difference () { difference () {
case_bottom(); union () {
//translate([CaseX / 2, 0, 0]) cube([CaseX, CaseY + 1, CaseZ + 1], center = true); case_bottom();
translate([0, 0, 1]) rotate([0, 0, 0]) color("red") case_top();
}
translate([-CaseX / 2, 0, 0]) cube([CaseX, CaseY + 1, 100], center = true);
} }
} }
@ -76,7 +81,7 @@ module esp32_mount (pos = [0, 0, 0]) {
Y = ESP32Size[1]; Y = ESP32Size[1];
Z = 2; Z = 2;
translate([pos[0], pos[1], pos[2]-5]) difference () { translate([pos[0], pos[1], pos[2]-5]) difference () {
cube([X+3, Y+3, 10], center = true); cube([X+4, Y+4, 10], center = true);
translate([0, 0, (10/2)-(2/2)+0.01]) cube([X, Y, Z], center = true); translate([0, 0, (10/2)-(2/2)+0.01]) cube([X, Y, Z], center = true);
translate([0, 0, 0]) cube([X-1, Y-1, 10], center = true); translate([0, 0, 0]) cube([X-1, Y-1, 10], center = true);
//micro usb //micro usb
@ -96,10 +101,20 @@ module LED_void (pos = [0, 0, 0]) {
translate(pos) rotate([90, 0, 0]) cylinder(r = R(D), h = 10, center = true, $fn = 60); translate(pos) rotate([90, 0, 0]) cylinder(r = R(D), h = 10, center = true, $fn = 60);
} }
module bolt_void (pos = [0, 0, 0], Z = 20, pad = 0) {
translate(pos) cylinder(r = R(3.25 + pad), h = Z, center = true, $fn = 30);
}
module bolt_plug (pos = [0, 0, 0], pad = 0) {
translate(pos) cylinder(r = R(8 + pad), h = 3.5, center = true, $fn = 60);
}
module case_bottom () { module case_bottom () {
difference () { difference () {
case_shell(); union () {
case_shell();
bolt_plug([0, BoltY, -(CaseZ/2)+4]);
}
translate([0, 0, CaseSplitZ]) cube([CaseX + 1, CaseY + 1, CaseZ],center = true); translate([0, 0, CaseSplitZ]) cube([CaseX + 1, CaseY + 1, CaseZ],center = true);
//micro usb //micro usb
translate([0, -(CaseY/2), -7.8]) cube([9, 7, 4], center = true); translate([0, -(CaseY/2), -7.8]) cube([9, 7, 4], center = true);
@ -109,16 +124,35 @@ module case_bottom () {
//LEDS //LEDS
LED_void(LEDPosition1); LED_void(LEDPosition1);
LED_void(LEDPosition2); LED_void(LEDPosition2);
//bolt
translate([0, BoltY, -(CaseZ/2)+(3.5/2)-0.01]) cylinder(r = R(5.6), h = 3.5, center = true, $fn = 30);
bolt_void([0, BoltY, -(CaseZ/2)], 20);
} }
esp32_mount(ESP32Position); esp32_mount(ESP32Position);
} }
module case_top () { module case_top () {
$fn = 50;
difference () { difference () {
case_shell(); case_shell();
translate([0, 0, CaseSplitZ-CaseZ]) cube([CaseX + 1, CaseY + 1, CaseZ],center = true); translate([0, 0, CaseSplitZ-CaseZ]) cube([CaseX + 1, CaseY + 1, CaseZ],center = true);
bolt_void([0, BoltY, 0], CaseZ - 6 + 1);
translate([2.5, -28, 17]) rotate([0, 0, 90]) scale([0.5, 0.5, 1]) linear_extrude(4) {
text("Canon EOS M50", font = "Liberation Sans:style=Bold Italic");
}
} }
translate([0, 0, 12]) difference () {
rounded_cube([CaseX - 6.1, CaseY - 6.1, 4], d = 6, center = true);
rounded_cube([CaseX - 8, CaseY - 8, 4 + 1], d = 5, center = true);
}
difference () {
translate([0, BoltY, 1]) cube([10, 10, CaseZ - 6 - 1], center = true);
bolt_void([0, BoltY, -4], CaseZ - 6 + 1, -.4);
bolt_plug([0, BoltY, -(CaseZ/2)+4], 0.2);
}
} }
if (PART == "case_bottom") { if (PART == "case_bottom") {