An Object Detection and Identification System for a Mobile Robot Control

The one of the features of mobile robot control is to detect and to identify objects in workspace. Especially, autonomous systems must detect obstacles and then revise actual trajectories according to new conditions. Hence, many solutions and approaches can be found in literature. Different sensors and cameras are used to solve problem by many researchers. Different type sensors usage can affect not only system performance but also operational cost. In this study, single camera based obstacle detection and identification algorithm was developed to control omni-drive mobile robot systems. Objects and obstacles, which are in robot view, are detected and identified their coordinates by using developed algorithms dynamically. Developed algorithm was tested on Festo Robotino mobile robot. Proposed approach offers not only cost efficiency but also short process time.

Manuscript received April 06, 2017; accepted July 09, 2017.DOI: 10.17694/bajece.336480However, using LiDAR in mobile robots increases the cost considerably.Manufacturers must find and develop new is image processing.In this kind of systems, images captured from one or more cameras are processed by a computer (or microprocessor-based controller) which is located inside or outside of the mobile robot [1].Various operations are performed on processed images to detect objects and according to results robot trajectory is re-determined and calculated by controller [7][8][9][10][11][12][13][14].In general, this technique which uses a single camera provides significant cost advantages.However, it is difficult to process streaming images from camera by using low capacity microprocessors [10].In this study, an object detection and identification algorithm is developed using a low-cost camera to re-determine and planning of mobile robot trajectory.The developed algorithm is tested on the simulation software of Festo Robotino mobile robot and the results are examined.The paper is organized as follows.In section II, brief information is presented for Festo Robotino Mobile Robot (Robotino).In section 3, the structure of the developed object detection and identification system 2 is presented.The case studies and results are presented in section 4. In the last section, the obtained experimental results are discussed.

II. FESTO ROBOTINO MOBILE ROBOT
Robotino is an omni-drive mobile robot platform which is produced by Festo [15][16].It is shown in Fig. 1.Technical properties of the Robotino are listed in Table 1.The embedded micro-controller of Robotino has ROS (Robotic Operating System) and controls wireless communication, sensors, speed mode [15][16].By using the encoder which is inside of 1.72AP version embedded software, x-y position and z-orientation can be easily obtained.Using the IEEE 802.11g standard, x-y coordinates and angular velocity information can be easily transmitted to Robotino [15][16].Algorithms, which are validated in the simulation environment, can be integrated into the real system.And also, developers can develop their own simulation tool and/or control software by using Matlab, Visual Studio, Java or C/C++.Robotino support these programming platforms.In order to execute the commands on the robot, the connection between the robot and the computer must be activated firstly.For this, the following pseudo-code command lines which is shown in below must be run on Matlab and Visual Studio platforms to load and initialize the robot-computer and computer-robot data communication protocol [17]."robotinoAPI" and "robotinoIP" parameters can be various from Robotino versions [17].Detailed information about Robotino can be found in [15-

III. OBJECT DETECTION
Object detection algorithm which is consist of six steps was developed by using Matlab.The flow chart of developed algorithm is shown in Fig. 2. In first step, images which is captured from video stream by camera are classified and labeled by colors.In the labeling process, each object is expressed as a matrix consisting of three main colors as shown in equation (1).In (1), Rn is 80x80 red color matrix, Gn is 80x80 green color matrix and Bn is 80x80 blue color matrices, respectively.In the next step, the colors of the objects with 16 essential colors in the RobotinoSim tool are defined according to the RGB codes to be used in the BLOB analysis 18].RGB → GRAY color conversion is performed on the detected image before this operation.And then, BLOB analysis is performed on labeled sections [18].The BLOB analysis provides the coordinates, width and height information of the objects in the live video stream which is separated by sections at first step.The detected objects on the live video stream are marked by using "Bounding Box" method.This method produces B matrix which is shown in equation (2).
In (2), where Bn represents an object in bounding box, n is the number of detected objects.x1, x2, y1 and y2 represent coordinates of the objects on live video stream.h1, h2, w1 and w2 represent height and weight of the object.The matrix which is shown in equation 3 is obtained from the BLOB analysis.
BOn is a 4xn matrix where n is the number of detected objects.In this way, coordinates, height and width information of detected objects are obtained.If the dimensions of the objects are in limits which are between 15 and 70 pixels for this study, On matrix which is shown in ( 1) is obtained for each object.On matrix is necessary to classify each object by color.
In the next section, results of experimental studies which are performed in simulation are presented.

IV. CASE STUDIES
Test environment is created by using RobotinoSim simulation tool [17] for testing proposed algorithm.The codes which is written in Matlab are compiled on RobotinoSim.Views of the object detection experiments are shown in Fig. 3-7.For each experiment, robot -computer connection is set and tested at the beginning.In Robotino Sim, basic 16 colors are used to create objects.Basic colors are preferred because of using any color filters for filtering color tones.Different shapes have been created as objects such as cylinder, cube, rectangular parallelepiped etc.It is assumed that the test setup is in constant light intensity.Figures 3-7 show detection of different objects.Figure 3 shows the process of detecting a yellow cylindrical object in the range of 15-70 pixels width and 15-70 pixels height in live video stream.
Fig. 4 shows the process of detecting a yellow cylindrical object when robot is approaching to the object.The choice of the range of 15-70 pixels is to limit the reasons for objects to a certain size.In this view, changes over and under a certain size are automatically filtered.These dimensions can be changed if desired.

V. CONCLUSION
In this study, detection and identification of objects in the real environment, which is one of the most important topics in mobile robot control, have been performed.By using the developed algorithm, images which are obtained from a lowcost single camera are captured and the objects which have different colors and shapes in the work space of the robot are detected and identified.The main aim of the proposed approach is to detect any kind of objects which are in work space of robot by using only low-cost single camera without an extra equipment.According to experimental results, proposed approach provides detection of all objects which are fit in determined dimension range in robot work space.And, all detected objects are labeled and marked on live video stream.By using these steps, robot can easily calculate coordinate of each object.Performance of the proposed approach is observed during experimental studies.According to our observation results, proposed approach is performed with high success rate and low calculation time.As a future work, classification of detected objects will be done by artificial neural network for developing autonomous behavior.

Fig. 5 .
Fig. 5. Detection of red object from far position.

Fig. 6 .
Fig. 6.Detection of red object from near position.

Fig. 5
Fig.5shows the process of detecting a rectangular prismatic object with a width size of 15-70 pixels and a height size of 15-70 pixels in real time.Fig.6shows the detection of a red square prismatic object when robot is approaching to the object.

Fig. 7
Fig. 7 shows the process of detecting the green cylindrical object in the range of 15-70 pixels width and 15-70 pixels height during live video stream in the real-time.

TABLE 1
RobotinoSim and RobotinoView software which are developed by Festo offer simulation environment for Robotino. 17].