fix: Blues Swan Initialization#2955
Merged
fpistm merged 2 commits intostm32duino:mainfrom Apr 7, 2026
Merged
Conversation
5aad8bf to
1fe4411
Compare
- improve comment accuracy - macro variable rename
fpistm
approved these changes
Apr 7, 2026
There was a problem hiding this comment.
Pull request overview
This PR targets the Blues SWAN_R5 board initialization to ensure the 3V3 regulator discharge pin is configured correctly (open-drain) at startup, addressing issue #2954. It also includes broader variant maintenance changes for SWAN_R5 pin mappings and clock configuration documentation, plus a small cleanup/fix for the Blues CYGNET variant.
Changes:
- Fix SWAN_R5 3V3 regulator initialization by configuring the DISCHARGE pin as open-drain (OD) rather than push-pull (PP).
- Restructure SWAN_R5 variant pin definitions /
digitalPin[]layout and annotate mappings more explicitly. - Cleanup CYGNET VMAIN divider macro naming and refine clock-config documentation/comments.
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
variants/STM32L4xx/.../variant_SWAN_R5.h |
Reworks SWAN_R5 pin defines and adds board/regulator/VMAIN helper macros. |
variants/STM32L4xx/.../variant_SWAN_R5.cpp |
Updates digitalPin[] / analogInputPin[]; fixes regulator init (PE6 open-drain); expands clock-config commentary. |
variants/STM32L4xx/.../PeripheralPins_SWAN_R5.c |
Converts to a “manually generated” pin map with schematic reference and many comment clarifications/adjustments. |
variants/STM32L4xx/.../variant_CYGNET.h |
Renames/fixes VMAIN divider constant usage (VMAIN_ADC_DIV_K). |
variants/STM32L4xx/.../variant_CYGNET.cpp |
Documentation/reference cleanup in clock config; minor struct field/comment adjustments. |
variants/STM32L4xx/.../PeripheralPins_CYGNET.c |
Adds schematic link comment. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
variants/STM32L4xx/L4R5Z(G-I)Y_L4R9Z(G-I)Y_L4S5ZIY_L4S9ZIY/variant_SWAN_R5.cpp
Show resolved
Hide resolved
variants/STM32L4xx/L4R5Z(G-I)Y_L4R9Z(G-I)Y_L4S5ZIY_L4S9ZIY/PeripheralPins_SWAN_R5.c
Show resolved
Hide resolved
variants/STM32L4xx/L4R5Z(G-I)Y_L4R9Z(G-I)Y_L4S5ZIY_L4S9ZIY/variant_SWAN_R5.cpp
Show resolved
Hide resolved
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Addresses #2954
Also: Minor clean-up of Blues Cygnet