paparazzi-devel
[Top][All Lists]
Advanced

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

Re: [Paparazzi-devel] How to BIND EXT MAG Messages to AHRS


From: Rijesh Augustine
Subject: Re: [Paparazzi-devel] How to BIND EXT MAG Messages to AHRS
Date: Wed, 16 Sep 2015 09:44:21 -0600

Thanks Felix, That explained so much.

I used AHRS_MAG_OMEGA variable and can actively see the ext. Mag in action.

Regards
Rijesh

On Tue, Sep 15, 2015 at 5:31 PM, Felix Ruess <address@hidden> wrote:
Even without a mag, the AHRS will estimate psi changes by integrating the gyro measurements from the initial heading...
So that psi changes when rotating the aircraft is expected even when you don't have a mag (although it will drift over time and not be correct wrt north).

If you unplug the mag, you should not see any new/changing mag measurements in the IMU_MAG message.
Also if you rotate the mag but not the aircraft, the AHRS should slowly "correct" the psi angle to the direction the mag is pointing at...

On Wed, Sep 16, 2015 at 1:17 AM, Rijesh Augustine <address@hidden> wrote:
Looking at Messages -> Attitude -> psi:

I move the external mag, the value doesn't change.
I move the Lisa and the value changes.
I unplug the external mag, and move the board and the value changes.
I restart the Lisa without the external mag and move the Lisa and the value changes.

Thanks
Rijesh



On Tue, Sep 15, 2015 at 4:59 PM, Felix Ruess <address@hidden> wrote:
Hi,

that looks correct to me...

> The psi message is still being updated by the Aspirin Mag.

Are you sure, how do you conclude that?
If you unplug the hmc, you should not get any new mag measurements anymore at all...

Cheers, Felix

On Wed, Sep 16, 2015 at 12:13 AM, rijesh <address@hidden> wrote:
Hi all,

I am having issues with this bit of code again. It was working fine in July
but now it doesn't seem to be working.

I decided to pull to the latest code and try to sort it out from there. I am
on v5.7_devel-236-g426d50c.

I have an external HMC5883 plugged into my i2c2 line on my Lisa MX.
The IMU MAG message in the Messages window changes with the orientation of
the external HMC5883.
The psi message is still being updated by the Aspirin Mag.

My config at build time seems to have the correct config:
subsystems/ahrs/ahrs_float_cmpl_wrapper.c:94:1: note: #pragma message:
Config: AHRS_FC_IMU_ID = 255
 PRINT_CONFIG_VAR(AHRS_FC_IMU_ID)
 ^
subsystems/ahrs/ahrs_float_cmpl_wrapper.c:101:1: note: #pragma message:
Config: AHRS_FC_MAG_ID = 2
 PRINT_CONFIG_VAR(AHRS_FC_MAG_ID)

I have this defined for my ahrs:
    <subsystem name="ahrs" type="float_cmpl_quat">
      <define name="ASPIRIN_2_DISABLE_MAG" value="TRUE" />
      <define name="USE_MAGNETOMETER" value="TRUE"/>
      <define name="AHRS_FC_MAG_ID" value="MAG_HMC58XX_SENDER_ID"/>
    </subsystem>

and I have this defined in my module section:

    <load name="mag_hmc58xx.xml">
      <define name="MODULE_HMC58XX_UPDATE_AHRS" value="TRUE" />
      <configure name="MAG_HMC58XX_I2C_DEV" value="i2c2"/>
    </load>

Here is my full airframe file:
http://pastebin.com/Sh3mi4WN



--
View this message in context: http://lists.paparazziuav.org/How-to-BIND-EXT-MAG-Messages-to-AHRS-tp17253p17362.html
Sent from the paparazzi-devel mailing list archive at Nabble.com.

_______________________________________________
Paparazzi-devel mailing list
address@hidden
https://lists.nongnu.org/mailman/listinfo/paparazzi-devel


_______________________________________________
Paparazzi-devel mailing list
address@hidden
https://lists.nongnu.org/mailman/listinfo/paparazzi-devel



_______________________________________________
Paparazzi-devel mailing list
address@hidden
https://lists.nongnu.org/mailman/listinfo/paparazzi-devel



_______________________________________________
Paparazzi-devel mailing list
address@hidden
https://lists.nongnu.org/mailman/listinfo/paparazzi-devel



reply via email to

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