Skip to content

Commit

Permalink
stm32/boards: Add missing LPUART macros for H7 HAL.
Browse files Browse the repository at this point in the history
The STM32H7xx HAL LPUART AF macros are missing the number, this HAL is the
only one that's inconsistent in the way it defines LPUART AF macros, so we
only need to define them for H7.
  • Loading branch information
iabdalkader authored and dpgeorge committed Dec 1, 2022
1 parent 771c16f commit fb7d211
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions ports/stm32/boards/stm32h7xx_hal_conf_base.h
Expand Up @@ -101,4 +101,10 @@
// HAL parameter assertions are disabled
#define assert_param(expr) ((void)0)

// The STM32H7xx HAL defines LPUART1 AF macros without numbers.
#ifndef GPIO_AF3_LPUART1
#define GPIO_AF3_LPUART1 GPIO_AF3_LPUART
#define GPIO_AF8_LPUART1 GPIO_AF8_LPUART
#endif

#endif // MICROPY_INCLUDED_STM32H7XX_HAL_CONF_BASE_H

0 comments on commit fb7d211

Please sign in to comment.