Browse over 10,000 Electronics Projects using the Page Numbering provided at the bottom of each Page.

Discovering OpenSCAD – part 1: basic functions

Discovering OpenSCAD – part 1: basic functions

Who prints 3D objects needs a 3D modeling and editing software to create and edit files; a good example is OpenSCAD, that is also a nice resource to modify and process most of Thingiverse files.


With “3D modeling” we mean the design of a three-dimensional shape, the generation of the model and its representation in a digital format readable by a computer; It is generally the first step needed in a wide variety of very different applications: for example, to fabricate physical objects with numerical control instruments or also for purely “virtual uses” as 3D computer graphic images or movie-making.

There are two 3D modeling techniques: manual and algorithmic. A 3D model can also be obtained by scanning a real object. The “manual method” handbooks are inspired by the traditional plastic arts manuals, where you manipulate a material up to get it to the desired shape; in algorithmic modeling, instead, you describe the object with programming techniques.

The algorithmic methods are best suited both to achieve high model precision and to reproduce serially similar models.

Talking about computer generated models and file formats, there are many ways: one of the most common, used by several popular software like Blender or Google Sketchup, is using polygon meshes to describe the model outer surface. Another method worth mentioning is the constructive solid geometry (CSG) which describes the entire model volume starting from simple primitives such as cubes, cylinders, spheres and combining each other through unions, intersections and differences.

As you can imagine, obtaining a realistic representation of organic forms with this system requires a lot of work; vice-versa, it is a very suitable system for mechanical parts: in fact, these tend to be easily exploded into geometric primitives and are naturally represented by solid objects rather than by surfaces whose internal shapes are not defined. Depending on the targets you want to achieve, you have to pay attention to several modeling issues: in 3D models it is important the “external” and visual rendering, the surface properties, but when the model must be physically made, the real object structure and its mechanical properties are fundamental.

For this goal, the 3d modeling based on solids is a real help.

OpenSCAD is a free software to create 3D models based on constructive solid geometry, it excels in modeling objects that require precision: from the simplest shape as a rectangular box up to complex structures or mechanisms.

The other very visible OpenSCAD feature is that models are not created by mouse browsing but are described algorithmically in a simple programming language: this is one of the simplest user interfaces that allow you to achieve the accuracy required by CNC applications and also provides useful tools to make composed objects by mathematical formulas.

These features, together with its ease of use, make OpenSCAD a good choice for the hobbyist who wants to add to its electronic projects a structural or mechanical part, 3D printer with a 3Drag or made by using other numerical control tools.

Thanks to all these characteristics, OpenSCAD is one of the most used software that can be found on various model file sharing websites (as Thingiverse).

In this first tutorial we’ll see the OpenSCAD basic functions, enough to create custom boxes for our projects.