paparazzi-devel
[Top][All Lists]
Advanced

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

[Paparazzi-devel] Sonar module


From: Loic Drumettaz
Subject: [Paparazzi-devel] Sonar module
Date: Fri, 16 Mar 2012 16:29:40 +0100

Hi,

I finally managed to update altitude measurement with the sonar
module. There was several issues, found first with adc_generic module.
- ADC1 is used on LISA M to bind the spektrum receiver, so I couldn't
use it together with the receiver
- ADC2 never sent any value, maybe this is the one which is used to
measure supply voltage??
- ADC3 worked with index 3: <configure name="ADC_CHANNEL_GENERIC1" value="3"/>

With this module, I was able to see the raw value from the sonar with
the telemetry.  So, i tried to do the same with the sonar module.
I added DOWNLINK_SEND_BOOZ2_SONAR in the read function of
sonar_maxbotix.c (I used the old telemetry message BOOZ2_SONAR so it's
good to keep it for debugging ;)). It showed that the sonar module was
working fine as the value sonar_meas was updated.

So the problem was in ins.c, in the function ins_update_sonar. ins_qfe
wasn't updated (I also added ins_qfe to BOOZ2_SONAR). It turned out
that the boolean ins_update_on_agl was  FALSE. So i added:
ins_update_on_agl=TRUE in the init function of sonar_maxbotix.c

I'm also suprised by line 110:
#ifdef BOOZ2_SONAR
     ins_update_on_agl=FALSE
#endif
BOOZ2_SONAR is defined nowhere and seems to be an old flag?

I suppose a new issue can be opened on github?

Regards
Loïc



reply via email to

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