1
$\begingroup$

I am trying to build pitch, roll and yaw from sensor readings of a 9 degree of freedom sensing device. The data look like that (in a .csv file):

TIME,ACC_X,ACC_Y,ACC_Z,GYRO_X,GYRO_Y,GYRO_Z,MAG_X,MAG_Y,MAG_Z
2313992204,-1.694118,-2.053042,-8.886943,0.006272,-0.004091,0.000682,-48.200001,-68.400002,13.000000
2313992204,-1.674976,-2.029114,-8.886943,0.006545,-0.003682,0.000682,-48.500000,-67.599998,11.300000
2313992204,-1.674976,-2.033899,-8.882157,0.006136,-0.004091,0.000273,-47.799999,-67.500000,12.300000
2313992204,-1.703690,-2.033899,-8.882157,0.006818,-0.003682,0.000409,-47.700001,-68.099998,11.800000
2313992204,-1.694118,-2.053042,-8.877372,0.006409,-0.004500,0.000682,-47.900002,-67.400002,11.200000

I am not familiar with building this measures from these data and also I am not familiar with quaternions. This question is the only thing I have found to be related to mine questions (Calculating pitch, yaw, and roll from mag, acc, and gyro data), however, it is not using all the axis. Ideally, I want to build this vector and be able to visualize them in 3D (like cube animation that is made live from 9dof sensors and Arduino). Moreover, I want to be able to compute the heading from this data.

Can anyone help me, I have all my pipeline in python so it would be helpful to have advice on how to do that with python?

$\endgroup$
  • $\begingroup$ Do you have a reason to believe that all 9 inputs are required to calculate PRY? $\endgroup$ – Carl Witthoft Aug 7 '18 at 19:42
  • 1
    $\begingroup$ I know that gyroscope and accelerometer are enough, but I forgot to specify that I have multiple sensors, so the magnetometer will allow me to know also the relative position in the devices group. $\endgroup$ – Guido Muscioni Aug 8 '18 at 4:42
  • $\begingroup$ Base on your question you have sufficient information to calculate Roll, Pitch and Yaw. Also in the post you link there is a linked there is link to Arduino. If you still have question please comeback we will try to help. $\endgroup$ – Mahendra Gunawardena Aug 10 '18 at 0:30
  • $\begingroup$ Thank you Mahendra, however the code posted only use accelerometer, I want to use also gyro information. Am I missing something? $\endgroup$ – Guido Muscioni Aug 10 '18 at 6:35
  • $\begingroup$ Any reason you want to use gyro data? $\endgroup$ – Mahendra Gunawardena Aug 11 '18 at 1:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.