Loading...
 

Zephyr project on STM32

   Zephyr Workbench, a VSCode extension to manage Zephyr on STM32.
It enables users to easily create, develop, and debug Zephyr applications.
Main features:
  • Install host dependencies.
  • Import toolchain and SDK.
  • Create, configure, build and manage apps.
  • Debug STM32.
You can directly download it from the VSCode marketplace
For more details, visit the Zephyr Workbench

System Workbench for STM32


Debugging issue

Good morning all,
I’m very enthusiast STM32 user and love the System Workbench coz of all Open Source technologies, but I found a really limiting issue for my projects.

I need to partition the ROM area into sections and I does it using ld script.
I used 2 methods:
- (DP) Direct Partitioning: partitioning in memory definitions and placing of section at desired memory partition;
- (SA) Section Address: single flash partition and positioning of the sections at fixed addresses in section definitions.

I test using 3 nucleo boards: NUCLEO-F091RC, NUCLEO-F4303K8, NUCLEO-F411RE

I create 2 different partions for all the board and using the 2 methods above:
- (1-1-2-R) that means 1K + 1K + 2K + REST of ROM
- (6-2-16-R) that means 6K + 2K + 16K + REST of ROM

I test the builds using SystemWorkbench (SW) and ST-Link Utility (ST-L) for all the combinations.

RESULTS:
Compile  : ALL OK
Link  : ALL OK

DEBUG REPORT:

NUCLEO-F091RC(1-1-2-R) - SW(1-1-2-R) - ST-L(6-2-16-R) - SW(6-2-16-R) - ST-L
(DP)OKOKFAIL!!!OK
(SA)OKOKFAIL!!!OK

NUCLEO-F4303K8(1-1-2-R) - SW(1-1-2-R) - ST-L(6-2-16-R) - SW(6-2-16-R) - ST-L
(DP)OKOKFAIL!!!OK
(SA)OKOKFAIL!!!OK

NUCLEO-F411RE(1-1-2-R) - SW(1-1-2-R) - ST-L(6-2-16-R) - SW(6-2-16-R) - ST-L
(DP)OKOKOKOK
(SA)OKOKOKOK


As you can see, I can’t debug in SystemWorkbench when using NUCLEO-F091RC and NUCLEO-F4303K8 in (6-2-16-R) partitioning mode, but I can normally debug when use the NUCLEO-F411RE.

I can Run, Halt, Step, Reset, etc... normally with all the 3 boards in all situations using ST-Link Utility.

Because of the dimensions I can’t attach it, but I link the zip file of the enteire workspace with the three projects and with all the sistuations mentioned above:
https://drive.google.com/open?id=0B9VxKVnIagPvZkJ2ZmdneG1xT00Question

In all projects there are 4 configurations and 4 linker scripts (one per configuration), at the very begin of every linker script there are detailed explanations of tools versions and memory partition used.

(The amap.exe included to simply navigate the map files is a Sergey Sikorskiy project and can be freely downloaded here: http://www.sikorskiy.net/prj/amapQuestion )

Hope this can help you guys to resolve this problem.

Best regards,

Silvio Vallorani.

After an “I DON’T KNOW WHAT/WHY” operation, now my NUCLEO-F4303K8 normally debug...

The only things I does are:
- use a fresh installation of eclipse mars-2;
- install in it the “GNU ARM PLUGIN” that can be downloaded here: http://gnuarmeclipse.github.io/plugins/install/Question
- create an empty nucleo-f3 project,
- modified the linker script the GNU ARM PLUGIN generate to reproduce my (6-2-16-R) scheme,
- flash into, debug, and BOOM, it debug!

The only thingh I noticed is the “mem.ld” it produce which has the CCMRAM non empty field

RAM (xrw)  : ORIGIN = 0x20000000, LENGTH = 12K
CCMRAM (xrw)  : ORIGIN = 0x10000000, LENGTH = 4K /* < - - - - - - - - */
BOOT (rx)  : ORIGIN = 0x8000000, LENGTH = 6K
EEP_EMU (rx)  : ORIGIN = 0x8001800, LENGTH = 2K
BOOTLOADER (rx)  : ORIGIN = 0x8002000, LENGTH = 16K
FLASH (rx)  : ORIGIN = 0x8006000, LENGTH = 40K
FLASHB1 (rx)  : ORIGIN = 0x00000000, LENGTH = 0
EXTMEMB0 (rx)  : ORIGIN = 0x00000000, LENGTH = 0
EXTMEMB1 (rx)  : ORIGIN = 0x00000000, LENGTH = 0
EXTMEMB2 (rx)  : ORIGIN = 0x00000000, LENGTH = 0
EXTMEMB3 (rx)  : ORIGIN = 0x00000000, LENGTH = 0
MEMORY_ARRAY (xrw)  : ORIGIN = 0x20002000, LENGTH = 0

I really don’t know if this resolve the problem, but from now, i can debug also with the SystemWorkbench projects I posted above, with and without the CCMRAM defined.

Buh?!?!


 

Newest Forum Posts

  1. Монтаж камина с грилем в Москве - установка и барбекю by KpddomErorb, 2025-05-10 18:28
  2. SPI on Nucleo_STMH533RE by royjamil, 2025-05-04 20:13
  3. SPI on Nucleo_STMH533RE by higginsa1, 2025-03-25 07:37
  4. SPI on Nucleo_STMH533RE by royjamil, 2025-03-23 11:31
  5. SPI on Nucleo_STMH533RE by higginsa1, 2025-03-23 09:33
  6. Configuring DMA for ADC in SW? by sam.hodgson, 2025-03-04 12:58
  7. Build a project in "release" mode by info@creosrl.it, 2025-02-20 18:12
  8. Build a project in "release" mode by info@creosrl.it, 2025-02-20 17:05
  9. Build a project in "release" mode by tang, 2025-02-20 10:36
  10. Build a project in "release" mode by info@creosrl.it, 2025-02-19 17:35

Last-Modified Blogs