wilselby / ROS_quadrotor_simulator

Quadrotor simulator using ROS, Gazebo, and RVIZ
270 stars 125 forks source link

Problem about yaw value of the planned path #31

Open kaganozgun opened 6 years ago

kaganozgun commented 6 years ago

Hello, I am working on project similar to your project. I have problem about yaw degree of the drone. If the target position yaw is smaller than 90 degree planned path is not work correctly. Drone rotate multiple times on any of the direction and goes to target point. I want to create planned path only changing drone position and yaw value. Is there any way to limit the planning algorithm like only rotate the yaw and don't change the pitch value ? Additionally there is a yaw value difference between planned path and drone yaw value on rviz. Differences is exactly -90 degree. I try to decrease the target yaw value 90 degree but if the target yaw value is smaller than -90 planned path is changing and drone spin on x axis or y axis while planning the path.

wilselby commented 6 years ago

Hello!

Are you using the packages I provided or is this your own custom project?

What type of algorithm are you using to control the yaw of the drone? I would recommend starting with a PID controller. You can even start just with a P controller and then add D, then I if you need it. You should be able to get the quadrotor into a hover state to simplify the testing process. Then change the yaw and see how the quadrotor reacts.

Yaw is controlled by changing the motor speed of the pairs of motors so you can look at the motor speeds to see if you are getting the expected result. You shouldn't need to change pitch to change yaw.

When looking at rviz, you may have to check the reference frame if you aren't seeing the expected yaw angle.

Hope that helps, and good luck!

Wil Selby www.wilselby.com http://wilselby.com LinkedIn https://www.linkedin.com/in/wilselby/ | YouTube https://www.youtube.com/user/wilSelby

On Thu, Apr 19, 2018 at 7:40 AM, Kağan Özgün notifications@github.com wrote:

Hello, I am working on project similar to your project. I have problem about yaw degree of the drone. If the target position yaw is smaller than 90 degree planned path is not work correctly. Drone rotate multiple times on any of the direction and goes to target point. I want to create planned path only changing drone position and yaw value. Is there any way to limit the planning algorithm like only rotate the yaw and don't change the pitch value ? Additionally there is a yaw value difference between planned path and drone yaw value on rviz. Differences is exactly -90 degree. I try to decrease the target yaw value 90 degree but if the target yaw value is smaller than -90 planned path is changing and drone spin on x axis or y axis while planning the path.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/wilselby/ROS_quadrotor_simulator/issues/31, or mute the thread https://github.com/notifications/unsubscribe-auth/AIWi7HtDnrrg3m77M8T0mnRJ3A7eAUmBks5tqKHzgaJpZM4Tb7IA .