Fix STM32F1 pin mapping issue (#744)#1973
Merged
zackees merged 1 commit intoFastLED:masterfrom Aug 1, 2025
Merged
Conversation
- Expand USE_NEW_STM32_PIN_DEFINITIONS condition to include all STM32F1 variants - Fixes pin mapping for Blue Pill and other STM32F1 boards - Enables proper recognition of STM32 pin names like PA7, PB5, PC13 - Resolves compilation errors and non-functional pin assignments - Backward compatible with existing working configurations The legacy pin definitions used incorrect Arduino pin numbers instead of STM32 pin names, causing FastLED to fail on most STM32F1 boards. This fix ensures all STM32F1 boards use the correct pin definitions from fastpin_arm_stm_new.h instead of the broken legacy definitions. Fixes FastLED#744
Member
|
all in one commit too. Nice. |
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.
Summary
This PR fixes the STM32F1 pin mapping issue reported in #744, which prevented FastLED from working on Blue Pill and other STM32F1 boards.
Problem
The issue was that FastLED's pin definition selection logic was too restrictive, causing most STM32F1 boards to fall back to broken legacy pin definitions that use arbitrary Arduino pin numbers instead of proper STM32 pin names like
PA7,PB5, etc.Users experienced:
PA7Solution
Expanded the
USE_NEW_STM32_PIN_DEFINITIONScondition insrc/platforms/arm/stm32/fastpin_arm_stm32.hto include all common STM32F1 board definitions:Changes
PA7,PB5,PC13, etc.)Testing
Verified that:
USE_NEW_STM32_PIN_DEFINITIONSis now properly defined for STM32F1 boardsImpact
This fix resolves the core issue preventing FastLED from working on:
Users can now use FastLED on STM32F1 boards with standard syntax:
Related Issues
Fixes #744 - FastLED does not work on STM32/BluePill ($40 bounty issue)
Checklist