Move common leg translation/rotation into module

This commit is contained in:
Joel Ebel 2018-05-21 23:43:58 -04:00
parent cc44b9dabd
commit f3ac692891

View File

@ -256,6 +256,8 @@ module Decorations() {
Produces a single box fixation leg with screw hole. Produces a single box fixation leg with screw hole.
*/ */
module leg() { module leg() {
translate([0, Thick, Height/2]) {
rotate([90, 0, 180]) {
difference() { difference() {
linear_extrude(Thick) { linear_extrude(Thick) {
difference() { difference() {
@ -274,6 +276,8 @@ module leg() {
cube([8*ScrewHole,4*ScrewHole,OuterMargin*2]); cube([8*ScrewHole,4*ScrewHole,OuterMargin*2]);
} }
} }
}
}
} }
@ -282,16 +286,12 @@ module leg() {
This module produces the wall fixation box legs. This module produces the wall fixation box legs.
*/ */
module Legs() { module Legs() {
translate([MountInset, Thick, Height/2]) { translate([MountInset, 0, 0]) {
rotate([90, 0, 180]) {
leg(); leg();
} }
} translate([Length - MountInset, 0, 0]) {
translate([Length - MountInset, Thick, Height/2]) {
rotate([90, 0, 180]) {
leg(); leg();
} }
}
} }