paparazzi-devel
[Top][All Lists]
Advanced

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

Re: [Paparazzi-devel] Lisa debugging


From: antoine drouin
Subject: Re: [Paparazzi-devel] Lisa debugging
Date: Wed, 1 Sep 2010 22:15:05 +0200

Hi Marko

vbat is on top of my todo list

On Wed, Sep 1, 2010 at 9:02 PM, Marko Thaler <address@hidden> wrote:
> Hi Poine,
>
> Thanks, I'll have a look at the libstm32. Since I am totally new to hardware
> driver development, I do not think I can be of any help for the I2C code,
> but I will have a look and learn a lot ;-).
>
> Oh, one more thing. I have noticed the vsupply battery voltage in the Lisa
> telemetry is constantly 0 dV. Is there a specific flag that must be set for
> this to work or is this going to be implemented in the future?
>
> Thank you and talk to you soon,
>
> Marko
>
>
> On Wed, Sep 1, 2010 at 8:01 PM, antoine drouin <address@hidden> wrote:
>>
>> Hi Marko
>>
>> I know the I2C code needs quite a bit of rework. I2C1 is something
>> close from the libstm32 example - I2C2 uses different code. When I2C2
>> is stable I'll make I2C1 use the same code. About the missing files,
>> they are from libstm32, which is distributed with the paparazzi-stm32
>> package. You can look at the script used to build the package in the
>> toolchain directory on svn. What I find strange is that I don't get
>> the crashes you have here, but I'm using a slightly different setup
>> with asctec esc. Another difference is that I'm using a different
>> version of libstm32 where I've turned off the assert_param. In the
>> version of the package they are function call to an empty function (
>> in  sw/airborne/stm32/stm32_vector_table.c ). libstm32 make a generous
>> use of it, slowing down every interrupt handler by about a factor of
>> two.
>> I'll release a new version of the toolchain with the assert_param disabled
>> asap.
>>
>> Poine
>>
>>
>>
>> On Wed, Sep 1, 2010 at 7:38 PM, Marko Thaler <address@hidden>
>> wrote:
>> > Hello,
>> >
>> > Eric and Poine, thank you for your suggestions and help.
>> >
>> > I have set up the debug environment in Eclipse which seems to work fine.
>> >
>> > The only problem now is that if I randomly suspend (halt) the code
>> > execution, I sometimes get an error:
>> >
>> > Can't find a source file at "some_file.c"
>> >
>> > Until now some_file.c were:
>> > - stm32_usart.c
>> > - stm32_i2c.c
>> >
>> > I can not find this files anywhere in the paparazzi3 repository. The
>> > interesting part is that during compilation there are no errors and
>> > those
>> > files are not needed!?
>> >
>> > I have not managed to make a proper debug session with regards to
>> > Lisa/MKK
>> > ESCs freeze. However, in a quick test debug I have observed two
>> > different
>> > error behaviours:
>> >
>> > a) MKK ESCs block the motors (red ESC LED goes on) while Lisa is running
>> > normally (I am testing motors without props). To regain a normal motor
>> > operation I only have to power down and power up the Lisa. During this
>> > period ESCs have an uninterrupted power supply and the red ESC LEDs turn
>> > off
>> > as soon as the Lisa is reset (powered back up).
>> >
>> > b) Lisa can freeze in flight (Lisa's LEDs stop blinking and stay in
>> > their
>> > last state) and ESCs turn the motors off (red ESC LEDs go on). In this
>> > case
>> > I can regain normal operation by suspending (halting) Lisa in the debug
>> > session and resuming the session. As soon as I hit the resume button in
>> > Eclipse motors and Lisa start to operate normally.
>> >
>> > For the b) example I could not take a look at where in the program the
>> > error
>> > occurred since I got "Can't find a source file" message from above and
>> > <symbol is not available> error in the debug window.
>> >
>> > I'll have a go at a proper debug tomorrow morning.
>> >
>> > Regards,
>> >
>> > Marko
>> >
>> >
>> > On Tue, Aug 31, 2010 at 8:19 PM, antoine drouin <address@hidden>
>> > wrote:
>> >>
>> >> looking at the I2C issue
>> >>
>> >> for JTAG:
>> >> xterm -e "/opt/paparazzi/stm32/bin/openocd -f interface/lisa-l.cfg -f
>> >> board/lisa-l.cfg"&
>> >> xterm -e "telnet localhost 4444" &
>> >>
>> >> in that window : halt
>> >>
>> >> /opt/paparazzi/stm32/bin/arm-none-eabi-gdbtui --eval-command="target
>> >> remote localhost:3333" var/BOOZ2_A7/ap/ap.elf
>> >>
>> >> Regards
>> >>
>> >> Poine
>> >>
>> >>
>> >> On Tue, Aug 31, 2010 at 6:40 PM, Marko Thaler <address@hidden>
>> >> wrote:
>> >> > Hello everybody,
>> >> >
>> >> > I am testing the new Lisa on a quadrotor and have a few questions:
>> >> > - I use Lisa with MKK ESCs. Has anybody encountered a freeze of ESCs
>> >> > while
>> >> > in flight? The red LEDs on all the MKK ESCs turn on and all the
>> >> > motors
>> >> > shut
>> >> > down. This happens while Lisa is running normally. I have tested all
>> >> > the
>> >> > I2C
>> >> > cabling but haven't observed anything unusual. Sometimes red LEDs
>> >> > turn
>> >> > on at
>> >> > power up, but after a reset everything is normal and functioning
>> >> > properly.
>> >> > - I am new to gdb (been previously using CrossWorks from Rowley). Is
>> >> > there a
>> >> > quick and dirty procedure write up on how to connect to Lisa? I had a
>> >> > couple
>> >> > of tries to attach gdb (gdbserver) to a running Lisa but with no
>> >> > luck.
>> >> > - When I do not have the MKK ESCs connected to the I2C port and the
>> >> > autopilot code is running, I can freeze the code with holding the
>> >> > throttle
>> >> > stick in the motor on/off position (down and right) for a couple of
>> >> > seconds
>> >> > (anything from 3 to 20 seconds). This condition is not always
>> >> > reproducible
>> >> > so sometimes it needs a couple of retries (go to center position and
>> >> > than
>> >> > back to down and right). I could practically always reproduce the
>> >> > freeze
>> >> > in
>> >> > the first three tries when ap_mode is in ATTITUDE_Z_HOLD. When in
>> >> > ATTITUDE_RC_CLIMB and ATTITUDE_DIRECT the freeze is rarely
>> >> > reproducible.
>> >> > The
>> >> > freeze never happened when ESCs were connected to Lisa.
>> >> >
>> >> > I know you should not abuse Lisa in this way, I am just writing up my
>> >> > observations if anybody encounters something similar.
>> >> >
>> >> > I will examine all the unusual behaviour in the code myself as soon
>> >> > as I
>> >> > get
>> >> > more comfortable with gdb (any help is deeply appreciated :).
>> >> >
>> >> > Thanks for your input and kind regards,
>> >> >
>> >> > Marko
>> >> >
>> >> >
>> >> > _______________________________________________
>> >> > Paparazzi-devel mailing list
>> >> > address@hidden
>> >> > http://lists.nongnu.org/mailman/listinfo/paparazzi-devel
>> >> >
>> >> >
>> >>
>> >> _______________________________________________
>> >> Paparazzi-devel mailing list
>> >> address@hidden
>> >> http://lists.nongnu.org/mailman/listinfo/paparazzi-devel
>> >
>> >
>> > _______________________________________________
>> > Paparazzi-devel mailing list
>> > address@hidden
>> > http://lists.nongnu.org/mailman/listinfo/paparazzi-devel
>> >
>> >
>>
>> _______________________________________________
>> Paparazzi-devel mailing list
>> address@hidden
>> http://lists.nongnu.org/mailman/listinfo/paparazzi-devel
>
>
> _______________________________________________
> Paparazzi-devel mailing list
> address@hidden
> http://lists.nongnu.org/mailman/listinfo/paparazzi-devel
>
>



reply via email to

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