2020-02-23 18:15:25 +00:00
|
|
|
//
|
2020-02-26 19:43:02 +00:00
|
|
|
// NopSCADlib Copyright Chris Palmer 2020
|
2020-02-23 18:15:25 +00:00
|
|
|
// nop.head@gmail.com
|
|
|
|
// hydraraptor.blogspot.com
|
|
|
|
//
|
|
|
|
// This file is part of NopSCADlib.
|
|
|
|
//
|
|
|
|
// NopSCADlib is free software: you can redistribute it and/or modify it under the terms of the
|
|
|
|
// GNU General Public License as published by the Free Software Foundation, either version 3 of
|
|
|
|
// the License, or (at your option) any later version.
|
|
|
|
//
|
|
|
|
// NopSCADlib is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
|
|
|
// without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
|
|
// See the GNU General Public License for more details.
|
|
|
|
//
|
|
|
|
// You should have received a copy of the GNU General Public License along with NopSCADlib.
|
|
|
|
// If not, see <https://www.gnu.org/licenses/>.
|
|
|
|
//
|
2021-09-03 09:23:24 +01:00
|
|
|
include <../core.scad>
|
2020-02-23 18:15:25 +00:00
|
|
|
|
|
|
|
include <../vitamins/extrusions.scad>
|
2021-09-03 09:23:24 +01:00
|
|
|
include <../vitamins/extrusion_brackets.scad>
|
2020-02-23 18:15:25 +00:00
|
|
|
include <../vitamins/washers.scad>
|
|
|
|
include <../vitamins/nuts.scad>
|
|
|
|
|
2021-09-05 10:24:42 +01:00
|
|
|
module inner_bracket_test(bracket, backwards = false)
|
2021-09-03 09:23:24 +01:00
|
|
|
rotate([90, 0, 180]) {
|
2021-09-05 10:24:42 +01:00
|
|
|
extrusion = extrusion_inner_corner_bracket_extrusion(bracket);
|
2021-09-03 09:23:24 +01:00
|
|
|
eWidth = extrusion_width(extrusion);
|
|
|
|
size = extrusion_inner_corner_bracket_size(bracket);
|
|
|
|
tnut = extrusion_inner_corner_bracket_tnut(bracket);
|
|
|
|
|
|
|
|
translate([backwards ? -eWidth : 0, 0])
|
|
|
|
extrusion_inner_corner_bracket(bracket, backwards = backwards);
|
|
|
|
|
|
|
|
translate([-eWidth / 2, 0])
|
|
|
|
rotate([-90, 0, 0])
|
2021-09-05 10:24:42 +01:00
|
|
|
extrusion(extrusion, size.x - nut_thickness(tnut) - extrusion_tab_thickness(extrusion), false, cornerHole = eWidth > 20);
|
2021-09-03 09:23:24 +01:00
|
|
|
|
|
|
|
translate([-eWidth, -eWidth / 2])
|
|
|
|
rotate([0, 90, 0])
|
2021-09-05 10:24:42 +01:00
|
|
|
extrusion(extrusion, eWidth + size.y - nut_thickness(tnut) - extrusion_tab_thickness(extrusion), false, cornerHole = eWidth > 20);
|
2021-09-03 09:23:24 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
2021-09-05 10:24:42 +01:00
|
|
|
module bracket_test(bracket)
|
2021-09-03 09:23:24 +01:00
|
|
|
rotate([90, 0, 180]) {
|
2021-09-05 10:24:42 +01:00
|
|
|
extrusion = extrusion_corner_bracket_extrusion(bracket);
|
2021-09-03 09:23:24 +01:00
|
|
|
eWidth = extrusion_width(extrusion);
|
|
|
|
size = extrusion_corner_bracket_size(bracket);
|
|
|
|
|
|
|
|
extrusion_corner_bracket_assembly(bracket);
|
|
|
|
|
|
|
|
translate([-eWidth / 2, 0])
|
|
|
|
rotate([-90, 0, 0])
|
2021-09-05 10:24:42 +01:00
|
|
|
extrusion(extrusion, size.y, false, cornerHole = eWidth > 20);
|
2021-09-03 09:23:24 +01:00
|
|
|
|
|
|
|
translate([-eWidth, -eWidth / 2])
|
|
|
|
rotate([0, 90, 0])
|
2021-09-05 10:24:42 +01:00
|
|
|
extrusion(extrusion, eWidth + size.x, false, cornerHole = eWidth > 20);
|
2021-09-03 09:23:24 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
2020-02-27 17:55:03 +00:00
|
|
|
module extrusion_brackets(examples = false) {
|
2020-02-25 22:23:44 +00:00
|
|
|
extrusion_inner_corner_bracket(E20_inner_corner_bracket);
|
2020-02-23 18:15:25 +00:00
|
|
|
|
|
|
|
translate([30, 0])
|
2020-02-25 22:23:44 +00:00
|
|
|
extrusion_inner_corner_bracket(E20_inner_corner_bracket, grub_screws = false);
|
2020-02-23 18:15:25 +00:00
|
|
|
|
|
|
|
translate([60, 0])
|
2020-02-25 22:23:44 +00:00
|
|
|
extrusion_corner_bracket_assembly(E20_corner_bracket);
|
2020-02-23 18:15:25 +00:00
|
|
|
|
2021-09-03 09:23:24 +01:00
|
|
|
translate([110, 0])
|
|
|
|
extrusion_inner_corner_bracket(E40_inner_corner_bracket);
|
2020-02-23 18:15:25 +00:00
|
|
|
|
2021-09-03 09:23:24 +01:00
|
|
|
translate([140, 0])
|
|
|
|
extrusion_corner_bracket_assembly(E40_corner_bracket);
|
2020-02-23 18:15:25 +00:00
|
|
|
|
2021-09-03 09:23:24 +01:00
|
|
|
if(examples) {
|
|
|
|
translate([20, 50, 10])
|
2021-09-05 10:24:42 +01:00
|
|
|
inner_bracket_test(E20_inner_corner_bracket, true);
|
2020-02-27 17:55:03 +00:00
|
|
|
|
2021-09-03 09:23:24 +01:00
|
|
|
translate([20, 80, 10])
|
2021-09-05 10:24:42 +01:00
|
|
|
inner_bracket_test(E20_inner_corner_bracket);
|
2020-02-27 17:55:03 +00:00
|
|
|
|
2021-09-03 09:23:24 +01:00
|
|
|
translate([20, 120, 10])
|
2021-09-05 10:24:42 +01:00
|
|
|
bracket_test(E20_corner_bracket);
|
2020-02-27 17:55:03 +00:00
|
|
|
|
2021-09-03 09:23:24 +01:00
|
|
|
translate([100, 70, 10])
|
2021-09-05 10:24:42 +01:00
|
|
|
inner_bracket_test(E40_inner_corner_bracket);
|
2020-02-27 17:55:03 +00:00
|
|
|
|
2021-09-03 09:23:24 +01:00
|
|
|
translate([100, 130, 10])
|
2021-09-05 10:24:42 +01:00
|
|
|
bracket_test(E40_corner_bracket);
|
2020-02-23 18:15:25 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
if($preview)
|
2021-09-03 09:23:24 +01:00
|
|
|
let($show_threads = true)
|
|
|
|
extrusion_brackets(true);
|