Tim-HW / ROS2-Path-Planning-Turtlebot3-Potential-Field

ROS2 Package for turtlebot3 to execute local path planning using the potential field methods. This package is an excuse to learn C++ and ROS2. Feel free to use it as you wish :D
MIT License
14 stars 0 forks source link

running result #1

Open yjydiancom opened 10 months ago

yjydiancom commented 10 months ago

I followed your instructions and ran your code, but the only thing that came out of the run was what is shown in this image below 2023-10-18 10-02-37 的屏幕截图

Tim-HW commented 10 months ago

Hello ! That normal ! if you look at gazebo you're robot is supposed to move at the position (x=3,y=5) Cheers

yjydiancom commented 10 months ago

May I ask what command should be executed subsequently?

yjydiancom commented 10 months ago

Is this one not visualized in code?

Tim-HW commented 10 months ago

You will first need to launch a gazebo world with turtlebot3.

$ export TURTLEBOT3_MODEL=burger $ ros2 launch turtlebot3_gazebo turtlebot3_world.launch

Then you can rosrun the package for potential field.

yjydiancom commented 10 months ago

Could you tell me how to define the end point and how to start the algorithm to plan the path? Sorry to bother you all the time

yjydiancom commented 10 months ago

Sorry, I meant to ask how to define the starting point, when I run it, no matter how I define the end point, the cart keeps rotating in the position in the picture below and does not change. 2023-10-18 22-49-42 的屏幕截图 After running what you said "$ export TURTLEBOT3_MODEL=burger $ roslaunch turtlebot3_gazebo turtlebot3_world.launch" I also ran "ros2 launch potential_field potential_field.launch. potential_field.launch. ", but the turtlebot keeps going haywire

Tim-HW commented 10 months ago

You can check on Rviz the direction of the force applied (Repulsive and Attractive). Might be useful :D

yjydiancom commented 10 months ago

I tried to do it yesterday, but I still don't understand how to view the direction of the force applied (Repulsive and Attractive) in Rviz.