Skip to content

Make User Button DFU/FRESET optional#376

Merged
hathach merged 3 commits intomasterfrom
pr/1
Jan 26, 2026
Merged

Make User Button DFU/FRESET optional#376
hathach merged 3 commits intomasterfrom
pr/1

Conversation

@hathach
Copy link
Member

@hathach hathach commented Jan 26, 2026

supercede #292 since we cannot push to update the other PR

matsujirushi and others added 2 commits February 2, 2023 17:24
# Conflicts:
#	src/boards/boards.c
#	src/main.c
Copilot AI review requested due to automatic review settings January 26, 2026 09:29
@hathach hathach changed the title Button not required Button DFU/FRESET not required Jan 26, 2026
@hathach hathach changed the title Button DFU/FRESET not required Make User Button DFU/FRESET optional Jan 26, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Makes DFU/OTA button handling optional so the bootloader can build/run on boards without dedicated DFU/FRESET buttons.

Changes:

  • Guard DFU/OTA button reads in main.c behind #if defined(...) checks.
  • Relax board requirements by no longer requiring 2 buttons at compile-time.
  • Conditionally compile/declare button helpers only when relevant button macros exist.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 4 comments.

File Description
src/main.c Avoids referencing undefined button macros; minor whitespace cleanups.
src/boards/boards.h Stops enforcing “2 buttons required” and conditionally exposes button API.
src/boards/boards.c Conditionally compiles button helpers and only initializes buttons when defined.

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

@hathach hathach merged commit 30c7349 into master Jan 26, 2026
102 checks passed
@hathach hathach deleted the pr/1 branch January 26, 2026 10:35
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.

3 participants