From cf6e8a2eee59ced9dcdfb02295bbaf9559e9975e Mon Sep 17 00:00:00 2001 From: Kevin O'Connor Date: Sat, 2 Nov 2019 11:35:27 -0400 Subject: [PATCH] stm32: Define PGx pins on stm32f103 Signed-off-by: Kevin O'Connor --- src/stm32/gpio.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/stm32/gpio.c b/src/stm32/gpio.c index 58919bdd..4b7649dc 100644 --- a/src/stm32/gpio.c +++ b/src/stm32/gpio.c @@ -23,8 +23,10 @@ DECL_ENUMERATION_RANGE("pin", "PE0", GPIO('E', 0), 16); #ifdef GPIOF DECL_ENUMERATION_RANGE("pin", "PF0", GPIO('F', 0), 16); #endif -#ifdef GPIOH +#ifdef GPIOG DECL_ENUMERATION_RANGE("pin", "PG0", GPIO('G', 0), 16); +#endif +#ifdef GPIOH DECL_ENUMERATION_RANGE("pin", "PH0", GPIO('H', 0), 16); #endif #ifdef GPIOI @@ -42,8 +44,11 @@ GPIO_TypeDef * const digital_regs[] = { #ifdef GPIOF ['F' - 'A'] = GPIOF, #endif +#ifdef GPIOG + ['G' - 'A'] = GPIOG, +#endif #ifdef GPIOH - ['G' - 'A'] = GPIOG, GPIOH, + ['H' - 'A'] = GPIOH, #endif #ifdef GPIOI ['I' - 'A'] = GPIOI,