State of the art
Several alternatives exist for capturing the three-dimensional geometry of an object, such as laser triangulation, structured light and stereo vision. Comparatively, the first method offers greater precision and a higher resolution, but it also has limitations in terms of the kind of materials that can be scanned. Laser triangulation is based on capturing the projection of a laser beam over an object using a camera.
There are already scanners on the market with prices ranging from €500 to over €20,000 which are not open source, so the user is not able to study or modify the software.
FabScan5 and MakerScanner6 feature among these open source scanners, but they are not available for purchase as kits and the materials must therefore be purchased separately.
Ciclop
Ciclop is an open source 3D scanner kit. Being open source enables the user to study and modify it, whereas being sold as a kit permits the user to buy all the components together and at a fair price.
Design
The structure of Ciclop is made up of 3D-printed pieces, M8 threaded rods, M8 screws, M3 screws, nuts and washers. It has a 20 cm diameter methacrylate platform on which the piece is placed for scanning. It is covered with a anti-slip surface to prevent objects from moving during the scanning process.
The platform is supported by a 110 mm diameter ball bearing. The movement is created using a Nema 17 stepper motor.
Electronics
The sensor consists of a Logitech C270 HD webcam in the centre, two class 17 line laser modules located on the sides and a ZUM BT-3288 board, which is located in the interior of the body.
The ZUM BT-328 is an Arduino-based board that executes the control firmware of the motor and both lasers. It communicates with the PC via a micro-USB cable or Bluetooth. The ZUM SCAN is connected at the top, a shield derived from the Arduino CNC Shield9. This shield has 2 stepper drivers and connection pins for 4 lasers and 2 light dependent resistors (LDRs).
ZUM SCAN Shield
Horus
Firmware
The firmware has been developed using GRBL10 as a base and using other projects such as Marlin11 (the firmware used in open source 3D printers). It enables the lasers to be switched on and off, as well as the position, speed and acceleration of the stepper motor to be controlled using Gcode commands.
Software
The main program is a cross-platform desktop application developed in Python2. It uses wxPython12, NumPy13, SciPy14, Matplotlib15, OpenGL16, and an optimised version of OpenCV17 for Linux.
This application is the core of the scanning process. It manages the communications, the capture and syncing of the data, the image processing and the generation and visualisation of the point cloud.
It has been developed and optimised for GNU/Linux (Ubuntu18). However, it has been tested for Windows and it will also be supported for Mac. Horus consists of three workbenches which can be selected by the user.
Control
In this section each component of the scanner can be freely controlled: the camera settings, the lasers, the motors, etc… It has been designed so that makers and developers can carry out tests and experiments on eac h component of the device separately.
Calibration
The calibration workbench contains the tools needed for calibrating the device, from adjustment of the camera settings to the laser triangulation and detection of the rotating platform.
The system has been designed to calculate the internal scanning parameters automatically, using the structure assembled by the user. This is very important, because on being a DIY kit, no two scanners will ever be assembled identically. It is impossible to determine a priori what dimensions and directions the user will create on assembling it. Furthermore, the user can create a scanner with different dimensions and positions of the lasers and the camera. Horus will auto-calibrate correctly to achieve the perfect scanning.
Horus: phases of the calibration
Scanning
This section allows to select the type of scanning: with/without texture, one/two lasers, steps per turn, etc. It also provides a 3D environment for visualising the point clouds in real time and a video window which displays the different parts of the image processing.
The scanning times depend on the algorithm used and the acceleration and step of the motor. For 800 steps per turn (0.45º per step), the times vary from 2′ the fastest to 6′ the slowest (using both lasers) on Linux.
The result of this process is a PLY19 file. Here are some more examples:
Wizard
Horus also includes a wizard that simplifies the calibration and scanning processes, using a step-by-step guide.
Meshing
There are various open source programs, such as Blender20 or MeshLab21, which allow a point cloud (PLY) to be converted into a mesh (an STL22file). STL is a file format for 3D meshes composed of triangles. An STL file can be printed in 3D using programs such as Cura23.
Meshing with MeshLab: computing the normals
Once the STL has been created, the model can be visualised in Horus.
Future work
In this project we want to keep on evolving and improving. One of our main areas of work will be incorporating post-processing 3D mechanisms and meshing into Horus..
The opinion of the community is of great interest to us, which is why we are open to suggestions and improvements via our Group or GitHub.
We encourage you to get involved with this project!
Publications
In the coming weeks, we will be publishing all the developments, documents and manuals relating to this project in detail under Creative Commons and GPL v2 licence.
Are you ready?
References
GNU/Linux operating system
Python programming language
RepRap community
Arduino community
FabScan project
MakerScanner project
IEC60825-1:2014 Class 1 Security certification
ZUM BT-328 controller board
Arduino CNC Shield power shield
GRBL CNC control software
Marlin firmware
wxPython graphic library
NumPy matrix calculus library
SciPy scientific calculus library
Matplotlib graph-plotting generation library
OpenGL 3D graphics library
OpenCV artificial vision library
Ubuntu. Ubuntu GNOME, Kubuntu operating system
PLY mesh format
Blender 3D editor
MeshLab advanced mesh processor
STL mesh format
Cura 3D printing software