paparazzi-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Paparazzi-devel] Aspirin IMU 1.5 x,y swap


From: Bruzzlee
Subject: [Paparazzi-devel] Aspirin IMU 1.5 x,y swap
Date: Thu, 17 Apr 2014 21:47:35 +0200
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:24.0) Gecko/20100101 Thunderbird/24.4.0

Hi all

I have an Aspirin v1.5 mounted on the LisaM 1.0

If I define
        <subsystem name="imu"           type="aspirin_v1.0"/>
The directions seem to be correct

But if I define
        <subsystem name="imu"           type="aspirin_v1.5"/>

The front of the LisaM points to the right.
With front I define the PFD behaviour.

The Wiki "says": The front of IMU is marked as X axis. Warning! Aspirin 1.5 has x and y silkscreen swapped.
But this seems to wrong for my Aspirin 1.5

What could be the reason?

( BODY_TO_IMU are all set to 0)


I've found those code snippets which affects:

----------- imu_aspirin.c-------
#ifdef IMU_ASPIRIN_VERSION_1_0
    VECT3_COPY(imu.mag_unscaled, imu_aspirin.mag_hmc.data.vect);
#else // aspirin 1.5 with hmc5883
    imu.mag_unscaled.x = imu_aspirin.mag_hmc.dat a.vect.y;
    imu.mag_unscaled.y = -imu_aspirin.mag_hmc.data.vect.x;
    imu.mag_unscaled.z = imu_aspirin.mag_hmc.data.vect.z;
----------- hmc58xx.c---------
      if (hmc->type == HMC_TYPE_5843) {
        hmc->data.vect.x = Int16FromBuf(hmc->i2c_trans.buf,0);
        hmc->data.vect.y = Int16FromBuf(hmc->i2c_trans.buf,2);
        hmc->data.vect.z = Int16FromBuf(hmc->i2c_trans.buf,4);
< div class="line" id="LC147">      }
      /* HMC5883 has xzy order of axes in returned data */
      else {
        hmc->data.vect.x = Int16FromBuf(hmc->i2c_trans.buf,0);
         hmc->data.vect.y = Int16FromBuf(hmc->i2c_trans.buf,4);
        hmc->data.vect.z = Int16FromBuf(hmc->i2c_trans.buf,2);
      }

Thank you Bruzzlee

Attachment: LisaM.jpg
Description: JPEG image


reply via email to

[Prev in Thread] Current Thread [Next in Thread]