Skip to content

hinge_box.scad

pinkfish edited this page Mar 20, 2026 · 7 revisions

LibFile: hinge_box.scad

This file has all the modules needed to generate a hinge box.

To use, add the following lines to the beginning of your file:

include <boardgame_toolkit.scad>

File Contents

  1. Section: Hinges

Section: Hinges

Module: HingeCone()

Topics: Hinges

Usage: HingeCone(6, 0.5)

Description:

Makes the hinge cone for use in hinges, this makes a 45 degree cone with an inner/outer that can be joined with other pieces to make a hinge.

Arguments:

By Position What it does
r radius of the cone
offset how far inside the cone to leave space

Example 1:

HingeCone() Example 1
include <boardgame_toolkit.scad>
HingeCone(6, 0.5);




Module: HingeLine()

Topics: Hinges

Description:

Makes a hinge setup in a straight line, has pieces that stick out each side wide enough to hook onto edges within 0.5 of the side.

Arguments:

By Position What it does
length length of the line to hinge
diameter diameter of the hinge itself
offset how much of a space to leave on the conical holes for the hinge
spin how much to rotate one of the legs (default 0)

Example 1:

HingeLine() Example 1
include <boardgame_toolkit.scad>
HingeLine(length = 60, diameter = 6, offset = 0.5);




Module: HingeLineWithSpacingAndNum()

Topics: Hinges

Description:

Makes a hinge setup in a straight line, has pieces that stick out each side wide enough to hook onto edges within 0.5 of the side.

Arguments:

By Position What it does
num number of hinge locations
spacing spacing between hinge spots
diameter diameter of the hinge itself
offset how much of a space to leave on the conical holes for the hinge
spin how much to rotate one of the legs (default 0)

Example 1:

HingeLineWithSpacingAndNum() Example 1
include <boardgame_toolkit.scad>
HingeLineWithSpacingAndNum(num = 10, spacing = 6, diameter = 6, offset = 0.5);

Module: InsetHinge()

Topics: Hinges

Usage: InsetHinge(100, 20, 6, 0.5);

Description:

Create a hinge that works and moves in the middle. Centers the pices back on the line with the middle being the length/2, width2/2 and the diameter/2, the legs stick down a little to make it easier to join onto other parts of the system.

Arguments:

By Position What it does
length length of the hinge (outside)
width width of the middle pice (outside)
diameter diameter of the round piece in the middle.
offset how much to offset the middle sections, 0.5 is usually good for this

Example 1:

InsetHinge() Example 1
include <boardgame_toolkit.scad>
InsetHinge(length = 100, width = 20, diameter = 6, offset = 0.5);

Module: HingeBoxLidLabel()

Usage: HingeBoxLidLabel(size=[100, 50], text\_str="Cards");

Description:

Makes a lid for one side of a hinge box with a label and pattern. This uses the $inner_width and $inner_length from the main hinge box creation.

Arguments:

By Position What it does
text_str the string to use for the label
lid_boundary boundary around the outside for the lid (default 10)
wall_thickness thickness of the walls (default default_wall_thickness)
layout_width the width of the layout pieces (default default_lid_layout_width)
aspect_ratio the aspect ratio (multiple by dy) (default 1.0)
lid_thickness thickness of the lid (default default_lid_thickness)
lid_rounding how much rounding on the edge of the lid (default undef)
lid_inner_rounding how much rounding on the inside (default undef)
material_colour the colour of the material in the box (default default_material_colour)
size_spacing extra spacing to apply between pieces (default default_slicing_layer_height)
label_options options for the label (default undef)
shape_options options for the shape (default undef)

Example 1:

HingeBoxLidLabel() Example 1
include <boardgame_toolkit.scad>
$inner_width = 100;
$inner_length = 50;
HingeBoxLidLabel(text_str="Cards");




Module: MakeBoxWithInsetHinge()

Topics: Hinges, HingeBox

Usage: MakeBoxAndLidWithInsetHinge(size=[100, 50, 20]);

Description:

Makes a box with an inset hinge on the side, this is a print in place box with a hinge that will make lid hinge onto the top, it is the same height on both sides, child 1 is in the base, child 2 is in the lid and child 3+ are lid pieces. Inside the children of the box you can use the $inner_height , $inner_width, $inner_length = length variables to deal with the box sizes.

Arguments:

By Position What it does
size outside size of the box [width, length, height]
hinge_diameter diameter of the hinge (default 6)
wall_thickness thickness of the walls (default default_wall_thickness)
floor_thickness thickness of the floor (default default_floor_thickness)
hinge_offset offset for the hinge mechanism (default 0.5)
gap gap between the two box halves (default 1)
side_gap gap on the sides of the hinge (default 3)
print_layer_height height of the print layers (default 0.2)
lid_thickness thickness of the lid (default default_lid_thickness)
prism_width width of the prism for the tab (default 0.75)
tab_offset offset for the tab (default 0.2)
tab_length length of the tab (default 10)
tab_height height of the tab (default 6)
material_colour the colour of the material in the box (default default_material_colour)
spacing wiggle room between moving parts (default 0.2)

Example 1:

MakeBoxWithInsetHinge() Example 1
include <boardgame_toolkit.scad>
MakeBoxAndLidWithInsetHinge(size=[100, 50, 20]);




Clone this wiki locally