-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Closed
Labels
Milestone
Description
There is rare case that st-util can't flash firmware onto NUCLEO-F091RC.
- Programmer/board type: Stlink/v2-1-onboard
- Programmer firmware version: v1.3.1-19-g55c0572
- Operating system: Debian GNU/Linux sid
- Stlink tools version and/or git commit hash: 55c0572
- Stlink commandline tool name:
st-util - Target chip (and optional board): STM32F091RCT6 on NUCLEO-F091RC
st-util output:
$ sudo st-util
--snip--
2017-05-20T17:04:06 ERROR src/gdbserver/gdb-server.c: cannot recv: -2
2017-05-20T17:04:07 INFO src/gdbserver/gdb-server.c: Listening at *:4242...
2017-05-20T17:04:07 INFO src/gdbserver/gdb-server.c: Found 4 hw breakpoint registers
2017-05-20T17:04:07 INFO src/gdbserver/gdb-server.c: GDB connected.
2017-05-20T17:04:08 INFO src/gdbserver/gdb-server.c: Found 4 hw breakpoint registers
2017-05-20T17:04:09 INFO src/common.c: Attempting to write 2048 (0x800) bytes to stm32 address: 134217728 (0x8000000)
Flash page at addr: 0x08000000 erased
2017-05-20T17:04:09 INFO src/common.c: Finished erasing 1 pages of 2048 (0x800) bytes
2017-05-20T17:04:09 INFO src/common.c: Starting Flash write for VL/F0/F3/F1_XL core id
2017-05-20T17:04:09 INFO src/flash_loader.c: Successfully loaded flash loader in sram
2017-05-20T17:04:13 ERROR src/flash_loader.c: flash loader run error
2017-05-20T17:04:13 ERROR src/common.c: stlink_flash_loader_run(0x8000000) failed! == -1
gdb output:
$ cat ../gdbwrite.boot
tar ext localhost:4242
monitor reset halt
load
monitor reset halt
$ arm-none-eabi-gdb -x ../gdbwrite.boot build/ch.elf
GNU gdb (7.12-6+9+b2) 7.12.0.20161007-git
Copyright (C) 2016 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "--host=x86_64-linux-gnu --target=arm-none-eabi".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from build/ch.elf...done.
_idle_thread.lto_priv.58 (p=0x0) at ../../../ChibiOS_16.1.6/os/rt/src/chsys.c:65
65 static void _idle_thread(void *p) {
Loading section startup, size 0xc0 lma 0x8000000
Loading section .text, size 0x62fc lma 0x80000c0
Loading section .data, size 0xb8 lma 0x80063c0
../gdbwrite.boot:3: Error in sourced command file:
Error finishing flash operation
Expected/description: I think gdb can do flash everytime.