On a 3 D scanning robot system design problem

Performing the scanning of the human body by means of conventional scanners, we faced the challenge of data insufficiency. In this given paper we present a new solution to this problem, comprising industrial robots application. Our purpose was to develop a fully functional, accurate, cheap and safe 3D scanning system based on a 6DOF industrial robot applications.


Introduction
3D scanning has been an active area of research for more than two decades.Various types of 3D scanning systems are used in industry, in particular for industrial applications.Nowadays the demand for 3D models of human body has drastically increased.As a result, now there are many systems available that are optimized for extracting accurate measurements of the body and modelling the whole surface almost automatically [1].
A classical approach to building human body models uses 3D scanners [2][3][4].They are quite expensive but simple to use and various softwares are available to model the resulting measurements.They work according to different technologies (laser line, structured light) and provide millions of points with often related colour information.Some other techniques are based on silhouette extraction or multi-image photogrammetry [5,6].
Manufacturing and clothing industries are adopting systems and technologies that enable their customers to visualize themselves in a garment before buying it [7].However, such devices are highly expensive and therefore are only available for special anthropometric studies.
Moreover there is an essential problem that arises during the image-capturing.This is so-called gaps and image irregularity which could appear if we want to scan a body of complex shape, like the human body.It is almost impossible to get a clear representation of some of the body's "hidden" parts using stationary or sliding in vertical or horizontal directions cameras and lasers.
We propose to implicate an industrial robot equipped with laser range finder mounted on its end effector for solving these problems.

Why Industrial Robot?
The first commercial application of industrial robot took place in 1961, when a robot was installed to load and unload diecasting machine.In fact, many early robot applications were in areas where a high degree of hazard or discomfort to humans existed.The fields were: welding, painting, and foundry operations, etc.In recent years, robots have been used in applications where they offer economic advantages, increase productivity and quality by means of higher flexibility, accuracy, repeata-bility, dexterity and rate of consistency over the other automated machines replacing human workers.
The main benefit of using an industrial robot with 6DOF or 5DOF in our work is its maneuverability and high range of accuracy according to the advance extent of its control and safety system.As it was mentioned above, performing the scanning of the human body we faced the challenge of data insufficiency.In other words, it was revealed that some points could not have been obtained by simple motion of the scanning system.Hence, it was decided to implement a more flexible measuring instrument.The robot can reach these fields quite rapidly, with an utmost precision, producing maximum efficiency and being a complement part of the measuring system.
The current stage and function of the system is the detection of the blind points after general scanning of complex objects, considering the shape using robot scanning system and transferring the data to image processing software for acquiring the composite picture of complex geometry object, for instance: human body (or parts).
This kind of application of industrial robot manipulator with 6DOF or 5DOF is quite unconventional and new.We use the universal robot that can be easily switched-over its product orientation and fulfil the task in other applications by reprogramming and changing the tool.

Human Robot Interaction
The object of scanning is represented by a human being, that is why we need to take into close consideration the safety issues in view of possible hazards that can be caused by the robot.A key issue hampering the entry of robots into unstructured human environments is safety [8,9].To ensure this the complete system must incorporate safe mechanical design, human-friendly interfaces and safe planning and control strategies.
For instance, control system must be failsafe, reliable and simple in usage with human-engineered interface.All movements, data-signals transfer must be synchronized for rapid, efficient model acquisition that can also improve the control.The safety devices, guard systems should be properly chosen; the maintenance of rules, standards, hazard estimation and elimination must be conducted.
For example, according to ANSI/RIA standards for Industrial Robots and Robot Systems the following elements should be contained: Actuating controls for protection from unintended operation (guarded push-button, key selector switch, two-handed control); remotly located controls (teach pendant); programmable safety circuits, robot stopping circuits (emergency stop); motion, speed control, space restricted safeguarded devices such as: mechanical stops, adjustable mechanical or non-mechanical, dynamic limiting devices, limit switches, safety mat system, light curtains, laser scanning devices, pull cords, interlocked barriers.All safe-guarded devices shall be securely installed and located at distance such the hazard can not be accessed.This distance can be calculated using the following equation (1) [10]: Where: D s min safe distance between safeguarding device and the hazard; K speed constant (1,6 m/sec); T s machine worst stopping time; T c control system worst stopping time; T r response time of the safeguarding device; D p f maximum travel towards the hazard within the presence sensing safeguarding devices (PSSD).Taking into account the specifics of the robot application, assessment and hazard identification were performed.Using the possibility of avoidance, degree of severiy and exposure criteria for given task, the risk reduction category was determined as R1, that means strict protection of personnel involved in task performance.The question of safety will be considered more detailed in the next papers.In present work we focused on the design processes, control system and interfaces.

Application Solution and Elements of the System 4.1 Range-finder
For our research we decided to use a simple and cheap device, a laser distance-measurer Stabila LE [11], that uses a TOF (time-of-flight) technique to measure the distance.It consists of a transmitter, one or two receiver channels and a time measuring unit (Fig. 1).The transmitter consists of the laser and pulsing electronics.A compatible PC is used for collecting the measurement results, controlling the optical attenuator and to adjust the parameters of the receiver channel.The measurement result is unambiguous and accurate both in horizontal and vertical directions, because the measurement beam is narrow and there is no danger of the target being hidden behind some other object in the scene.Transmitter and receiver beams a TIMING DIS-CRIMINATOR are coaxial and that the measurement accuracy does not depend on distance [12].

The KR6 robot features
For our task we implemented PUMA type robot KR6 [13](See Fig. 2), equipped with the KR C2 controller; six servo drive modules powered by the power supply.The interface between the controller, safety equipment and the servo drive modules is formed by the DSE (digital servo-electronics) and ESC (electronic safety circuit) with its Interbus interface.The controller is based on standard PC hardware with a powerful Celeron microprocessor and Windows-like user interface.The controller contains all the components and functions that are required to operate the robot.It is designed for realization of PTP, contour-following motions with linear and circular interpolation.Thus it covers a range of applications, from the simplest assembly tasks to more complex tasks which require continuous-path control.Programming is carried out in the KRL language.In addition there is a control panel, which is used for teaching and operating the KR C2 robot controller and thus constitutes the man-machine interface.The microcontroller sends keyboard and status data to the PC via a standard CAN bus, by which means it is initialized and parameterized by the controller.The display information is transferred serially via a separate high-speed interface.With its plug-in components, the computer unit built into the PC chassis performs all the functions of the controller: windows user interface with visual display and input; program creation, correction, archiving, and maintenance; diagnosis, start-up assistance; sequence control; path planning; control of the drive circuit; monitoring; parts of the ESC safety circuit; communication with external units (other controllers, host computers, PCs, network), etc.

Homogenous vectors and matrices
It is possible to receive data from robot control system as Cartesian co-ordinates of end effector and it is possible to get the data about Tool orientation in matters of Eulers angles e.g.rotational angles about X, Y, Z axis.According to Fig. 3 below, the homogeneous transformation matrix connecting the work co-ordinate system (xn, yn, zn, 1) homogeneous vectors with the world co-ordinates homogeneous vectors (X, Y, Z , 1) can be found like in [14]: Where l x = cos α 2 cos α 3 l y = sin α 2 sin α cos α 3 + cos α sin α 3 l z = cos α(− sin α 2 ) cos α 3 + sin α sin α 3 m x = cos α 2 (− sin α 3 ) m y = sin α 2 sin α(− sin α 3 ) x co-ordinate of the work co-ordinate system origin in world co-ordinate system r y y co-ordinate of the work co-ordinate system origin in world co-ordinate system r z z co-ordinate of the work co-ordinate system origin in world co-ordinate system α is rotational angle about x axis α 2 is rotational angle about y axis α 3 is rotational angle about z axis So we receive the co-ordinates of the measured point like it is shown below.
And if we organize the measurement in such a way that the laser device measures the distance along z n axis then to build the 3D image of the scanned object in our cas we need only last column from the result matrix (3).The robot working frame (including the laser measurement head) moves along the given path during 3D scanning.The path and the trajectory planning for this application is an important and interesting research and development topic.For the given application system the data synchronization was achieved by the application of additional wire/wireless connections and supplementary software, which essentially improved the work processing characteristics.In compliance with the principle of equipment elimination we used a wireless connection for KRC2 and PC (see Fig. 4).It gave us an opportunity to simplify the system and improve the work in the whole.By serial interface we connect LE to PC (See Fig. 5).In this case it is possible to operate the process of measurement using PC software via user interface.To connect the PC with the LE Unit and KR C2, a software application was developed on the basis of Borland Delphi 7.0 development environment.The developed software was used and synchronized with KRL programming for robot control.For better, faster, and more convenient data transfer between PC and KRC2 a wireless method was adopted.

User Interface
Interface was developed and designed with a purpose to make the system user-friendly, simple, and as convenient in usage as possible, and, at the same time, with high functional capabilities.User interface is represented by dialog application window which contains control elements and settings for robot system manipulation (see Fig. 6).Every button (status window, panel, boxes) has its own function and is responsible for certain task.

Measurement and Experiments
The sequence of events for system is shown in the Fig. 7: -  Some steps of system operations require parallel serial functioning, so to achieve stability in work and communications we created a data transfer protocol on the basis of RS 232 standard connection protocol.As the robot was working in close with human, we made several level of responding protocol, if something is wrong in communication or data, robot should not execute such command.Now this system is under construction and testing.

Experimental Results
In the course of our research the following experiments were carried out: After capturing co-ordinates of indefinite surfaces, robot was sent to predefined position and measurements were provided.According to received information and calculations (see chapter 5), 3D image was acquired.The robot path was performed in vertical plane.The result of scanning is presented in Fig. 8 and Fig. 9. On Fig. 8 at the left one can see the points, co-ordinates of which were calculated using Eq.(3), these points formed the structure of the scanned object.After they were built, triangular patches were set on these points.It was made without any additional calculations to achieve smooth surface.In Fig. 9 was provided by our colleague Lomonosov E. who uses special program with smoothing and as one can see the model looks much better.The experiment was made to check the calculations and Eq.(3).As we can see this equation and calculations were made right.The irregular surface of the reconstructed image is the result of the discreet data received from distance measurer unit and the strategy of scanning.As it was written above, scanning was provided perpendicular to the projection plane.It is possible to assume that if the scanning is performed following other trajectory, other words, if the measurement unit measures perpendicular to the measurement surface the result would be more precise and the reconstructed image became more smooth and realistic.It is important to note that the steps of measurement (e.g.discreet data) highly influence to the results of scanning.As result of the first experiment with the developed system we found that our future task is to research the maximum precision of the system.The precision of the system is influenced by the strategy of scanning and precision of the robot.Also we have to study the maximum possible speed of scanning which is influenced a lot by the rate of scanning device and is con-Fig.7. Algorithm of measurement strained by the minimum error we want to get.Although we obtained good results from our first experiment we should provide more research to receive the results which can be used in industry, especially manufacturing.

Future Research
Our future research will incorporate further investigations concerning this area.Namely, it is planned to widen the set optimization of the scanning algorithm and operated scanning time, integrate to the system elements for detailed video surveillance and events tracking with real-time data processing.Additionally, although the current software system meets the present requirements, it is expected to be adjusted and improved for the successful achievement of our final goals.We also would like to improve image dearness using achievements in computer vision and continue researches on the subject of safety in human robot interaction.

Conclusion
In conclusion we would like to point out that the possibilities of the modern industrial robots allow us to commission them into various areas quite different from manufacturing.Our experiment has shown that this approach to 3D scanning is promising very much in garment industry.The proposed system incorporates many elements with different functional capabilities which should be thoroughly considered and harmonized.It demands a lot of time, energy, and additional resources but we hope that this solution later will be widely adopted in textile or any industry.

Fig. 1 .
Fig. 1.Structure of the two-channel TOF laser range finder.

Fig. 5 .
Fig. 5. System elements interaction It contains: -Serial interfaces for robot and laser connection; -Setup of computer data; graphic tool orientation; -Visual model of scanning body; -Recording of motion flow (path); -Adjustable co-ordinate system, end-effector orientation; -Data application and start of measuring, internal network adjustments, transfer to the other computers; -Remote control; -Lasers manual control (system of commands); -Status window; -Sending/reading signals to/from range finder.Launching the KRC (robot controller) and the PC we have a possibility to turn on the LE unit and start our measurements by activating becoming buttons on the display of PC.This interface provides the user with: -Establish and change communication ports, modification of robot co-ordinates and their orientations (enter the Cartesian co-ordinates X Y Z , where end effector should be moved and indicate the orientation by changing its A(α 3 ), B(α 2 ), C(α) angles); -Robot, range finder pre-programming; -Capturing and tracking measured co-ordinates and sending them to the software for further 3D image processing; -Recording of robot movements combination; -Connect/disconnect laser range finder; -Log-in to the LAN, Internet, PDA, mobile technology; -Server/client state triggering; -Acquiring detailed image from scanning object; -Scanning processes observation; -Robot operate position determination; range finder status recognition.
Turn on the LE Unit, robot controller and communication device; -Start computer program; -Start robot program (Robot calibration, base position); -Receiving scanned object as a 3D image with problematic locations (blind points); -Sending (the) robot to this position according to the captured co-ordinates; -Measuring (scanning); -Getting the results; -Data transfer; -Waiting for the next request/ stop.Per.Pol.Mech.Eng.