In this project we designed an autonomous mobile robot for completing a given set of tasks using the WebotR2021a simulation platform. First of all let's look at the task.
Task
At the beginning, the robot is at a 25cm x 25cm square. Then we have to navigate the robot using line following until it meets the wall following area. After wall following, the robot enters a circular maze and it has been divided into four quadrants. Then, we have to navigate the robot to the colored box which is located in one of the four radius lines of the circular maze while indicating the quadrant numbers. After approaching the box, the robot has to identify the colors of bottom and front sides of the box in order to calculate the direction it needs to follow at the ramp section. After color detection, it has to pass a dash line section to enter the ramp area. Then, it has to select the correct direction which was calculated in the color detection phase. There are pillars in order to confirm whether the direction it took is correct or not. After that, it enters the gate section. There are two synchronous gates which operates in a given sequence but two gates have different sequences. Finally, the robot has to pass both of these gates without hitting them and stop at a 25cm x 25cm white square in order to complete the task.
Design & Implementation
1. 3D Modeling, Physics Modeling and Sensor Modeling
The whole robot corresponds to a CAD model and all the parts and mechanisms used here should be implemented in real world as well. We must always try to make the simulation that matches with the real world implementation. Otherwise there's no meaning of simulating a robot in an unrealistic way.
For designing the 3D model of the robot, we used SOLIDWORKS software. First, a complete CAD model was designed considering the real world implementation as mentioned above. There, we focused on size of the objects, material properties, weight distribution of the robot, and reliability and realization of mechanisms for every single peace of the robot. When modeling sensors, we did that according to sensor datasheets and considering Gaussian noise that will be added to sensor readings as well.
2. Line Following
Line following is one of the major tasks. In general we achieve this using an array of proximity sensors lies above the line. We used an array of 8 IR sensors placed in a constant distance apart from each other. We used a PID algorithm for line following.
3. Wall Following
We used sharp IR sensors for this sub task. Two sensors were placed vertically in left and right sides of the robot. A PID algorithm was used for this task as well.
4. Maze Solving
We designed a custom algorithm this. After entering to the maze, the robot navigates along its the circumference while indicating quadrant numbers. Then it enters one of the diagonals and moves along it until it detects the box. It it could not find the box in that particular diagonal, it turns right and enters the other diagonal after traveling through the circumference and go along it until detects the box.
5. Robot Arm Manipulator
According to the task, the robot has to detect colors of bottom and front sides of the box. Since we want to find the bottom color we designed a robot arm that grabs the box and lift it up in order to expose bottom side of the box to the color sensor. The color sensor is also attached to the robot arm, and it is connected to a servo motor. Then the color sensor rotates in 90 degrees steps to get the colors of front and bottom sides.
6. Ramp Section
In order to navigate through ramp area properly, we did 3D modeling of the robot and placement of hardware (specially the battery - the heaviest part in the robot) by preserving the center of gravity of the robot as low as possible and preserving the balance of the robot. In the test runs we experienced that the robot turns unexpectedly at the half way, climbing the ramp. The reason was that the placement of battery. By adjusting its position we could solve that problem. Another problem we encountered in ramp section is that when the robot enters the top of the ramp and leaving from the top of the ramp, distance sensors used for line following gave us unpredictable outputs. Reason for this was that the considerable change of height between the sensors and the white line there. So we defined a separate function for navigating robot in such scenarios.
7. Passing the Gates
We used an ultrasonic sensor for this purpose and designed an algorithm for passing both gates in a single attempt. Once the robot approaches the gate section, it stops and wait until the first gate is closed. If it is already closed, then the robot enters the algorithm. We used the state transition of the gates for navigating through them safely.
No comments:
Post a Comment