Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

A . TASK - 1 : Multi - robot coverage path planning Two robots are located in ROS Stage environment. The environment includes obstacles that

A. TASK-1: Multi-robot coverage path planning
Two robots are located in ROS Stage environment. The environment includes obstacles that the robots should
avoid colliding.
The starting positions and orientations of the robots are shown in Figure 1. The arrows show the directions
that the robot moves. The distance R that the robot travels in left/right directions is the same. Both robots
start moving up until they detect the wall/obstacle with their sensors; then they turn left/right, and then move
down/up until they detect the wall/obstacle again with their sensors. This motion pattern is executed until
the robot reaches the end point (see Figure 1, square icons). The robots should always face the directions
that they move. The starting positions and the orientations of the robots should appear as seen in Figure 1.
Set the value of R as 3 for robot-1 and robot-2. You can do small changes on this value.
Each robot should keep the track of the total distance that it travels.
You should create a yaml file that holds the R values for the robots. The parameters in the yaml file should be
received in the Python file using the appropriate functions.
First, robot-1 should start moving. When robot-1 finishes its motion, it should send the message that includes
string command and float distance to robot-2. The value of the command variable should be START and the
value of the distance variable should be the total distance traveled by robot-1. Robot-2 should subscribe to
the topic that this message is sent. Upon receiving this message, robot-2 should start its motion also print the
distance value that is received. Note that for this message file to be built, you need to modify your
CMakeLists.txt file in your project package accordingly and include this message as a header to your Python
file(s).
Important Notes:
You should use the robots sensor so that it does not hit the walls/obstacles. You can define a fixed
distance (R) for the robot when it is traveling in left or right direction (i.e. in the x axis). However, do
not define a fixed distance for the robot when it is traveling in up or down direction (i.e. in the y axis).
This should be controlled by the robots sensors. That is, the robot should understand when it should
turn left/right using its sensor data.
You need to change the world file to change the initial postions and orientations of the robotsEXECUTION:
The execution of each step should be demonstrated in ROS Stage and the nodes should be written in Python.
You can create a seperate Python node for each robot that executes step A. Or, you can create a single Python
node that executes step A for both robots. You need to have a separate Python nodes for steps B and C.
You can start running your nodes either using rosrun command or using roslaunch command by creating
launch files.
In your world file, change the window and floorplan functions in your world file as you see below. The image
file is in the uploaded project folder in Moodle.
window (
size [850.000850.000]
rotate 0.0000.0
scale 40.0
show_data 1
show_trailarrows 1
show_trailfootprint 1
floorplan (
name "firstmap"
bitmap "FinalProjectWorld.png"
size [19.019.00.5]
pose [0.0000.00000.000]
image text in transcribed

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Pro SQL Server Wait Statistics

Authors: Enrico Van De Laar

1st Edition

1484211391, 9781484211397

More Books

Students also viewed these Databases questions

Question

Has your organisation defined its purpose, vision and mission?

Answered: 1 week ago