DESIGN AND FABRICATION OF 3D SCANNER USING IR SENSOR 19MEPN6601- INNOVATIVE AND CREATIVE PROJECT REPORT Submitted by SOURAV R A JITHIN RAHUL A HARIHARAN K 19BME018 19BME064 20BME338 in partial fulfillment for the award of the degree of Bachelor of Engineering in Mechanical Engineering Dr. Mahalingam College of Engineering and Technology Pollachi - 642003 An Autonomous Institution Affiliated to Anna University, Chennai - 600 025 JUNE 2022 Dr. Mahalingam College of Engineering and Technology Pollachi - 642003 An Autonomous Institution Affiliated to Anna University, Chennai - 600 025 BONAFIDE CERTIFICATE Certified that this Innovative and Creative project work, “ DESIGN AND FABRICATION OF 3D SCANNER USING IR SENSOR” is the bonafide work of SOURAV R A JITHIN RAHUL A HARIHARAN K 19BME018 19BME064 20BME338 who carried out the project work under my supervision. SIGNATURE OF HOD SIGNATURE OF SUPERVISOR Dr. I. RAJENDRAN M.E., Ph.D., FIE, Mr. S. NAVEEN KUMAR. M.E., Senior Professor& Head of the Department Mechanical Engineering Dr. Mahalingam College of Engineering and Technology, NPTMCET Campus Pollachi – 642003 India Assistant Professor Mechanical Engineering Dr. Mahalingam College of Engineering and Technology, NPT-MCET Campus Pollachi – 642003 India Submitted for the Autonomous End Semester Examination Innovative and Creative Project viva- voce held on EXAMINER-1 EXAMINER-2 DESIGN AND FABRICATION OF 3D SCANNER USING IR SENSOR ABSTRACT As we look throughout history, the wealthy and privileged have had access to useful technologies, before the masses. When cars, televisions, and even computers first entered the market, they were revolutionary but overpriced. This discouraged people from acquiring them. These technologies are not necessities to life, but they play big roles in making life more convenient. 3D scanners are relatively new technologies that have many useful applications, but yet very few people own them, mostly due to the expense of the product. We will talk about a way to create a cheap standalone 3D scanning system, which through the use of processing information taken by a line IR, can create digitized 3D models. These models can be used in digital animation or printed with 3D printers for a wide variety of applications. Many different technologies can be used to build these 3D scanning devices; each technology comes with its own limitations, advantages, and costs. Many limitations in the kind of objects that can be digitized are still present: for example, optical technologies encounter many difficulties with shiny, mirroring, or transparent objects. There are several different kinds of 3D IR scanners, with prices ranging from the couple thousands to the hundreds of thousands. Nowadays, 3D scanners have become widely used tools in different disciplines, such as robotics, medicine and manufacturing. These devices are capable of representing virtual 3D objects with extremely good accuracy, but they are very expensive, making them not affordable for research institutions with low economical resources. Because of that, many we have been worked on projects to develop low-cost 3D scanners implementing different methodologies and technologies. This report shows a methodology to develop a prototype of a 3D scanner device that can represent virtual 3D objects from distance measurements obtained by a 1D optical distance sensor. Essentially, the device consists of three elements, an electromechanical platform, a data acquisition hardware (controlled by the Arduino Nano) and a graphical user interface (Mesh Lab). The results obtained by scanning different solid objects are very promising and show the effectiveness of the presented approach and good functionality of the device. i ACKNOWLEDGEMENT We wish to acknowledge with thanks for excellent encouragement given by the management of our college and we thank Dr. C. Ramaswamy, M.E., Ph.D., FIV, Secretary, NIA Educational Institutions for providing us with a plethora of facilities in the campus to complete our project successfully. We wish to thank our Principal Dr. A. Rathinavelu, M.Tech., Ph.D., for his motivation. We express our extreme gratefulness to Dr. I. Rajendran, M.E., Ph.D., FIE, Head of the Department, Mechanical Engineering who was instrumental in providing such wonderful support, which any student would dream to have. It is also our primary duty to thank our Project guide Mr. S. Naveen Kumar. M.E., Assistant Professor, Mechanical Engineering, who is back bone of all our project activities, for his constant guidance and encouragement, which kept us fast and pro-active in our work. It is their enthusiasm and patience that have borne fruit in the end. We sincerely thank Project Coordinator Dr. R. Gnanaguru, M.E., Ph.D., Associate Professor, Department of Mechanical Engineering for their valuable help and encouragement in developing and completing this project successfully. Finally, we wish to express our deepest gratitude and indebtedness to our parents for their kind support. ii TABLE OF CONTENTS CONTENTS DESIGN AND FABRICATION OF 3D SCANNER USING IR SENSOR .............................................................................................................. i ACKNOWLEDGEMENT .................................................................................................... i ABSTRACT ........................................................................................................................... i TABLE OF CONTENTS ....................................................................................................iii LIST OF FIGURES ............................................................................................................vii LIST OF TABLES............................................................................................................... ix 1. INTRODUCTION .............................................................................................................. 1 2. LITERATURE REVIEW ................................................................................................... 3 3. 3D SCANNER .................................................................................................................... 5 3.1 CLASSIFICATION OF 3D SCANNING TECHNIQUES ........................................................................................................... 5 3.1.1 LASER TRIANGULATION 3D SCANNER .............................................................. 5 3.1.2 STRUCTURED LIGHT 3D SCANNER ...................................................................... 6 3.1.3 PHOTOGRAMMETRY ............................................................................................... 6 3.1.4 LASER PULSE BASED 3D SCANNING ................................................................... 7 3.1.5 CONTACT BASED 3D SCANNING .......................................................................... 7 3.2 COMPARISON TABLE ............................................................................................. 8 3.3 OBJECTIVES .............................................................................................................. 9 3.4 METHODOLOGY ...................................................................................................... 9 3.5 BLOCK DIAGRAM ................................................................................................. 10 4. COMPONENTS ............................................................................................................... 11 iii 4.1 HARDWARE COMPONENTS ................................................................................ 11 4.2 MECHANICAL COMPONENTS ............................................................................ 11 4.3 ARDUINO NANO .................................................................................................... 11 4.3.1 SPECIFICATION ....................................................................................................... 12 4.3.2 PIN DESCRIPTION ................................................................................................... 13 4.3.3 ADVANTAGES ......................................................................................................... 14 4.3.4 APPLICATION .......................................................................................................... 14 4.4 NEMA-17 BIPOLAR STEPPER MOTOR ............................................................... 14 4.4.1 SPECIFICATIONS ..................................................................................................... 15 4.4.2 STEPPER MOTOR APPLICATIONS ....................................................................... 15 4.5 A4988 STEPPER MOTOR CONTROLLER ............................................................ 15 4.5.1 SPECIFICATIONS ..................................................................................................... 16 4.5.2 CONTROL PINS ........................................................................................................ 16 4.6 A51SK0F INFRARED DISTANCE SENSOR ......................................................... 17 4.6.1 SPECIFICATIONS ..................................................................................................... 17 4.6.2 APPLICATIONS ........................................................................................................ 17 4.6.3 SCHEMATIC ............................................................................................................. 18 4.6.4 ABSOLUTE MAXIMUM RATINGS ........................................................................ 18 4.6.5 OPERATING SUPPLY VOLTAGE .......................................................................... 18 4.7 MICRO SD CARD SHIELD ..................................................................................... 19 4.7.1 MICRO SD CARD MODULE PIN OUT................................................................... 20 4.8 MICRO SD CARD (TF CARD) ............................................................................... 20 iv 4.9 12V POWER SUPPLY.............................................................................................. 21 4.9.1 SPECIFICATIONS ..................................................................................................... 21 4.10 BREADBOARD ...................................................................................................... 22 4.10.1 LIMITATIONS ......................................................................................................... 22 4.11 JUMPER WIRES .................................................................................................... 23 4.12 M8 LEAD SCREW AND NUT .............................................................................. 24 4.12.1 ADVANTAGES ....................................................................................................... 25 4.13 8MM SMOOTH ROD ............................................................................................. 25 4.13.1 FEATURES .............................................................................................................. 26 4.14 SC8UU LINEAR MOTION BEARING ................................................................ 26 4.14.1 SPECIFICATIONS ................................................................................................... 27 4.15 FLEXIBLE COUPLING 5MM TO 8MM .............................................................. 27 4.15.1 SPECIFICATIONS ................................................................................................... 28 4.15.2 FEATURES .............................................................................................................. 28 4.16 SHF8 8MM FLANGE MOUNTING ...................................................................... 28 4.16.1 SPECIFICATIONS ................................................................................................... 29 5. DESIGN LAYOUT .......................................................................................................... 30 5.1 ELECTROMECHANICAL STRUCTURE .............................................................. 31 5.1.1 SPINNING PLATFORM ........................................................................................... 31 5.1.2 ELEVATOR MECHANISM AND DISTANCE SENSOR .................................................................................................................... 31 5.2 DISTANCE SENSOR ............................................................................................... 31 5.3 POINT CLOUD TO STL .......................................................................................... 32 v 6. CIRCUIT DIAGRAM ...................................................................................................... 33 6.1 SOFTWARE.............................................................................................................. 33 6.2 COLLECTING DATA POINTS ............................................................................... 33 6.3 FLOW CHART OF THE PROGRAM THAT COLLECTS AND SAVES DATA POINTS ........................................................... 34 6.4 SAVING DATA POINTS ......................................................................................... 35 6.5 VISUALIZATION .................................................................................................... 35 7. SOFTWARE DESCRIPTIONS ....................................................................................... 36 7.1 ARDUINO IDE ......................................................................................................... 36 7.1.1 ADVANTAGES OF USING ARDUINO SOFTWARE................................................................................................................... 36 7.1.2 FEATURES ................................................................................................................ 37 7.1.3 APPLICATIONS ........................................................................................................ 37 7.2 MESHLAB ................................................................................................................ 37 8. COST ESTIMATION ...................................................................................................... 39 9. RESULT ........................................................................................................................... 40 10. CONCLUSIONS ............................................................................................................ 42 11. REFERENCES ............................................................................................................... 43 vi LIST OF FIGURES Figure 3.1 Classification of 3D Scanning Techniques ….......................................................... 5 Figure 3.2 Laser Triangulation Technique ................................................................................ 6 Figure 3.3 Structured Light 3D Scanning … ............................................................................. 6 Figure 3.4 Photogrammetry Technique … ................................................................................7 Figure 3.5 Contact Based 3D Scanning … ................................................................................8 Figure 3.6 3D Scanning Method … ........................................................................................... 9 Figure 3.7 Block Diagram of 3D Scanner System …................................................................ 10 Figure 4.1 Arduino Nano Board ................................................................................................ 12 Figure 4.2 Nema-17 Bipolar Stepper Motor .............................................................................. 14 Figure 4.3 A4988 Stepper Motor Controller ..............................................................................15 Figure 4.4 Infrared Distance Sensor ...........................................................................................17 Figure 4.5 Schematic Diagram of Infrared Distance Sensor ..................................................... 18 Figure 4.6 Micro SD Card Shield ...............................................................................................19 Figure 4.7 Micro SD Card Module Pin Out.............................................................................. .20 Figure 4.8 Micro SD Card ......................................................................................................... 20 Figure 4.9 12V Power Adaptor ...................................................................................................21 Figure 4.10 Breadboard ............................................................................................................ 22 Figure 4.11 Jumper Wire .......................................................................................................... 23 Figure 4.12 Lead Screw ............................................................................................................ 24 Figure 4.13 8mm Smooth Rod .................................................................................................. 26 Figure 4.14 SC8UU Linear Motion Bearing ............................................................................. 27 vii Figure 4.15 Flexible Coupling 5mm to 8mm .............................................................................28 Figure 4.16 SHF8 8mm Flange Mounting ................................................................................ 29 Figure 5.1 Design layout of 3D Scanner................................................................................... 30 Figure 6.1 Circuit Diagram ....................................................................................................... 33 Figure 6.2 Object-rotating plate Point A is the measured point and point B is the coordinate calculated adjusted for the rotation ...................................................................................................................... 34 Figure 6.3 Flow Chart .................................................................................................................34 Figure 6.4 An example of the conversion from points to a mesh using MeshLab ......................................................................................................... 35 Figure 7.1 Steps to Convert the Cloud points to STL file ........................................................ 38 Figure 7.2 Mesh File ................................................................................................................. 38 Figure 9.1 Base of The Project (3D scanner)............................................................................ 40 Figure 9.2 Arduino, Stepper Motor and Power Supply of 3D scanner .................................................................................................................... 40 Figure 9.3 IR Sensor and Scanning Object .................................................................................41 viii LIST OF TABLES Table 3.1 Comparison of different 3D Scanning Techniques ...................................................8 Table 4.1 Pin Description of Arduino Nano ............................................................................ 13 Table 4.2 Absolute Maximum Ratings .................................................................................... 18 Table 4.3 Operating Supply Voltage ....................................................................................... 18 Table 4.4 Specifications of SC8UU Linear Motion Bearing ................................................... 27 Table 4.5 Specifications of SHF8 8mm Flange Mounting ...................................................... 29 Table 8.1 Cost Estimation…………………............................................................................ 39 ix CHAPTER 1 INTRODUCTION 3D scanning methodology came into existence in late 20th century. The initial 3D scanners in the 1980s used contact probes. These physically touched the target articles a number of times until the device had enough digital data points to create a 3D model. As this method was time consuming, newer methods which were more efficient and faster were developed. Out of the methods used for reverse engineering, 3D scanning is the most effective. Reverse engineering involves recreating an existing product. It is mainly used to redesign and produce a reasonably accurate replica of the product. Computer vision has been widely used for reverse engineering. To enhance the quality of an image, a computer uses image processing. Using this computer vision, three-dimensional data can be obtained from two dimensional images. The main purpose of 3D scanning is to create a digital three-dimensional model out of the data collected by the scanner from its surroundings. Creation of the 3D digital model is made by using the idea of point cloud. Information regarding the object’s shape is collected at such points. The whole shape, geometry, color or pattern of the object is extrapolated using the data collected at these points. This process is called as reconstruction. Post reconstruction, STL (Stereo Lithography) file is generated which can be printed. After 3D printing of this file, the threedimensional replica of the original object is generated. The field of 3D scanning is growing rapidly in modern industries. Many techniques have been implemented to get the most accurate replica of the product. The research of 3D reconstruction has always been a difficult goal. Using 3D reconstruction one can determine any object’s 3D profile, as well as knowing the 3D co-ordinate of any point on the profile. The 3D reconstruction of objects is a generally scientific problem and core technology of a wide variety of fields, such as CAD, CAM, reverse engineering, medical imaging, computer graphics etc. For instance, the lesion information of the patients can be presented in 3D on the computer, which offers a new and accurate approach in diagnosis and thus has vital clinical value. When it comes to 3D scanning, thoughts often tend towards the endless opportunities to study things and shapes that were previously impossible. However, 3D scanning is also a perfect technology for fixing the previously unfixable. 1 The purpose of a 3D scanner is usually to create point cloud of geometric samples on the surface of the subject. These points can then be used to extrapolate the shape of the subject (a process called reconstruction). If color information is collected at each point, then the colors on the surface of the subject can also be determined. The “picture” produced by a 3D scanner describes the distance to a surface at each point in the picture. This allows the three-dimensional position of each point in the picture to be identified. In the last decades, the microelectronics has changed in a drastic way the world we live; causing that people have the possibility to use innovative devices in order to overcome problems that seemed impossible to be solved before. Those changes show a revolution in digital technology so now people have smaller and faster computers that are capable to manage multimedia applications efficiently. Particularly in the recent years, different types of sensors have been developed to create commercial devices known as 3D scanners. These devices gather information of an object or scene and represent it graphically in three dimensions using different techniques. In the market there are commercial 3D scanners that vary about the techniques that are used to get the necessary information, costs and their applications, such as vivid 9i, Mephisto Micro, HDS3000, Zscanner 800 and many others. Among the wide field of 3D scanners applications some examples are: in industry, scanners are useful in reverse engineering to create automotive parts; in forensic medicine, help to construct digital 3D models of accidents; in Orthopedics, to prostheses fabrication and in Robotics, made possible the artificial vision to mobile robots. Even though, many commercial and sophisticated scanners exist, also they are very expensive, in the range of tens of thousand dollars, and this limits their utilization in research institutes with scarce resources. Due to this problematic, there have been some alternatives to achieve similar results using scanners with lower cost sensors. There are several methodologies to obtain three-dimensional maps of an object or scenes. 2 CHAPTER 2 LITERATURE REVIEW V.N.Chougule, H.S.Gosavi, M.M.Dharwadkar, A.A.Gaind (2018) proposed a Review of Different 3D Scanners and Scanning Techniques in IOSR Journal of Engineering, using this paper, different methods for 3D scanning have been studied in detail. Arnulfo León Reyesa, Jesús Medina Cervantesb, Nereyda Castro Gutiérre (2013) proposed a Low cost 3D scanner by means of a 1D optical distance sensor at Iberoamerican Conference, The 3D scanner device developed in this project was tested to prove the effectiveness of the proposed scanning method. Mohd Javaid, Abid Haleem, Ravi Pratap Singh, Rajiv Suman (2021) proposed an Industrial perspectives of 3D scanning: Features, roles and it's analytical applications, Sensors International 2, in this the point cloud data created from the 3D Scan is used with the help of dedicated software to build a 3D CAD model of the product geometry and use a point cloud to improve product performance and design optimization. Mahesh Parde, Karan Khankal, Thotya S, R.S.Meshram (2018) proposed a Implementation of 3D Scanner Using IR Distance Sensor, Electronic & Telecommunication KGCE Karjat India, Volume-4, Issue-2, using this we know that the system which is proposed is much convenient for the industrial use which require small scale material to be scanned. Bhagyashri Tawade (2016) proposed a Review Study of Range Calculation Based on Laser Triangulation, International Journal for Research in Emerging Science and Technology, Volume3, Issue-9, This study has presented laser-based inspection system to measure the inside filament slope and golf equipment used by a golfer to hit a golf ball groove. 3 Joao Guilherme; Mario A. Gazziro; Alessandro N. Ide; Jose H. Saito proposed the laser triangulation for most reliable 3D scanning systems. In triangulation-based systems, the field of vision and deep variation are limited, but they have a great exactness. This work describes a development of a 3D scanning system, with exactness and with better range. Sanjeev Kumar; Prabhat Kumar Tiwari suggested a triangulation-based range finder in this paper. The sensor measures range and direction of objects and surfaces, based on the triangulation principle Some papers are describing approaches to detect height/depth of object using laser triangulation by various methods. Yang-Cheng Lin; Pin-Hao Hu proposed a laser-based inspection system to measure the inside filament slope or angle and the golf equipment used by a golfer to hit a golf ball head face by using laser triangulation principle. The proposed principle is established based on ray optics and laser triangulation method. Compared to common harmful testing, the experimental results show that the laser-based inspection system is an actual and a nice measuring method for inspection applications. 4 CHAPTER 3 3D SCANNER 3.1 CLASSIFICATION OF 3D SCANNING TECHNIQUES Many techniques have been implemented to get the most accurate replica of the product. In such circumstances, it is essential that these techniques should be studied and compared with each other. The methods used for 3D scanning are primarily classified as the following figure 3.1 [3]. Fig 3.1 Classification of 3D Scanning Techniques 3.1.1 LASER TRIANGULATION 3D SCANNER This uses the principal of triangulation [1] used for measuring distances as shown in the figure 3.2. Laser beam is imparted on a point, for finding its distance from the laser source. Diffused reflections are detected by detectors placed such that source, object and detector form a triangle. The main advantage of such type is its high speed of detection, accuracy and precision. Surface properties of the object being the main disadvantage of this method, constraining its application. The line laser projects a linear vertical line on the object which is to be scanned, the image of this is taken by the camera and the position of the object or laser is changed depending on the setup so as to get the contour of other part of the object, slowly and steadily the whole object is covered. This information is then given to the processor which combines all the images to generate a 3D model. APPLICATIONS: Entertainment industry, reverse engineering 5 Fig 3.2 Laser Triangulation Technique 3.1.2 STRUCTURED LIGHT 3D SCANNER This method uses light grid pattern projections and synchronizing it with a camera for obtaining surface properties of the object using triangulation principle as shown in the figure 3.3.. Pattern of light is produced by using light modulators based on different technologies, in this method displacement of individual stripe is converted to 3D coordinate of the object. APPLICATION: Face Id, Forensic sciences Fig 3.3 Structured Light 3D Scanning 3.1.3 PHOTOGRAMMETRY This technology reveals the geometric properties of the objects by means of photographic images. The principal of photogrammetry is to take several images of the object from various views with common reference point in each photograph. It eliminates laborious modelling of object and also captures the color aspect of the object used as a subject. The object which is to be 3D scanned is placed on a clear, bright and well-lit place. All these photographs are put in photogrammetry software to process and develop a 3D model of the object is shown in the figure 3.4.. 6 APPLICATION: Topographic mapping, Archeological department Fig 3.4 Photogrammetry Technique 3.1.4 LASER PULSE BASED 3D SCANNING These scanners are known as lidar or time of flight scanners based on the time taken by laser to hit target and return. The speed of light is defined and using the time taken by laser, the distance can be easily found. Laser range detects only the distance of a point in its path therefore to change the view of laser, system of rotating mirrors is implemented. These are particularly used in areas where huge objects are to be scanned but operates at slower processing speed. Application: Area scan, large scale scanning 3.1.5 CONTACT BASED 3D SCANNING Contact based 3D scanning uses contact between probe and the object to reveal the surface information measured by deformation of the probe as shown in the figure 3.5.. The probe is moved firmly over the surface to acquire the information. Coordinate measuring machines are well known contact-based scanners, used for quality control. These classes of lasers are largely used due to their potential to scan transparent and reflective surface. APPLICATION: Transparent or Reflective objects, High precision and accuracy applications. 7 Fig 3.5 Contact Based 3D Scanning 3.2 COMPARISON TABLE Table no 3.1 Comparison of different 3D Scanning Techniques The different methods for 3D scanning have been studied detail in the table no 3.1. These methods are compared with each other on the basis of various parameters. From the comparison between these methods, it can be inferred that different applications require different types of scanners. The implementation of right method in the industries will yield the most accurate replica of the target object while saving the costs. 8 3.3 OBJECTIVES This project aims to design and fabrication of 3D Scanner whose base principle is Non-contact type and developing an effective and efficient 3D Scanner. The generalized 3D Scanner which can be implement in any domain. The main objective of the project is to make a 3D Scanner for the Engineering based start-up companies for easy to use, medium accuracy, affordable price, less processing time and operational safety. 3.4 METHODOLOGY In order to scan solid 3D objects, the authors made use of a very simple method. It consists of taking distance measurements from a solid 3D object that is subjected to a controlled rotation. After each revolution of the object, distance measurements need to be taken at a different height of it. In this manner, the silhouette of the object can be obtained in every revolution it does by gathering the distance measurements and corresponding rotation degrees. The silhouette distances are obtained by the difference between a fixed distance and distance measurements. Figure 3.6 shows the proposed 3D scanning method. Fig 3.6 3D Scanning Method The 3D scanner device designed to accomplish this goal is comprised of three elements: an electromechanical structure, a data acquisition hardware and a graphical user interface. These elements and their functionality are described as followed. 9 3.5 BLOCK DIAGRAM The Block Diagram of 3D Scanner System as shown in the figure 3.7. The architecture of the proposed 3D Scanner system using IR sensor. The proposed hardware consists of Arduino Nano, Stepper Motor, Stepper Motor Controller, IR Distance sensor, Micro SD card Shield, 12V DC power source. Active scanners emit some kind of radiation or light and detect its reflection in order to probe an object or environment. 3D IR Scanning or 3D IR Scanners can generally be categorized into three main categories; time of flight, phase shift, and IR triangulation. These IRscanning techniques are typically used independently but can also be used in combination to create more versatile scanning system. Fig 3.7 Block Diagram of 3D Scanner System The 3D scanner device designed to accomplish this goal is comprised of three elements: an electromechanical structure, a data acquisition hardware and a graphical user interface. These elements and their functionality are described as followed. 10 CHAPTER 4 COMPONENTS 4.1 HARDWARE COMPONENTS 1. Arduino Nano 2. Nema-17 Bipolar Stepper motor 3. A4988 Stepper motor controller 4. A51SK0F Infrared Distance Sensor 5. Micro SD card shield 6. Micro SD card 7. 12V Power supply 8. Breadboard 9. Jumper Wires 4.2 MECHANICAL COMPONENTS 1. Lead Screw and Nut M8 2. Smooth Rod Dia-8mm 3. SC8UU Linear Motion Bearing 4. Flexible Coupling 5mm to 8mm 5. SHF8 8mm Flange Mounting 4.3 ARDUINO NANO The Arduino Nano is a small, complete, and breadboard-friendly board based on the ATmega328P. It offers the same connectivity and specs of the Arduino Uno board in a smaller form factor as shown in the figure 4.1. The Arduino Nano is equipped with 30 male I/O headers, in a DIP-30-like configuration, which can be programmed using the Arduino Software integrated development environment (IDE), which is common to all Arduino boards and running both online and offline. The board can be powered through a type-B mini-USB cable or from a 9 V battery. The Arduino Nano has a number of facilities for communicating with a computer, another Arduino, or other microcontrollers. The ATmega328 provide UART TTL (5V) serial communication, which is available on digital pins 0 (RX) and 1 (TX). An FTDI FT232RL on the 11 board channels this serial communication over USB and the FTDI drivers (included with the Arduino software) provide a virtual com port to software on the computer. The Arduino software includes a serial monitor which allows simple textual data to be sent to and from the Arduino board. The RX and TX LEDs on the board will flash when data is being transmitted via the FTDI chip and USB connection to the computer (but not for serial communication on pins 0 and 1). A Software Serial library allows for serial communication on any of the Nano's digital pins. The ATmega328 also support I2C and SPI communication. The Arduino software includes a Wire library to simplify use of the I2C bus. 4.3.1 SPECIFICATION Microcontroller Operating voltage Input voltage Digital I/O pins Analog input pins DC per I/O pin DC for 3.3 V pin Flash memory SRAM EEPROM Clock speed : ATmega328P : 5 volts : 6 to 20 volts : 14 (6 optional PWM outputs) :8 : 40 mA : 50 mA : 32 KB : 2 KB : 1 KB : 16 MHz Fig 4.1 Arduino Nano Board 12 4.3.2 PIN DESCRIPTION Table No 4.1 Pin Description of Arduino Nano Pin Category Pin Name Details Power Vin, 3.3V, 5V, GND Vin: Input voltage to Arduino when using an external power source (6-12V). 5V: Regulated power supply used to power microcontroller and other components on the board. 3.3V: 3.3V supply generated by on-board voltage regulator. Maximum current draw is 50mA. Reset Reset Resets the microcontroller. Analog Pins A0 – A7 Used to measure analog voltage in the range of 0-5V Input/output Pins Digital Pins D0 - D13 Can be used as input or output pins. 0V (low) and 5V (high) Serial Rx, Tx Used to receive and transmit TTL serial data. External Interrupts 2, 3 To trigger an interrupt. PWM 3, 5, 6, 9, 11 Provides 8-bit PWM output. SPI 10 (SS), 11 (MOSI), 12 (MISO) and 13 (SCK) Used for SPI communication. Inbuilt LED 13 To turn on the inbuilt LED. IIC A4 (SDA), A5 (SCA) Used for TWI communication. AREF AREF To provide a reference voltage for input voltage. 13 4.3.3 ADVANTAGES Great platform for beginners. Tiny size makes it perfect for compact projects. Functionally the same as their larger counterparts. Fits onto a breadboard making prototyping easier. 4.3.4 APPLICATION Can be used in Designing of basic circuit designs. It is used in the development of an automation system. It can be also used in developing projects based on code-based control. This Arduino Uno is used in do it yourself project prototyping. 4.4 NEMA-17 BIPOLAR STEPPER MOTOR NEMA 17 is a high torque hybrid bipolar stepper motor with a 42×42X38 mm faceplate. This motor has a step angle of 1.8 deg., this means that it has 200 steps per revolution and for every step it will cover 1.8° as shown in the figure 4.2. The motor has four color coded wires (Black, Green, Red & Blue) terminated with bare leads. Black and Green wire is connected with one coil; Red and Blue is connected with other. This motor can be controlled by two H-bridges but it is recommended to use a stepper motor driver. Its allowing for a holding torque of 4 kg-cm. NEMA 17 Stepper motor is generally used in Printers, CNC machine, Linear actuators and hard drives. Fig 4.2 Nema-17 Bipolar Stepper Motor 14 4.4.1 SPECIFICATIONS Voltage Rating : 3.6V Current Rating : 2.8A Step Angle : 1.8 deg Steps Per Revolution : 200 No. of Phases :4 No. of Leads :4 4.4.2 Stepper Motor Applications CNC machines Precise control machines 3D printer/prototyping machines Laser cutters Pick and place machines 4.5 A4988 STEPPER MOTOR CONTROLLER The A4988 Driver Module is used to control the speed and direction of stepper motors mainly used in robotics, toys, and 3D printers for motion control. It is capable of operating bipolar stepper motors in full step, half step, quarter step, eighth step, and sixteenth step modes. There is a built-in translator which allows only two pins from the Arduino board to be used to control the speed and direction of the stepper motor as shown in the figure 4.3. Fig 4.3 A4988 Stepper Motor Controller 15 4.5.1 SPECIFICATIONS Maximum Operating Voltage: 35V Minimum Operating Voltage: 8V Maximum Current per phase is 2A so it can easily control NEMA17 that has an output current of 2A per phase. Dimensions: 15.5 × 20.5 mm (0.6″ × 0.8″) Capable of operating bipolar stepper motors in full step, half step, quarter step, eighth step, and sixteenth step modes In full step, the driver has 200 steps per revolution which is 1.8 degrees per step. 4.5.2 CONTROL PINS These are the control pins which are used to control the where EN, SLP and RST control the power states and DIR and STEP control the input. STEP: This is the pin which controls the rotation steps (micro steps) of the motor. It will be connected with a digital pin of the Arduino board. When a high signal will be passed to this pin, the motor will move by one step. The speed of the motor rotation will change according to how soon the signal of the pin goes high. DIR: This is the pin which controls the direction of the rotation of the motor. This will also be connected to a digital pin of the Arduino. When a high signal is passed to this pin, the motor will rotate clockwise whereas if a low signal is provided instead, the motor will rotate in an anti-clockwise direction. EN: This is the enable pin. It is used to turn the outputs of the module on or off. A high signal will disable the outputs. By default, this pin is at a low state. RST: This is the reset pin. It sets the internal translator to a predefined home state which is the position where the motor starts initially. This position will vary depending upon the micro step resolution. This is an active low input where a HIGH signal will enable the driver. SLP: This is also an active low input pin which is used to reduce power consumption by setting the module to sleep mode when the motors are not in use. This is achieved by supplying a low signal to this pin. 16 4.6 0A51SK0F Infrared Distance Sensor GP2Y0A51SK0F is a distance measuring sensor unit, composed of an integrated combination of PSD (position sensitive detector), IR-LED (infrared emitting diode) and signal processing circuit as shown in the figure 4.4. The variety of the reflectivity of the object, the environmental temperature and the operating duration are not influenced easily to the distance detection because of adopting the triangulation method. This device outputs the voltage corresponding to the detection distance. So, this sensor can also be used as a proximity sensor. Fig 4.4 Infrared Distance Sensor 4.6.1 SPECIFICATIONS Distance measuring sensor is united with PSD, Infrared LED and signal processing circuit Short measuring cycle (16.5ms) Distance measuring range: 2 to 15 cm Compact size (27.0 × 10.8 × 12.0mm) Analog output type. 4.6.2 APPLICATIONS Distance Measuring Sensor Unit Measuring distance: 2 to 15 cm Analog output type 17 4.6.3 SCHEMATIC Fig 4.5 Schematic Diagram of Infrared Distance Sensor 4.6.4 ABSOLUTE MAXIMUM RATINGS Table No 4.2 Absolute Maximum Ratings 4.6.5 OPERATING SUPPLY VOLTAGE Table No 4.3 Operating Supply Voltage 18 4.7 MICRO SD CARD SHIELD The micro-SD card module contains two main components that make it undoubtedly easy to add data logging to your next Arduino project: Fig 4.6 Micro SD Card Shield The operating voltage of any standard micro-SD Cards is 3.3 V. So, we cannot directly connect it to circuits that use 5V logic. In fact, any voltages exceeding 3.6V will permanently damage the micro-SD card. That’s why; the module has an onboard ultra-low dropout regulator that will convert voltages from 3.3V – 6V down to ~3.3V. There’s also a 74LVC125A chip on the module which converts the interface logic from 3.3V-5V to 3.3V. This is called logic level shifting. That means you can use this board to interact with both 3.3V and 5V microcontrollers like Arduino. There are actually two ways to interface with micro-SD cards – SPI mode and SDIO mode. SDIO mode is way faster and is used in mobile phones, digital cameras etc. But it is more complex and requires signing non-disclosure documents. For that reason, hobbyist like us will likely never encounter SDIO mode interface code. Instead, every SD card module is based on ‘lower speed & less overhead’ SPI mode that is easy for any microcontroller to use. 19 4.7.1 MICRO SD CARD MODULE PIN OUT Fig 4.7 Micro SD Card Module Pin Out VCC pin supplies power for the module and should be connected to 5V pin on the Arduino. GND should be connected to the ground of Arduino. MISO (Master In Slave Out) is SPI output from the Micro SD Card Module. MOSI (Master Out Slave In) is SPI input to the Micro SD Card Module. SCK (Serial Clock) pin accepts clock pulses which synchronize data transmission generated by Arduino. SS (Slave Select) pin is used by Arduino (Master) to enable and disable specific devices on SPI bus. 4.8 MICRO SD CARD (TF CARD) A TF card is basically a small version of an SD card with similar functionality. Hence, this card is also known as a micro-SD card as shown in the figure 4.8. Fig 4.8 Micro SD Card A TF, or a Trans Flash card was developed and launched by SanDisk and Toshiba in 2004. Due to its dimensions (11x15x1mm), this card is one of the most widely used small storage devices. 20 4.9 12V POWER SUPPLY The SMPS Power Adaptor – 12V/2A (Power supply) is a Switched mode power supply (SMPS). This is the advanced power supply and better than conventional ones. If you want low losses and stable output also you don’t want to make a rectifier, so go for SMPS. You can use this SMPS Power Adaptor – 12V/2A to power-up the Arduino UNO/Arduino MEGA, DC motors, LCD screens, DVD players, Hard Drives, Audio Gear, and most other digital devices use less than 2 Amperage as shown in the figure 4.9. The high-quality AC to DC Switching Power Adapter which gives a clean regulated 12VDC output at up to 2A. These adapter work with 240VAC input, allowing them to work with household supply. The barrel plug attached to these wall adapters are center positive with 2.1mm diameter. It is an AC 100~240V to DC 12V 2A Power Adapter, Buck Converter, Switching Power Supply, Transformer, Charger, Applied to the Charging equipment etc. Fig 4.9 12V Power Adaptor 4.9.1 SPECIFICATIONS Input Voltage: 100-240VAC, 50/60Hz Output: 12V 2A Output Adapter: 5.5mm x 2.5mm PWM design, make sure the stability and high efficiency of power supply. Anti-jamming, passed EMC test, wave less than 20MV. Efficiency above 80%, exothermal less than 25 degree Function: with overvoltage protection, short-circuit protection, overload protection 21 4.10 BREADBOARD A breadboard, or protoboard, is a construction base for prototyping of electronics. Originally the word referred to a literal bread board, a polished piece of wood used when slicing bread.In the 1970s the solder less breadboard (plug board, a terminal array board) became available and nowadays the term "breadboard" as shown in the figure 4.10. Because the solder less breadboard does not require soldering, it is reusable. This makes it easy to use for creating temporary prototypes and experimenting with circuit design. For this reason, solder less breadboards are also popular with students and in technological education. Older breadboard types did not have this property. A strip board (Vero board) and similar prototyping printed circuit boards, which are used to build semi-permanent soldered prototypes or one-offs, cannot easily be reused. A variety of electronic systems may be prototyped by using breadboards, from small analog and digital circuits to complete central processing units (CPUs). Compared to more permanent circuit connection methods, modern breadboards have high parasitic capacitance, relatively high resistance, and less reliable connections, which are subject to jostle and physical degradation. Signaling is limited to about 10 MHz, and not everything works properly even well below that frequency. Fig 4.10 Breadboard 4.10.1 LIMITATIONS Solder less breadboards usually cannot accommodate surface-mount technology devices (SMD) or components with grid spacing other than 0.1 inches (2.54 mm). Further, they cannot accommodate components with multiple rows of connectors if these connectors do not match the dual in-line layout it is impossible to provide the correct electrical connectivity. 22 Sometimes small PCB adapters called "breakout adapters" can be used to fit the component to the board. Such adapters carry one or more components and have 0.1 inches (2.54 mm) spaced male connector pins in a single in-line or dual in-line layout, for insertion into a solder less breadboard. Larger components are usually plugged into a socket on the adapter, while smaller components (e.g., SMD resistors) are usually soldered directly onto the adapter. The adapter is then plugged into the breadboard via the 0.1 in (2.54 mm) connectors. Very complex circuits can become unmanageable on a solder less breadboard due to the large amount of wiring required. The very convenience of easy plugging and unplugging of connections also makes it too easy to accidentally disturb a connection, and the system becomes unreliable. 4.11 JUMPER WIRES Fig 4.11 Jumper Wire A jumper wire is an electric wire that connects remote electric circuits used for printed circuit boards as shown in the figure 4.11. By attaching a jumper wire on the circuit, it can be shortcircuited and short-cut (jump) to the electric circuit. A jump wire (also known as jumper, jumper wire, DuPont wire) is an electrical wire, or group of them in a cable, with a connector or pin at each end (or sometimes without them – simply "tinned"), which is normally used to interconnect the components of a breadboard or other prototype or test circuit, internally or with other equipment or components, without soldering. Individual jump wires are fitted by inserting their "end connectors" into the slots provided in a breadboard, the header connector of a circuit board, or a piece of test equipment. 23 4.12 M8 LEAD SCREW AND NUT A lead screw (or lead screw), also known as a power screw or translation screw, is a screw used as a linkage in a machine, to translate turning motion into linear motion. Because of the large area of sliding contact between their male and female members, screw threads have larger frictional energy losses compared to other linkages as shown in the figure 4.12. They are not typically used to carry high power, but more for intermittent use in low power actuator and positioner mechanisms. Leadscrews are commonly used in linear actuators, machine slides (such as in machine tools), vises, presses, and jacks. Leadscrews are a common component in electric linear actuators. Fig 4.12 Lead Screw Leadscrews are manufactured in the same way as other thread forms (they may be rolled, cut, or ground). A lead screw is sometimes used with a split nut (also called half nut) which allows the nut to be disengaged from the threads and moved axially, independently of the screw's rotation, when needed (such as in single-point threading on a manual lathe). A split nut can also be used to compensate for wear by compressing the parts of the nut. A hydrostatic leadscrew overcomes many of the disadvantages of a normal leadscrew, having high positional accuracy, very low friction, and very low wear, but requires continuous supply of high-pressure fluid and high precision manufacture leading to significantly greater cost than most other linear motion linkages. 24 A nut is a type of fastener with a threaded hole. Nuts are almost always used in conjunction with a mating bolt to fasten multiple parts together. The two partners are kept together by a combination of their threads' friction (with slight elastic deformation), a slight stretching of the bolt, and compression of the parts to be held together. In applications where vibration or rotation may work a nut loose, various locking mechanisms may be employed: lock washers, jam nuts, eccentric double nuts, specialist adhesive thread-locking fluid such as Loctite, safety pins (split pins) or lockwire in conjunction with castellated nuts, nylon inserts, or slightly oval-shaped threads. 4.12.1 ADVANTAGES The advantages of a leadscrew are: Large load carrying capability Compact Simple to design Easy to manufacture; no specialized machinery is required Large mechanical advantage Precise and accurate linear motion Smooth, quiet, and low maintenance Minimal number of parts Most are self-locking (cannot be back-driven) 4.13 8MM SMOOTH ROD These are the smooth rods used for 3D printer kits. They’re made of chrome-plated highcarbon steel and provide smooth, consistent motion when paired with linear bearings. These smooth rods are manufactured for use in 3D printers, Hydraulics as well as in CNC / linear motion applications, are stand up to frequent use without a problem as shown in the figure 4.13. In the robotics field, these smooth metal rods are usually used on the axis for 3D printers or CNC engraving machines to slide on. This rod comes in various lengths and body diameters, we made it available for our Makers. 25 Fig 4.13 8mm Smooth Rod After rigorous inspection, the last important thing is safe packing. Anti-rust oil is to be sprayed on the rod surface and each rod is to be packed in a paper sleeve and then in the wooden box. 4.13.1 FEATURES High precision, high hardness, high stability. Strictly control every precision process to ensure quality. Simple design, durable material, high temperature preheat treatment, accurate outer hole size. Due to its moderate hardness, it has been applied in many fields. Made of stainless steel, high corrosion resistance, high strength and wear resistance to maintain its efficient operation. 4.14 SC8UU LINEAR MOTION BEARING SC8UU 8mm Linear Motion Ball Bearing Slide Block Unit for CNC 3D Printer is used on hardened steel shafts as shown in the figure 4.14. This is ideal for small CNC applications. The universal Ball Bearings are easy to replace when it is damaged to improve the machine efficiency and save energy. This linear slider is widely used in home appliances, industrial, low noise and high-speed electric motors, construction machinery, automotive components, pumps, and machinery. Smooth moving, low friction, high rigidity, and long life. Economical, easy to maintain replace. This linear bearing is great for 3D printer’s small routers, CNC and robotics. 26 Fig 4.14 SC8UU Linear Motion Bearing 4.14.1 SPECIFICATIONS Table No 4.4 Specifications of SC8UU Linear Motion Bearing Model SC8UU / SCS8UU Material Metal + Rubber Inner Diameter (ID) (mm) 8 Length (mm) 35 Width (mm) 30 Height (mm) 20 Weight (gm) 44 4.15 FLEXIBLE COUPLING 5MM TO 8MM A coupling is a device used to connect two shafts together at their ends for the purpose of transmitting power as shown in the figure 4.15. The primary purpose of couplings is to join two pieces of rotating equipment while permitting some degree of misalignment or end movement or both. In a more general context, a coupling can also be a mechanical device that serves to connect the ends of adjacent parts or objects. Couplings do not normally allow disconnection of shafts during operation, however there are torque-limiting couplings which can slip or disconnect when some torque limit is exceeded. Selection, installation and maintenance of couplings can lead to reduced maintenance time and maintenance cost. 27 Fig 4.15 Flexible Coupling 5mm to 8mm 4.15.1 SPECIFICATIONS Type: Flexible Shaft Coupling Material: Aluminum Inner Hole Size: 5mm x 8mm Outside Diameter:19mm Length:25mm Main dimensions: d1=5mm, d2=8mm, D=19mm, L=25mm 4.15.2 FEATURES The structure is simple, easy to install, buffer, damping, convenient to disconnect. The size is complete and the surface is smooth. Story reversal characteristics are identical, The elastic connection, you can absorb vibration, compensate radial, angular and axial misalignment. Shaft coupler often used to connect servo motor stepper motor, encoder screw driving machine platform, etc. 4.16 SHF8 8MM FLANGE MOUNTING This SHF8 flanged aluminum linear support bracket is used to secure linear shafting to an assembly as shown in the figure 4.16. It is light weight, strong and suitable for all shaft types. Many well-designed 3D printers, CNC machines and linear motion products make use of these end supports as they provide a convenient and firm method for securing 8mm linear shaft to the rest of the machine’s assembly, making use of two holes in the block’s foot. 28 Fig 4.16 SHF8 8mm Flange Mounting Due to the precise machining of the block itself, you can be confident that your linear shafting sits true to the rest of your CNC machine or 3D printer, resulting in a high-quality product. The rod is physically secured via a slit in the block, where a clamping screw is used to tighten the aluminum around the shaft. This friction clamping force, combined with a dab of lock tight on the screw thread will create a failsafe connection, one that is an engineering industry standard. 4.16.1 SPECIFICATIONS Table No 4.5 Specifications of SHF8 8mm Flange Mounting Model SHF8 Material Aluminium Compatibility 8mm Linear Shaft Clamping Bolt Size M4 Mounting Bolt Size M5 Mounting Hole Distance 32mm 29 CHAPTER 5 DESIGN LAYOUT The 3D scanning device created in this project will be based on the mechanisms [2] of the scanner depicted in Figure 5.1. It will consist of a rotating platform and an elevator mechanism, both of which will help scan the entire object. The object will sit on the platform and the distance sensor will be mounted on the elevator which will move up and down by rotating a threaded rod passing through a nut fastened in the middle of the elevator. Fig 5.1 Design layout of 3D Scanner In order to scan solid 3D objects, the authors made use of a very simple method. It consists of taking distance measurements from a solid 3D object that is subjected to a controlled rotation. After each revolution of the object, distance measurements need to be taken at a different height of it. In this manner, the silhouette of the object can be obtained in every revolution it does by gathering the distance measurements and corresponding rotation degrees. The silhouette distances are obtained by the difference between a fixed distance and distance measurements. The 3D scanner device designed to accomplish this goal is comprised of three elements: an electromechanical structure, a data acquisition hardware and a point cloud to STL. These elements and their functionality are described as followed. 30 5.1 ELECTROMECHANICAL STRUCTURE There are two stepper motors attached to the electromechanical structure [7], one of them controls the vertical movement of the 1D optical distance sensor and the other one controls the rotation of the platform that supports objects that are to be scanned. The sensor is mounted on a toothed belt and pulley arrangement. The structure disassembled. The stepper motor that controls the platform rotation needs 200 full steps to execute a complete revolution, leaving a resolution of 1.8º per step. The other stepper motor has a reduction gear box included that gives it enough torque to move the sensor. 5.1.1 SPINNING PLATFORM The spinning platform is powered by a NEMA 17 Stepper motor which rotates 1,8° per step, or 200 steps per revolution [2]. The object meant to be scanned will sit on the surface of the platform and rotate around the stepper motor’s axis of revolution. The motor is larger and more powerful than necessary for most light objects, but this problem was counteracted in a couple of ways. Firstly, by adding friction to the spinning platform’s surface and secondly, by reducing the motor’s torque. The added friction to the surface helps the object stay in place and not slip when the motor takes very aggressive and distinct steps. 5.1.2 ELEVATOR MECHANISM AND DISTANCE SENSOR The elevator is powered by a NEMA 17 Stepper motor stepper motor its only purpose is to move the distance sensor up and down to collect all the necessary point data. On either side of the stepper motor there is a steel rod to guide the sensor and keep it in place. The vertical motion of the elevator is made possible by spinning a threaded rod through a nut resulting in a moved distance equal to the lead of the thread per full revolution. The transmission of the motor’s torque to the threaded rod is achieved through the use of a shaft coupling [2]. 5.2 DISTANCE SENSOR A distance sensor is a component that measures the distance between itself and the nearest object straight ahead of the sensor by combining both a transmitter and receiver [4] in one component. The accuracy of the distance measurements heavily depends on the characteristics of the sensor used. In this project we used the GP2Y0A51SK0F infrared distance sensor, which is a low cost 1D laser sensor that is widely used on industrial applications. Its measurement range limits are from 2-15mm. It can be configured to provide an analogue output signal that can be voltage (0-10V) or current (4-20mA). 31 5.3 POINT CLOUD TO STL Place the object on the turntable in the middle. Connect power supply and wait for the machine to home itself. When reached, press the scanning push button and wait. Depending on the layer height you choose and object size it will take more or less to complete. Once complete, remove the SD card. Remove the SD card and copy the file to your PC. The file should have the next format. Three columns separated by a comma with the values of the x, y, and z coordinates. This are just points in a format of a point cloud. To obtain an STL file, we use the MESHLAB software To be able to create a three-dimensional visualization in a computer, software able to process the point data is needed. Each measurement from the distance sensor corresponds to a point in a Cartesian coordinate system. The point cloud, which is a large collection of points, will be converted to a mesh using MeshLab. The mesh is a collection of triangular connections between the points in the point cloud. This creates a surface with the purpose of resembling the scanned object as closely as possible. 32 CHAPTER 6 CIRCUIT DIAGRAM The circuit diagram of the 3D Scanner as shown in the figure 6.1. The stepper motors are controlled by Arduino and the Readings are stored in the SD card all the functions are controlled and monitored by Arduino. Fig 6.1 Circuit Diagram 6.1 SOFTWARE This section will cover the Arduino code and the software used to import the point data and convert it to a mesh ready to be 3D printed. 6.2 COLLECTING DATA POINTS The data collecting software is represented by the flow chart and is based around a Cartesian coordinate system that is centered in the middle of the object-rotating plate. Since the height, angle and distance are all known or measurable parameters but are not known in terms of x, y and z, a translation is needed. As shown in Figure 6.2, a point on the rotating plate can be interpreted as a point on a cylinder and therefore cylindrical coordinates are used to determine x, y and z: x = r · cos θ y = r · sin θ z=z 33 Fig 6.2 Object-rotating plate Point A is the measured Point and Point B is the coordinate calculated adjusted for the rotation Where θ is the known rotation of the object, z is the known height of the elevator/sensor and the radius r is calculated by: r = distance to plate center − measured distance 6.3 FLOW CHART OF THE PROGRAM THAT COLLECTS AND SAVES DATA POINTS Fig 6.3 Flow Chart 34 6.4 SAVING DATA POINTS In order to save the collected data points to a readable document, a text-file micro-SD card module is used. This module is allowing the user to save all the information that is printed to the Arduino’s serial monitor and is thus very useful in this project. 6.5 VISUALIZATION In order to visualize the object and initiate the reverse engineering process in the computer, the points are imported as a text file with each row containing an x-, y-, and z-coordinate. This project made use of MeshLab to convert the points to a mesh and export it as an STL-file able to be 3D printed. A generic example of this process can be seen in Figure where 10,000 points were randomly generated on the boundaries of a parameterization of a torus as shown in the figure 6.4. Fig Points Fig Mesh Fig 6.4 An example of the conversion from points to a mesh using MeshLab 35 CHAPTER 7 SOFTWARE DESCRIPTIONS There are two software are used in our project. First one is the Arduino IDE that is used to write and upload the code to the Arduino Nano, and the another one is the MeshLab it is used to Mesh the coordinate points to the STL file. 7.1 ARDUINO IDE Arduino is an open-source project that created microcontroller-based kits for building digital devices. It is a programmable microcontroller for electronic and mechanical devices. It can easily connect digital and analog electronic signals such as sensors (GPS, Wi-Fi, Bluetooth). The IDE environment mainly contains two basic parts: Editor and Compiler where former is used for writing the required code and later is used for compiling and uploading the code into the given Arduino module. The main code, also known as a sketch, created onthe IDE platform will ultimately generate a Hex File which is then transferred and uploaded in the controller on the board. The Arduino IDE supplies a software library from the wiring project, which provides many common input and output procedures. It is designed to introduce programming to artists and other users unfamiliar with software development. It includes a code editor with brace matching, automatic indentation, API lookup, capable of compiling and uploading programs to the board. The Arduino Integrated Development Environment contains a text editor for writing code, a message area, a text console, a toolbar with buttons for common functions and aseries of menus. It connects to the Arduino and hardware to upload programs and communicate with them. 7.1.1 ADVANTAGES OF USING ARDUINO SOFTWARE Arduino IDE is a cross-platform. It is inexpensive. The number of library of examples present inside the Arduino software. It is open source and extensible hardware &software. It is simple and clear programming environment. 36 7.1.2 FEATURES It is an open source. It is cheap comparing with other programming language. It can communicate with a computer via serial connection over USB. It can be powered from USB or standalone DC power. 7.1.3 APPLICATIONS Laboratories Aerospace Industries Traffic Control System Automatic vehicle control Smart Home Medical 7.2 MESHLAB Download and install MESHLAB with the default install. Open MeshLab and go to file, import mesh. Here opens the scanned file. In the next window select XYZ format and as a separator select the comma ','. Now the point cloud is open. We have to give normal to the points. For that go to filter, normal curvature and orientation, compute normal for point set and in this window play with the settings. 10 was a good number. Click apply and close the window. The processes are shown in the figure 7.1. 37 Fig 7.1 Steps to Convert the Cloud points to STL file Now go to filter, remeshing simplification and reconstruction and here selects screened Position surface reconstruction. Play with the settings if you want and then click apply. Close the window and there we have our file. Fig 7.2 Mesh File 38 CHAPTER 8 COST ESTIMATION Table No 8.1 Cost Estimation S.NO PART NAME QUANTITY COST TOTAL COST 1 Stepper Motor 2 500 1000 2 Stepper Motor Driver 2 150 300 3 Arduino & Sd Module 1 1200+200 1400 4 IR Sensor 1 700 700 5 5mm to 8mm Flexible Coupling 1 250 250 6 M8 Threaded Rod and M8 Nut 1 450+100 550 7 8mm OD Plain Rod 2 200 400 8 8mm Bearing 2 300 600 9 8mm Flange Mount 2 200 400 10 Breadboard 1 200 200 11 Jumper Wires 1 150 150 Total Rs 5950 Manufacturing Parts Cost = Rs 500 Total Cost = 5950 + 500 = Rs 6450 39 CHAPTER 9 RESULT Fig 9.1 Base of The Project (3D scanner) The above figure 9.1 is a base frame of the project. It consists of a frame with smooth rod and threaded rod which placed in vertical position(z-axis). It also has a frame for two stepper motor for object and IR sensor respectively. Fig 9.2 Arduino, Stepper Motor and Power Supply of 3D scanner 40 Arduino is mainly used to control our project it attaches with CNC shield with the stepper motor driver. Stepper motor is used to rotate the object and IR sensor. For this project we supply 12 V 2A power supply. We test the project before fixing it to the frame as shown in the figure 9.2. Fig 9.3 IR Sensor and Scanning Object We placed IR distance sensor along with threaded rod in z-axis. It has a smooth rod giving support to the threaded rod which is attached with the coupler and stepper motor. And object motor is placed in x-axis as shown in the figure 9.3. 41 CHAPTER 10 CONCLUSION The 3D scanner device developed in this project was tested to prove the effectiveness of the proposed scanning method. It was demonstrated that the resolution of the 3D virtual objects depends on the characteristics of the surface of the objects, material texture, dimensions of the object and of course the sensor resolution and stability of its output analogue signal. The 3D scanner device proved to have very good accuracy according to the calculated values. The results obtained so far are very promising, especially because the total cost of the designed device was under 10K. As future works, the authors will try to improve the stability of the analogue output signal and to duplicate the resolution of 3D virtual objects by programming the stepper motor, that controls the rotating platform, to work in half-step mode. Finally, to use this 3D scanner device in more specialized applications such as manufacture, it will be necessary to use another 1D optical distance sensor with a higher resolution. 42 REFERENCE [1] "A 3D Scanning system based on laser Triangulation and variable field of view," Department of Informatics, Systems and Telematics. [2] R. Gupta, H. Chaudhari. A Literature Review on Low-Cost 3D scanning using Structure Light and Laser Light Scanning Technology. International Journal of Innovative Research in Science, Engineering and Technology. Vol.6, Issue 7, July 2017. [3] V.N.Chougule, H.S.Gosavi, M.M.Dharwadkar, A.A.Gaind, Review of Different 3D Scanners and Scanning Techniques, IOSR Journal of Engineering, 2018. [4] Mahesh Parde, Karan Khankal, Thotya S, R.S.Meshram, Implementation of 3D Scanner Using IR Distance Sensor, Electronic & Telecommunication KGCE Karjat India, Volume4, Issue-2, 2018. [5] Research and Development of 3DModeling, Xi-Dao LUAN, Yu-Xiang XIE, Long YING and Ling-Da WU ’School of Information System and Management, National University of Defence Technology, Changsha 410073’. [6] ‘3D Laser Scanners’ Techniques Overview Mostafa Abdel-Bary EBRAHIM Professor, Civil Engineering Department. Faculty of Engineering - Rabigh, King AbdulAziz University. Kingdom of Saudi Arabia. Impact Factor (2014). [7] Characterization of a Large, Low-Cost 3D Scanner Jeremy Straub 1, *, Benjamin Kading 2, Atif Mohammad 1 and Scott Kerlin 11 Department of Computer Science, University of North Dakota, 3950 Campus Road, Stop 9015, Grand Forks, ND 58202, USA2 Department of Mechanical Engineering, University of North Dakota, 243 Centennial Drive, Stop 8359, Grand Forks, ND 58202, USA. 30 January 2015. 43