ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

roll, pitch, yaw using tags

asked 2017-10-23 06:20:00 -0600

oha gravatar image

Hi all, I am trying to get an ardrone to fly by getting directions from tags. I am having problems correcting my roll, pitch and yaw, To be honest my code is based off of someone else, and I am not sure I understand it properly, but basically when I detect a tag (using ar_track_alvar) I then run the command:

 roll, pitch, yaw = euler_from_quaternion([data.pose.orientation.x, data.pose.orientation.y,    data.pose.orientation.z, data.pose.orientation.w])

I was hoping this would give me the roll, pitch and yaw with respect to the tag but the results I am getting don't make any sense. My roll and yaw are always either ~3.14 or ~-3,14 (roll and yaw aren't identical, one might be positive and the other negative, but they both get those values) My pitch is mostly between 0.2 and -0.2.

I could not figure out any correlation between my drones orientation and the roll, pitch and yaw I am getting, so I am assuming I am doing something completely wrong, but if Im somehow making sense then any help as to how to correct myself would be greatly appreciated.

If there is a better way to go about it I am open to suggestions.

Thanks for any help available!

edit retag flag offensive close merge delete

Comments

my guess is that you're not getting the transform between the ardrone and the tag but the transform between the tag and some other coordinate system. I assume you've checked output_frame and tf tree for problems?

mcevoyandy gravatar image mcevoyandy  ( 2017-10-23 23:53:20 -0600 )edit

I just realized I forgot to mention what worked for me. I actually don't know what happened, but I left the project for 2 months and coming back the coordinate systems just made sense.. One thing I did notice is that the ardrone takes care of roll and yaw by itself, and I only needed to change pitch

oha gravatar image oha  ( 2018-03-13 01:52:36 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2018-03-25 07:55:31 -0600

oha gravatar image

I just realized I forgot to mention what worked for me. I actually don't know what happened, but I left the project for 2 months and coming back the coordinate systems just made sense.. One thing I did notice is that the ardrone takes care of roll and yaw by itself, and I only needed to change pitch

edit flag offensive delete link more

Question Tools

2 followers

Stats

Asked: 2017-10-23 06:20:00 -0600

Seen: 495 times

Last updated: Mar 25 '18