Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

STM32L071: Can't flash L071 device #1253

Closed
5 tasks done
rafaeldantaas opened this issue Jun 6, 2022 · 3 comments · Fixed by #1330
Closed
5 tasks done

STM32L071: Can't flash L071 device #1253

rafaeldantaas opened this issue Jun 6, 2022 · 3 comments · Fixed by #1330

Comments

@rafaeldantaas
Copy link

  • Programmer/board type: [V2-clone]
  • Operating system an version: [macOS Monterey v12.2]
  • stlink tools version and/or git commit hash: [1.7.0]
  • stlink commandline tool name: [st-flash]
  • Target chip (and board, if applicable): [STM32L071]

I'm facing issues to flash a STM32L071 MCU. Found older closed tickets with same behavior, maybe this suppose to be fixed already in v1.7.0... Appreciate any help!

Command line output:

2022-06-06T16:58:26 INFO common.c: Flash page at addr: 0x08000e00 erased
2022-06-06T16:58:26 INFO common.c: Flash page at addr: 0x08000e80 erased
2022-06-06T16:58:26 INFO common.c: Flash page at addr: 0x08000f00 erased
2022-06-06T16:58:26 INFO common.c: Flash page at addr: 0x08000f80 erased
2022-06-06T16:58:26 INFO common.c: Flash page at addr: 0x08001000 erased
2022-06-06T16:58:26 INFO common.c: Flash page at addr: 0x08001080 erased
2022-06-06T16:58:26 INFO common.c: Flash page at addr: 0x08001100 erased
2022-06-06T16:58:26 INFO common.c: Flash page at addr: 0x08001180 erased
2022-06-06T16:58:26 INFO common.c: Flash page at addr: 0x08001200 erased
2022-06-06T16:58:26 INFO common.c: Flash page at addr: 0x08001280 erased
2022-06-06T16:58:26 INFO common.c: Flash page at addr: 0x08001300 erased
2022-06-06T16:58:26 INFO common.c: Finished erasing 39 pages of 128 (0x80) bytes
2022-06-06T16:58:26 INFO common.c: Starting Flash write for L0
2022-06-06T16:58:26 INFO common.c: Starting Half page flash write for STM32L core id
2022-06-06T16:58:26 INFO flash_loader.c: Successfully loaded flash loader in sram
2022-06-06T16:58:26 INFO flash_loader.c: Clear DFSR
2022-06-06T16:58:26 INFO common.c: Go to Thumb mode
2022-06-06T16:58:26 ERROR flash_loader.c: Write error
2022-06-06T16:58:26 WARN flash_loader.c: Loader state: R2 0x40 R15 0xFFFFFFFE
2022-06-06T16:58:26 WARN flash_loader.c: MCU state: DHCSR 0x103000B DFSR 0x8 CFSR 0x0 HFSR 0x0
2022-06-06T16:58:26 WARN common.c: l1_stlink_flash_loader_run(0x8000000) failed! == -1
2022-06-06T16:58:26 WARN common.c:
write_half_pages failed == -1
@fdelbos
Copy link

fdelbos commented Oct 13, 2022

I have the same error with an L011K4 nucleo

@Nightwalker-87
Copy link
Member

For debugging reasons this should be repeated with:
st-flash --debug --reset write $(your binary name).bin 0x8000000

@Nightwalker-87 Nightwalker-87 changed the title [STM32L071]: Can't flash L071 device STM32L071: Can't flash L071 device Jan 6, 2023
@Nightwalker-87 Nightwalker-87 pinned this issue Apr 9, 2023
@Nightwalker-87
Copy link
Member

Duplicate of #681.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
No open projects
Status: Done
Development

Successfully merging a pull request may close this issue.

3 participants