Fix clearances after first platform print

This commit is contained in:
Dejvino 2021-01-21 21:14:44 +01:00
parent 09336f1d0d
commit 3e5afb4ebd
2 changed files with 40 additions and 13 deletions

View File

@ -1,6 +1,6 @@
include <export.scad> include <export.scad>
//export=MODEL_PLATFORM_HARNESS; //export=MODEL_PLATFORM_HARNESS;
//export=MODEL_PLATFORM_STRAP; export=MODEL_PLATFORM_STRAP;
// dependency: https://github.com/revarbat/BOSL // dependency: https://github.com/revarbat/BOSL
include <BOSL/constants.scad> include <BOSL/constants.scad>
@ -53,12 +53,14 @@ module lock_arm() {
translate([joiner_size.x/2, joiner_size.y/2, -joiner_size.z/2 + size.z/2]) cube(joiner_size, center=true); translate([joiner_size.x/2, joiner_size.y/2, -joiner_size.z/2 + size.z/2]) cube(joiner_size, center=true);
} }
module lock_mechanism_button(groove=false) { module lock_mechanism_button(groove=false) {
button_size=groove button_size=get_platform_lock_button_profile(groove);
?[10,5] size=get_platform_lock_button_size(groove);
:[7,4.5]; translate(get_platform_lock_button_pos())
size=[button_size.x, get_platform_wall()*7, button_size.y]; left(groove?1:0)
translate([get_platform_lock_pin_size().x*1.5, -get_platform_size().y/2+size.y*1.3, -get_platform_size().z/2]) difference() {
cube(size, center=true); cube(size, center=true);
up(size.z/2 + (groove?0.5:0)) back(3) cube(size, center=true);
}
} }
module lock_buttons_cutout() { module lock_buttons_cutout() {
module cutout_side(groove) { module cutout_side(groove) {
@ -108,6 +110,12 @@ module platform(base) {
top_size=get_platform_top_size(); top_size=get_platform_top_size();
top=!base; top=!base;
module base_platform_cutout_for_top() {
base_top_diff=[base_size.x-top_size.x, base_size.y-top_size.y];
guiding=0.4;
translate(get_platform_top_pos()) down(top_size.z/2) prismoid(size1=[top_size.x,top_size.y], size2=[top_size.x+base_top_diff.x*guiding,top_size.y+base_top_diff.y*guiding], h=top_size.z);
lock_buttons_cutout();
}
module base_platform() { module base_platform() {
module base_platform_core() { module base_platform_core() {
braced_thinning_wall(h=size.y, l=size.x, thick=size.z, wall=0, strut=wall, orient=ORIENT_X_90); braced_thinning_wall(h=size.y, l=size.x, thick=size.z, wall=0, strut=wall, orient=ORIENT_X_90);
@ -115,8 +123,7 @@ module platform(base) {
difference() { difference() {
base_platform_core(); base_platform_core();
translate(get_platform_top_pos()) down(top_size.z/2) prismoid(size1=[top_size.x,top_size.y], size2=[base_size.x-2,base_size.y-2], h=top_size.z); base_platform_cutout_for_top();
lock_buttons_cutout();
} }
} }
module top_platform() { module top_platform() {
@ -126,8 +133,11 @@ module platform(base) {
module strap_connectors() { module strap_connectors() {
//down(size.z/2) //down(size.z/2)
foreach_platform_strap_connector() { difference() {
link_connector_pin(); foreach_platform_strap_connector() {
link_connector_pin();
}
base_platform_cutout_for_top();
} }
} }
@ -151,6 +161,11 @@ module model_platform_strap() {
platform(base=true); platform(base=true);
} }
// Validation:
/*intersection() {
model_platform_harness();
model_platform_strap();
}*/
// Export: // Export:
difference() { difference() {
union() { union() {

View File

@ -19,5 +19,17 @@ function get_platform_strap_connector_offset() = [
]; ];
function get_platform_lock_pin_size() = [20, 4, 3]; function get_platform_lock_pin_size() = [20, 4, 3];
function get_platform_lock_arm_size() = [65, 2, 3]; function get_platform_lock_arm_size() = [46, 2, 3];
function get_platform_lock_pin_pos() = [-20, -get_platform_top_size().y/2 + get_platform_wall()*4 + 1, get_platform_top_size().z/2]; function get_platform_lock_pin_pos() = [-get_platform_lock_pin_size().x/2, -get_platform_top_size().y/2 + get_platform_wall()*4 + 1, get_platform_top_size().z/2];
function get_platform_lock_button_profile(groove) = groove ? [10, 5] : [7, 4.5];
function get_platform_lock_button_size(groove) = [
get_platform_lock_button_profile(groove).x,
get_platform_size().y * 0.25 + get_platform_lock_pin_size().y + 2,
get_platform_lock_button_profile(groove).y
];
function get_platform_lock_button_pos() = [
get_platform_lock_pin_size().x/2 + 5,
-get_platform_lock_button_size(false).y/2,
-get_platform_size().z/2
];