Question: Task to accomplish Create a Python program that, using ALL the methods from the robot _ control _ class.py Python script, helps the Turtlebot robot

Task to accomplish
Create a Python program that, using ALL the methods from the robot_control_class.py Python script, helps the Turtlebot robot to get out of the maze.
Just to help you out, let's make a summary of all the methods you've been using throughout the course:
get_laser (direction): As the name itself says, this method will allow you to get data from the laser of the robot. You will need to pass one parameter to this method:
direction: Here you will specify a number between 0 and 719, which will indicate the direction of the laser reading.
get_laser_full(): As the name itself says, this method will allow you to get all the data from ALL the laser beams of the robot. As I've said before, this is a total of 719 different readings. So, when called, this method will return a LIST containing all the 719 different readings from the laser beams.
move_straight(): As the name says, this method will allow you to start moving the robot in a straight line.
stop_robot(): As the name says, this method will allow you to stop the robot from moving.
move_straight_time(motion, speed, time): As the name itself says, this method will allow you to move the robot in a straight line. You will need to pass three parameters to it.
motion: Specify here if you want your robot to move forward ("forward") or backward ("backward").
speed: Specify here the speed at which you want your robot to move (in m/s).
time: Specify here how long you want your robot to keep moving (in seconds).
turn (clockwise, speed, time): As the name itself says, this method will allow you to turn the robot. You will need to pass three parameters to it.
clockwise: Specify here whether you want your robot to turn clockwise ("clockwise") or counter-clockwise ("counter-clockwise").
speed: Specify here the speed at which you want your robot to turn (in rad/s).
time: Specify here how long you want your robot to keep turning (in seconds).
Finally, and for this project, you are going to be able to use a new method.
rotate (degrees): This method will allow your robot to rotate for the specified number of degrees.
degrees: The number of degrees you want your robot to rotate.
**NOTE**: In theory, you can also make the robot rotate a certain number of degrees by using the **
t
u
r
n
(
)
** method and playing with the *
s
p
e
e
d
* and *
t
i
m
e
* values. However, this method will be less precise than the **
r
o
t
a
t
e
(
)
** method, because it's not taking into account external sources like the odometry of the robot (which the **
r
o
t
a
t
e
(
)
** method does).
- robot_control_class.py -
Below you can find the updated code for the robot_control_class.py class, which contains the new rotate() method.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Finance Questions!