Skip to content

Added support for empty size modifier in DfuSeFormat#21

Merged
benedekkupper merged 1 commit into
IntergatedCircuits:mainfrom
Standa-R:SupportEmptySizeModifierInDfuSeFormat
May 24, 2026
Merged

Added support for empty size modifier in DfuSeFormat#21
benedekkupper merged 1 commit into
IntergatedCircuits:mainfrom
Standa-R:SupportEmptySizeModifierInDfuSeFormat

Conversation

@Standa-R

@Standa-R Standa-R commented May 21, 2026

Copy link
Copy Markdown
Contributor

Some STM32 MCUs, e.g., the STM32L07x family, omit the size modifier in their alternate strings. This improves the Regex to account for that and adjusts the following logic, see fix #20 for more details.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates DFUSe alternate-setting string parsing to handle STM32 devices that omit the size modifier (K/M/space) in memory layout descriptors, addressing issue #20.

Changes:

  • Relaxed the DFUSe memory layout regex to allow an empty size modifier.
  • Updated parsing logic to safely handle a missing size modifier without indexing into an empty string.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread DeviceProgramming/Dfu/Device.cs
@benedekkupper

Copy link
Copy Markdown
Member

Thanks for the PR! Two small things to fix in the commit message:

  1. Remove the second half of the title, where the "added testing" expression is misleading, and overall that part isn't necessary.
  2. Add a Signed-off-by to the bottom of the commit message (there is built-in support for adding it in all git tools). This is a new requirement for all commits, you are the first to be tripped by it.

Signed-off-by: stanislav.rozum <stanislav.rozum@seznam.cz>
@Standa-R

Standa-R commented May 23, 2026

Copy link
Copy Markdown
Contributor Author

I am a bit lost in these waters, learned about amend, and Signed-off-by. I probably made a mistake, as I see a new commit instead of the previous one being edited, and I am going to attempt to fix that.

@Standa-R Standa-R force-pushed the SupportEmptySizeModifierInDfuSeFormat branch from b12158f to ae37c4c Compare May 23, 2026 20:22
@Standa-R

Copy link
Copy Markdown
Contributor Author

Ah, ok, easier than I thought. Thanks for the advice and the opportunity to learn new things.

@benedekkupper benedekkupper merged commit d0c9291 into IntergatedCircuits:main May 24, 2026
5 checks passed
@benedekkupper

Copy link
Copy Markdown
Member

Thanks for your contribution! I will publish a new release with your fix in the coming weeks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Parse DfuSeFormat fails for STM32L07x family

3 participants