Suddenly unable to load to flash of Lisa/MX with Black Magic Probe

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Suddenly unable to load to flash of Lisa/MX with Black Magic Probe

cxiao
Hello,

We have been successfully using the Lisa/MX and Black Magic Probe from 1BitSquared for several years, but yesterday, we ran into an issue where we were not able to program the Lisa/MX.

The error message is as follows:

```
Black Magic Probe (Firmware v1.6.1-27-ga4bb2c6) (Hardware Version 1)
Copyright (C) 2015  Black Sphere Technologies Ltd.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>

Target voltage: 3.3V
Available Targets:
No. Att Driver
 1      STM32F4xx
A program is being debugged already.  Kill it? (y or n) [answered Y; input not from terminal]
reset_handler () at ../../cm3/vector.c:64
64 {
Ignoring packet error, continuing...
Loading section .text, size 0x24ac8 lma 0x8000000
/home/cindy/paparazzi/sw/tools/flash_scripts/bmp_jtag_flash.scr:11: Error in sourced command file:
Error writing data to flash
```

The error occurs when trying to load the binary. I have tried using GDB with the same commands that are present in bmp_jtag_flash.scr, and I always get the same message and failure at the same place (when trying to load the .text section).

This error occurs:
* Using 2 different Black Magic Probes
* Using 4 different Lisa/MX boards, including one that was newly opened
* When building using the Quad_LisaMX aircraft configuration. We have also tried with our own aircraft configuration (the "Jownsey" aircraft in our conf file, here).
* We are using our own fork of paparazzi at https://github.com/uaarg/paparazzi, but this error occurs even when using the v5.10_stable release from the main repository.

I've also looked at the option bytes on the STM32F4 to see if there's any write protection active - there doesn't seem to be any.

We'd appreciate any pointers on where the error could be coming from, as we've tried different hardware and software to no avail. If anyone could help me figure out how to get a more verbose error message from GDB (I don't think the "Error writing data to flash" message is from the BMP, although I could be wrong), that would be great as well. Any help is appreciated as we're a student team going to competition very soon :p

Our next step is to try using an ST-LINK rather than a BMP.

Best,
Cindy
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Suddenly unable to load to flash of Lisa/MX with Black Magic Probe

cxiao
Update: We just tried flashing with an ST-LINK and that worked.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Suddenly unable to load to flash of Lisa/MX with Black Magic Probe

Alexandre Bustico
In reply to this post by cxiao
Le 11/06/2017 à 21:26, cxiao a écrit :
> Hello,
>
> We have been successfully using the Lisa/MX and Black Magic Probe from
> 1BitSquared for several years, but yesterday, we ran into an issue where we
> were not able to program the Lisa/MX.
>
> The error message is as follows:
>
> ```


Hello, there is a known bug in gdb version 7.12 :
https://github.com/blacksphere/blackmagic/issues/181


To get around that bug you can :

° use a previous gdb version (7.10 works)
° use the lastest gdb version (8.0 works too)
° apply a patch to the gdb 7.12 :
https://sourceware.org/bugzilla/show_bug.cgi?id=21188


Alexandre



_______________________________________________
Paparazzi-devel mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/paparazzi-devel
Loading...