Most joinery techniques require that each part be extended into the other and the stock which forms the joints be removed so that the two parts fit together. For simple and rough or rustic projects, it may be appropriate to simply cut the parts to size and mate them using adhesives and hardware. A classic example of this approach is a bird house for wrens:
Like all other projects, it begins with a set of parameters:
Usually designed around the dimensions of the stock used:
This requirement suggests a technique which will address the inability to parse an object w/in OpenSCAD to determine its dimensions:
Create a module, the output of which may be plugged in wherever a given set of dimensions is used.
An optional improvement here is to allow inputting the desired axis (two is easiest, but more may be done) as shown in:
The BlockSCAD link for the wren birdhouse is:
It includes a matrix for laying out the parts for cutting:
The parts layout may be easily prepared for exporting as a DXF or SVG using the projection() command as previously shown.
It is frequently necessary to refer to the dimensions of parts while working. While these could be stored as variables, it may be more expressive to calculate them using a module which can then return either width or depth based on a parameter:
Then it is simply a matter of cutting out the parts:
and assembling with a few nails and a hinge and associated hardware:
Files for this size are available at: https://community.carbide3d.com/t/a-birdhouse-for-wrens-but-parametric-so-adjustable/32161/11