ROS Answers: Open Source Q&A Forum - RSS feedhttps://answers.ros.org/questions/Open source question and answer forum written in Python and DjangoenROS Answers is licensed under Creative Commons Attribution 3.0Tue, 03 Nov 2015 17:44:11 -0600What do x, y, and z denote in mavros topic /mavros/imu/data_rawhttps://answers.ros.org/question/220333/what-do-x-y-and-z-denote-in-mavros-topic-mavrosimudata_raw/hi, I am using mavros to read the signals from the APM2.5. However I am not sure what x, y, z denote.
For example, in angular_velocity, I think the signals should be pitch, roll, and yaw in rad. How do x, y, and z correspond to them. Also, in linear_acceleration, what is the coordinates for x, y, and z, and are they in meter? Many thanks.
$ rostopic type /mavros/imu/data_raw
sensor_msgs/Imu
$ rosmsg show sensor_msgs/Imu
std_msgs/Header header
uint32 seq
time stamp
string frame_id
geometry_msgs/Quaternion orientation
float64 x
float64 y
float64 z
float64 w
float64[9] orientation_covariance
geometry_msgs/Vector3 angular_velocity
float64 x
float64 y
float64 z
float64[9] angular_velocity_covariance
geometry_msgs/Vector3 linear_acceleration
float64 x
float64 y
float64 z
float64[9] linear_acceleration_covariance
Mon, 02 Nov 2015 23:57:27 -0600https://answers.ros.org/question/220333/what-do-x-y-and-z-denote-in-mavros-topic-mavrosimudata_raw/Comment by pinocchio for <p>hi, I am using mavros to read the signals from the APM2.5. However I am not sure what x, y, z denote.</p>
<p>For example, in angular_velocity, I think the signals should be pitch, roll, and yaw in rad. How do x, y, and z correspond to them. Also, in linear_acceleration, what is the coordinates for x, y, and z, and are they in meter? Many thanks.</p>
<pre><code>$ rostopic type /mavros/imu/data_raw
sensor_msgs/Imu
$ rosmsg show sensor_msgs/Imu
std_msgs/Header header
uint32 seq
time stamp
string frame_id
geometry_msgs/Quaternion orientation
float64 x
float64 y
float64 z
float64 w
float64[9] orientation_covariance
geometry_msgs/Vector3 angular_velocity
float64 x
float64 y
float64 z
float64[9] angular_velocity_covariance
geometry_msgs/Vector3 linear_acceleration
float64 x
float64 y
float64 z
float64[9] linear_acceleration_covariance
</code></pre>
https://answers.ros.org/question/220333/what-do-x-y-and-z-denote-in-mavros-topic-mavrosimudata_raw/?comment=220338#post-id-220338Also, how can I know the frequency of the signals. Many thanks.Tue, 03 Nov 2015 00:36:47 -0600https://answers.ros.org/question/220333/what-do-x-y-and-z-denote-in-mavros-topic-mavrosimudata_raw/?comment=220338#post-id-220338Answer by Akif for <p>hi, I am using mavros to read the signals from the APM2.5. However I am not sure what x, y, z denote.</p>
<p>For example, in angular_velocity, I think the signals should be pitch, roll, and yaw in rad. How do x, y, and z correspond to them. Also, in linear_acceleration, what is the coordinates for x, y, and z, and are they in meter? Many thanks.</p>
<pre><code>$ rostopic type /mavros/imu/data_raw
sensor_msgs/Imu
$ rosmsg show sensor_msgs/Imu
std_msgs/Header header
uint32 seq
time stamp
string frame_id
geometry_msgs/Quaternion orientation
float64 x
float64 y
float64 z
float64 w
float64[9] orientation_covariance
geometry_msgs/Vector3 angular_velocity
float64 x
float64 y
float64 z
float64[9] angular_velocity_covariance
geometry_msgs/Vector3 linear_acceleration
float64 x
float64 y
float64 z
float64[9] linear_acceleration_covariance
</code></pre>
https://answers.ros.org/question/220333/what-do-x-y-and-z-denote-in-mavros-topic-mavrosimudata_raw/?answer=220356#post-id-220356 In IMU message, x,y and z values under `angular_velocity` correspond to roll rate, pitch rate and yaw rate respectively. Because, roll is rotation around x axis, pitch is around y and yaw is around z. Angles are represented as quaternion under `orientation`. They are not Euler angles directly. You should convert them from Quaternion to Euler angles. Check Wikipedia for description about Quaternions: https://en.wikipedia.org/wiki/Quaternions_and_spatial_rotation.
`linear_acceleration` values should be represented as m/s^2 unless otherwise stated. You should check **REP-103** (http://www.ros.org/reps/rep-0103.html) for dimension and coordinate standards in ROS.
For publish frequency of a topic you can use, `rostopic hz /mavros/imu/data_raw`Tue, 03 Nov 2015 06:21:34 -0600https://answers.ros.org/question/220333/what-do-x-y-and-z-denote-in-mavros-topic-mavrosimudata_raw/?answer=220356#post-id-220356Comment by pinocchio for <p>In IMU message, x,y and z values under <code>angular_velocity</code> correspond to roll rate, pitch rate and yaw rate respectively. Because, roll is rotation around x axis, pitch is around y and yaw is around z. Angles are represented as quaternion under <code>orientation</code> . They are not Euler angles directly. You should convert them from Quaternion to Euler angles. Check Wikipedia for description about Quaternions: <a href="https://en.wikipedia.org/wiki/Quaternions_and_spatial_rotation">https://en.wikipedia.org/wiki/Quatern...</a> . </p>
<p><code>linear_acceleration</code> values should be represented as m/s^2 unless otherwise stated. You should check <strong>REP-103</strong> ( <a href="http://www.ros.org/reps/rep-0103.html">http://www.ros.org/reps/rep-0103.html</a> ) for dimension and coordinate standards in ROS. </p>
<p>For publish frequency of a topic you can use, <code>rostopic hz /mavros/imu/data_raw</code></p>
https://answers.ros.org/question/220333/what-do-x-y-and-z-denote-in-mavros-topic-mavrosimudata_raw/?comment=220400#post-id-220400@Akif, BTW, what is the output of a APM2.5 connected GPS. Is it a global NED position or a local position? Many thanks.Tue, 03 Nov 2015 17:44:11 -0600https://answers.ros.org/question/220333/what-do-x-y-and-z-denote-in-mavros-topic-mavrosimudata_raw/?comment=220400#post-id-220400Comment by pinocchio for <p>In IMU message, x,y and z values under <code>angular_velocity</code> correspond to roll rate, pitch rate and yaw rate respectively. Because, roll is rotation around x axis, pitch is around y and yaw is around z. Angles are represented as quaternion under <code>orientation</code> . They are not Euler angles directly. You should convert them from Quaternion to Euler angles. Check Wikipedia for description about Quaternions: <a href="https://en.wikipedia.org/wiki/Quaternions_and_spatial_rotation">https://en.wikipedia.org/wiki/Quatern...</a> . </p>
<p><code>linear_acceleration</code> values should be represented as m/s^2 unless otherwise stated. You should check <strong>REP-103</strong> ( <a href="http://www.ros.org/reps/rep-0103.html">http://www.ros.org/reps/rep-0103.html</a> ) for dimension and coordinate standards in ROS. </p>
<p>For publish frequency of a topic you can use, <code>rostopic hz /mavros/imu/data_raw</code></p>
https://answers.ros.org/question/220333/what-do-x-y-and-z-denote-in-mavros-topic-mavrosimudata_raw/?comment=220397#post-id-220397Thx @Akif. That helps a lot.Tue, 03 Nov 2015 16:12:10 -0600https://answers.ros.org/question/220333/what-do-x-y-and-z-denote-in-mavros-topic-mavrosimudata_raw/?comment=220397#post-id-220397Comment by pinocchio for <p>In IMU message, x,y and z values under <code>angular_velocity</code> correspond to roll rate, pitch rate and yaw rate respectively. Because, roll is rotation around x axis, pitch is around y and yaw is around z. Angles are represented as quaternion under <code>orientation</code> . They are not Euler angles directly. You should convert them from Quaternion to Euler angles. Check Wikipedia for description about Quaternions: <a href="https://en.wikipedia.org/wiki/Quaternions_and_spatial_rotation">https://en.wikipedia.org/wiki/Quatern...</a> . </p>
<p><code>linear_acceleration</code> values should be represented as m/s^2 unless otherwise stated. You should check <strong>REP-103</strong> ( <a href="http://www.ros.org/reps/rep-0103.html">http://www.ros.org/reps/rep-0103.html</a> ) for dimension and coordinate standards in ROS. </p>
<p>For publish frequency of a topic you can use, <code>rostopic hz /mavros/imu/data_raw</code></p>
https://answers.ros.org/question/220333/what-do-x-y-and-z-denote-in-mavros-topic-mavrosimudata_raw/?comment=220366#post-id-220366Hi @Akif, thanks for your answer. I am confused about the quaternion representation for angular_velocity. I mean if the angular_velocity are under quaternion, there should be four values, namely x, y, z, and w, similar to the representation of orientation. Any hints on it?Tue, 03 Nov 2015 10:02:39 -0600https://answers.ros.org/question/220333/what-do-x-y-and-z-denote-in-mavros-topic-mavrosimudata_raw/?comment=220366#post-id-220366Comment by Akif for <p>In IMU message, x,y and z values under <code>angular_velocity</code> correspond to roll rate, pitch rate and yaw rate respectively. Because, roll is rotation around x axis, pitch is around y and yaw is around z. Angles are represented as quaternion under <code>orientation</code> . They are not Euler angles directly. You should convert them from Quaternion to Euler angles. Check Wikipedia for description about Quaternions: <a href="https://en.wikipedia.org/wiki/Quaternions_and_spatial_rotation">https://en.wikipedia.org/wiki/Quatern...</a> . </p>
<p><code>linear_acceleration</code> values should be represented as m/s^2 unless otherwise stated. You should check <strong>REP-103</strong> ( <a href="http://www.ros.org/reps/rep-0103.html">http://www.ros.org/reps/rep-0103.html</a> ) for dimension and coordinate standards in ROS. </p>
<p>For publish frequency of a topic you can use, <code>rostopic hz /mavros/imu/data_raw</code></p>
https://answers.ros.org/question/220333/what-do-x-y-and-z-denote-in-mavros-topic-mavrosimudata_raw/?comment=220370#post-id-220370Only `orientation` is represented as quaternion, angular velocity is not. Its message type is `geometry_msgs/Vector3` and consists of x, y and z only.Tue, 03 Nov 2015 10:32:37 -0600https://answers.ros.org/question/220333/what-do-x-y-and-z-denote-in-mavros-topic-mavrosimudata_raw/?comment=220370#post-id-220370