3D(ollar) Scanner

A cheap, yet surprisingly good rendition of a 3D scanner

Similar projects worth following
After seeing many 3D scanners with incomplete and broken software (except for Their model), I got tired with the other projects! I decided to make my own 3D scanner with a total biill of goods at $2.73 for the lazy susan bracket. The rest was salvaged from Bloominglabs, my hackerspace!

Right now, you can be up and running with your own 3D scanner! I have the hardware design, Arduino sketch, and the Processing programs all avilable.

What makes my project special vs other 3D scanning projects: I solve the pointcloud for any vertical arbitrary position for the camera (horizontal: -pi/2<X<pi/2),(vertical: 0<Y<pi/2)! I know of no other projects that do this. I also do so only requiring to know the center of the platter and the angle of laser line incident to vertical. 

Right now, the Processing skit works! You just have to edit it manually for the correct values. That's why I'm working on a Java version, with as much calibration I can include to make things easier for everyone who just wants to scan.

The Instructables link was the project I started to base mine from! Of course, I knew I'd migrate away from Processing, and even the Arduino platform. However, I include that link as a nod to my personal inspiration! Thank you, cube000 !

  • 4 × 1N4004 Discrete Semiconductors / Diodes and Rectifiers
  • 4 × IRLZ44N Discrete Semiconductors / Power Transistors and MOSFETs
  • 4 × 1Kohm resistor
  • 4 × 2.2Kohm resistor
  • 1 × junky laser Try to find focusable laser module. Shouldnt be much more than $3

View all 16 components

  • 3D scanner program updates

    Joshua Conway10/30/2014 at 02:19 0 comments

    I finally have the bulk of my calibration code written, with only the line selection / saving as the last step. Everything that's touched is calibrated and measured!

    Mainly, what next to do is the line selection / saving , writing the 3D scaning portion, and then updating the Arduino code to reflect a more GCode base.

    From there, I can easily generate a pointcloud file with X, Y, Z, as well as RGB attached to each coordinate. Once I am at this point, I will look into how hard it is to calculate surfaces using PCL.

    I also have to fix errors like my Makefile. I'm unsure how to do that, given this is my first real undertaking of programming. However, documentation online is very good. I'll get it done soon.

  • More progress on QT program

    Joshua Conway09/28/2014 at 14:52 0 comments

    I finally have all my settings save in ~/.config/JoshCrawleySoft/ and a user changeable directory for all the camera calibration data!

    Code was pushed to 9/27. I'm now working on the Hough line and circle transforms to auto-detect the laser plane intersection (hough line transform) as well as detection of the circular platter (hough circle transform). I may at a later time, implement color calibration using a flatbed scanner and paint chips from local hardware store. Goal here is lens calibrated, color calibrated, auto detected 3D scanning. The simpler, the better.

    Work is going slower on this project mainly due to 13 credit hours, new job at Indiana University, and my wedding on October 11! However, coding is still taking place for the magic of a cheap and ubiquitous 3D scanner!

  • Major update ; QT program available on GH

    Joshua Conway08/05/2014 at 10:51 0 comments

    I messed with Java in displaying Webcam images to do the ful stack with OpenCV. Unfortunately, messing with java is all that I got accomplished, considering there is no unified simple way of opening webcams on Java. I tried JMF, FMJ, Marvin, CIVIL, webcam-capture, and other libraries. The worst crashed my java interpreter. The best displayed any webcam source at 640x480 (argh!).

    So, I decided to see how hard displaying cam data would be with QT and C++... It took me 20 minutes to display an arbitrary resolution! So I decided to implement the GUI and controls in QT, OpenCV, and eventually PCL. 

    On August 4th (yesterday), I made my first major checkin on Github with my new QT program. It has the config screen and video viewing screens. Now, my next big adventure is to work on calibration routines. Then, and only until they are done, will I get to scanning.

    My calibration routines are simple in idea. 

    1. First, calibrate the cameras for lens abberation. That is easily solved by calling in the camera calibration routine. I do this for each camera. 

    2. I determine the center coordinate for the platter. That point (on each picture) is what I consider Origin. That point shouldnt change, so it's the same for each image. I use a hough circle transform, with inspiration from here:

    3. I determine the slope of the laser line on the platter. This angle is the combined angular displacement between horizontal and vertical allignment. I use a hough line transform to get the position of this line, and then calculate angle versus vertical.

    As long as I calculate for each camera its own calibration data, I can combine those pointclouds easily. I will need a calibration function for the second laser line and its position. I'm still thinking how I want to implement it, as my goal here is simplicity in use. 

  • Line lasers received, work on new box ; OpenCV and C++

    Joshua Conway07/30/2014 at 18:49 0 comments

    I now have the 2 line lasers I ordered! So, my total inventory is 2 line lasers and a point laser (with glass rod that makes 3rd dirty line laser). 

    I also have a gifted (lsusb) 046d:082d Logitech, Inc. HD Pro Webcam C920 ! Yes, this is a $70 webcam that captures at 1920x1080! 

    I'm also revising my decision to go with Java. I have fought and fought with the multitude of libraries that claim to properly open up webcams in Linux (OpenCV, webcam-capture, FMJ, JMF, Marvin...). Alas, I either end up with driver failures in opening the libraries, or they are capped at 640x480, which is no better than my PS2 Eyetoy. Doing that loses me 6.75x resolution data.

    Below is the output of a QT5 program I wrote using OpenCV and C++ at the max resolution my camera supports. Took only 20 minutes, and that's including learning C++ grammar (I already knew C):

    And this is a snapshot of my and my wife's artistry. We both painted it together (we hopped from side to side). And it was my first time painting :)

  • Given HD webcam!

    Joshua Conway07/28/2014 at 11:40 0 comments

    Right now, the Processing applets I have made and published on github do indeed work. The actual scanner application does talk to the arduino, acquires photos, and then processes them for 3d data. Awesome. But it's crap. Here's why:

    1. No calibration to speak of - every time I move webcam, I have to calculate center, and I should also calculate the slope of the line.

    2. I have to manually change resolutions in Processing. Every detection sketch fails on my better webcam with the FPS at 15/2 and expecting INTs.

    3. I want full OpenCV functionality - like camera calibration and hough transforms (line/circle detection). But I need Java or C for that.

    And the 3rd point goes into what I am currently working on: I'm learning Java proper so I can write a better program that does what Processing was supposed to do!

  • Scan of antique doll

    Joshua Conway07/28/2014 at 11:38 0 comments

    This Scan was done last Thursday as a demonstration to my mother what this project is about. She had this doll which was in her curio cabnet. So I took it, and scanned it at 480 pictures on a Sony EyeToy PS2 webcam. At this time, I only have 1 laser so there will be some problems with the hidden viewpoint. When my line lasers show up, I'll redo the project box to utilize both of them and solve many issues I have with Version 1.

    Pointclouds and picture dataset for said object aviliable on

View all 6 project logs

  • 1
    Step 1

    1. Find stepper motor, preferrably one with gearing.

  • 2
    Step 2

    2. Hook up circuits and apply Arduino sketch to test stepper motor.

  • 3
    Step 3

    3. Screw down the lazy susan bracket and platter and fix down parts. Secure motor and fix belt to the wheel.

View all 12 instructions

Enjoy this project?



Films4You wrote 10/22/2015 at 07:30 point

  Are you sure? yes | no

A Shed wrote 05/12/2015 at 04:49 point

Is there a circuit diagram somewhere to show how to hook all of the parts up?

  Are you sure? yes | no

Wilpe wrote 01/24/2015 at 12:50 point

so, is this project still alive? I would really like to build on of these scanners my own but I don´t know anything about the software part. So I´m hoping that this project will end with a step by step manual..

  Are you sure? yes | no

Rebelj12a wrote 11/10/2014 at 21:44 point
Sorry github link as well.

  Are you sure? yes | no

Rebelj12a wrote 11/10/2014 at 21:41 point
Ok not sure if this will help but.... here, Zoneminder mentions the V4L (video for linux) interface. Its a security camera software, however seeing what packages it installs one of those might have drivers and software for accessing webcams. Zoneminder has alot of compatibility although that may be C++.

  Are you sure? yes | no

Rebelj12a wrote 11/10/2014 at 21:35 point
Loving this keep up the good work, looking to make something like this although not laser point cloud but its good to know. More comments once I catch up on project progress.

  Are you sure? yes | no

Neon22 wrote 08/01/2014 at 10:54 point
you could use python and openCV which has a really nice interface between the two.

  Are you sure? yes | no

Joshua Conway wrote 08/01/2014 at 15:19 point
I found out the hard way (wasting a week and a half) finding out that Java wouldn't work. I tried perhaps 6 libraries trying to get them to open up my max resolution on my nice webcam. At worst, I received crashes and java instability. At the best, I got an HD webcam to show me 640x480...

After messing around with QT5, OpenCV, and Pointcloud library, I was able to acquire any arbitrary resolution my device supports and save it to files. It took me 20 minutes to get up to snuff to QT and C++ and get it running. The picture above with the 2 canvasses of the blue moon painting is a testament to that program able to capture.

Right now, I'm working on a QT C++ application that will do all the calibration and scanning. I'm building in the program also the ability to capture multiple cameras and individual calibration with each of them. And of course, accuracy is greatly wanted, but I'm also wanting color data, so I'm going to be capturing that too.

Once I get the GUI configured the way I like it, and at least the ability to view webcams, then I'll issue the GIT PUSH from my machine to master on github.

edited: Added last sentence of 2nd paragraph.

  Are you sure? yes | no

Neon22 wrote 08/02/2014 at 00:07 point
cool. I'll stop forking and enhancing your current github project then :)

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates