Skip to content

[Bug]: Incorrect buffer address used for flashing pyOCD internal targets after double buffering was disabled #664

@TeoMahnic

Description

@TeoMahnic

Description

The removal of the default double-buffering mechanism caused some internal targets to fail during programming. The failure occurs because the flash algorithm uses a different buffer address when double buffering is not enabled.

Proposed 3-step solution:

  1. Re-enable double buffering mechanism by default only for internal targets. It will then be used based on the existing condition of number of page_buffers available for the given algorithm.
  2. Go over all existing internal target algorithms and replace begin_data with a single entry in page_buffers, if page_buffers doesn't already exist. Update flash.py to reflect the changes in algorithms. Remove begin_data from the template in generate_flash_algo.py script.
  3. Remove second buffer location entry from page_buffers and correct end_stack for STM32H7xx internal targets, as they are confirmed to have issue with double-buffering mechanism.

Steps to Reproduce

No response

Expected Behavior

No response

Additional Information

No response

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingpyOCDChange is required in shipped pyOCD variant

Type

Projects

Status

Backlog

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions