Skip to content

Commit

Permalink
stm32:stm32f3{0|3|7}xxx pinmap Remove GPIO_SPEED_xxx and add legacy p…
Browse files Browse the repository at this point in the history
…inmap

   Pinmaps should not have contained GPIO_SPEED_xxx settings.
   This is board dependent.

   This change adds CONFIG_STM32_USE_LEGACY_PINMAP to allow for
   lazy migration to using pinmaps without speeds.

   The work required to do this can be aided by running tools/stm32_pinmap_tool.py.
   The tools will take a board.h file and a legacy pinmap and outut the required
   changes that one needs to make to a board.h file.

   Eventually, STM32_USE_LEGACY_PINMAP will be deprecated and the legacy
   pinmaps removed from NuttX.

   Any new boards added should set STM32_USE_LEGACY_PINMAP=n and
   fully define the pins in board.h
  • Loading branch information
davids5 authored and raiden00pl committed Apr 19, 2023
1 parent 35258a2 commit 98cd82f
Show file tree
Hide file tree
Showing 7 changed files with 2,905 additions and 1,187 deletions.
18 changes: 15 additions & 3 deletions arch/arm/src/stm32/hardware/stm32_pinmap.h
Original file line number Diff line number Diff line change
Expand Up @@ -109,11 +109,23 @@
/* STM32 F3 Family **********************************************************/

#elif defined(CONFIG_STM32_STM32F30XX)
# include "hardware/stm32f30xxx_pinmap.h"
# if defined(CONFIG_STM32_USE_LEGACY_PINMAP)
# include "hardware/stm32f30xxx_pinmap_legacy.h"
# else
# include "hardware/stm32f30xxx_pinmap.h"
# endif
#elif defined(CONFIG_STM32_STM32F33XX)
# include "hardware/stm32f33xxx_pinmap.h"
# if defined(CONFIG_STM32_USE_LEGACY_PINMAP)
# include "hardware/stm32f33xxx_pinmap_legacy.h"
# else
# include "hardware/stm32f33xxx_pinmap.h"
# endif
#elif defined(CONFIG_STM32_STM32F37XX)
# include "hardware/stm32f37xxx_pinmap.h"
# if defined(CONFIG_STM32_USE_LEGACY_PINMAP)
# include "hardware/stm32f37xxx_pinmap_legacy.h"
# else
# include "hardware/stm32f37xxx_pinmap.h"
# endif

/* STM32 F412 Family ********************************************************/

Expand Down
952 changes: 476 additions & 476 deletions arch/arm/src/stm32/hardware/stm32f30xxx_pinmap.h

Large diffs are not rendered by default.

661 changes: 661 additions & 0 deletions arch/arm/src/stm32/hardware/stm32f30xxx_pinmap_legacy.h

Large diffs are not rendered by default.

598 changes: 299 additions & 299 deletions arch/arm/src/stm32/hardware/stm32f33xxx_pinmap.h

Large diffs are not rendered by default.

450 changes: 450 additions & 0 deletions arch/arm/src/stm32/hardware/stm32f33xxx_pinmap_legacy.h

Large diffs are not rendered by default.

818 changes: 409 additions & 409 deletions arch/arm/src/stm32/hardware/stm32f37xxx_pinmap.h

Large diffs are not rendered by default.

595 changes: 595 additions & 0 deletions arch/arm/src/stm32/hardware/stm32f37xxx_pinmap_legacy.h

Large diffs are not rendered by default.

0 comments on commit 98cd82f

Please sign in to comment.