Skip to content

Commit

Permalink
Merge pull request #1 from mguentner/optional_lock
Browse files Browse the repository at this point in the history
make lock optional
  • Loading branch information
9R authored Sep 17, 2024
2 parents fd0dee6 + 5abf23c commit 41afca1
Showing 1 changed file with 12 additions and 9 deletions.
21 changes: 12 additions & 9 deletions ScadBox.scad
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@ RIM = true;
// Internal or External Lock
INTERNAL_LOCK = false;

// Whether to make a lock at all
LOCK = false;

// Container Length in mm
BOX_L_OUTER = 165; //[50:5:300]

Expand Down Expand Up @@ -285,22 +288,22 @@ if (PART == "container"){
division(DIVISIONS_L, BOX_W, BOX_L);
};
};

//make space for locking mechanism
lock_cutout(fixture_offset);
mirror ([0,1,0]){
lock_cutout(fixture_offset);
};
if (LOCK) {
//make space for locking mechanism
lock_cutout(fixture_offset);
mirror ([0,1,0]){
lock_cutout(fixture_offset);
};
}
};

//add lock fixtures
if (INTERNAL_LOCK) {
if (LOCK && INTERNAL_LOCK) {
lock_internal();
mirror([0,1,0]) {
lock_internal();
};
}
else {
} else if (LOCK && !INTERNAL_LOCK) {
for (i = fixture_coordinates) {
translate (i) lock_fixture();
}
Expand Down

0 comments on commit 41afca1

Please sign in to comment.