1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-13 11:29:58 +03:00

STM32H7 add UART4 pins (#14341)

* stm32h7: add uart4 ph13 and ph14

* stm32h7: increase UARTHARDWARE_MAX_PINS

* Update src/platform/STM32/serial_uart_stm32h7xx.c

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

* Update src/platform/STM32/serial_uart_stm32h7xx.c

Co-authored-by: Petr Ledvina <ledvinap@gmail.com>

---------

Co-authored-by: Mark Haslinghuis <mark@numloq.nl>
Co-authored-by: Petr Ledvina <ledvinap@gmail.com>
This commit is contained in:
Alex Klimaj 2025-04-15 04:15:15 -06:00 committed by GitHub
parent 9f18593be7
commit 9eb7d1920b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 6 additions and 3 deletions

View file

@ -399,7 +399,7 @@ extern uint8_t _dmaram_end__;
#elif defined(STM32F7)
#define UARTHARDWARE_MAX_PINS 4
#elif defined(STM32H7)
#define UARTHARDWARE_MAX_PINS 5
#define UARTHARDWARE_MAX_PINS 6
#elif defined(STM32G4)
#define UARTHARDWARE_MAX_PINS 3
#endif

View file

@ -207,14 +207,17 @@ const uartHardware_t uartHardware[UARTDEV_COUNT] = {
{ DEFIO_TAG_E(PA11), GPIO_AF6_UART4 },
{ DEFIO_TAG_E(PB8), GPIO_AF8_UART4 },
{ DEFIO_TAG_E(PC11), GPIO_AF8_UART4 },
{ DEFIO_TAG_E(PD0), GPIO_AF8_UART4 }
{ DEFIO_TAG_E(PD0), GPIO_AF8_UART4 },
{ DEFIO_TAG_E(PH14), GPIO_AF8_UART4 },
},
.txPins = {
{ DEFIO_TAG_E(PA0), GPIO_AF8_UART4 },
{ DEFIO_TAG_E(PA12), GPIO_AF6_UART4 },
{ DEFIO_TAG_E(PB9), GPIO_AF8_UART4 },
{ DEFIO_TAG_E(PC10), GPIO_AF8_UART4 },
{ DEFIO_TAG_E(PD1), GPIO_AF8_UART4 }
{ DEFIO_TAG_E(PD1), GPIO_AF8_UART4 },
{ DEFIO_TAG_E(PH13), GPIO_AF8_UART4 },
},
.rcc = RCC_APB1L(UART4),
.irqn = UART4_IRQn,