From 15e182dd827a48ab6f5f040f052ac201a915f2bc Mon Sep 17 00:00:00 2001 From: Giovanni Di Sirio Date: Mon, 3 Aug 2015 10:00:06 +0000 Subject: Added support for ports J and K to GPIOv2. git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@8149 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- os/hal/boards/ST_STM32F746G_DISCOVERY/board.c | 10 +++++++++- os/hal/ports/STM32/LLD/GPIOv2/pal_lld.h | 12 ++++++++++++ 2 files changed, 21 insertions(+), 1 deletion(-) (limited to 'os/hal') diff --git a/os/hal/boards/ST_STM32F746G_DISCOVERY/board.c b/os/hal/boards/ST_STM32F746G_DISCOVERY/board.c index 4d546e3d6..c340f41d6 100644 --- a/os/hal/boards/ST_STM32F746G_DISCOVERY/board.c +++ b/os/hal/boards/ST_STM32F746G_DISCOVERY/board.c @@ -57,7 +57,15 @@ const PALConfig pal_default_config = { #endif #if STM32_HAS_GPIOI {VAL_GPIOI_MODER, VAL_GPIOI_OTYPER, VAL_GPIOI_OSPEEDR, VAL_GPIOI_PUPDR, - VAL_GPIOI_ODR, VAL_GPIOI_AFRL, VAL_GPIOI_AFRH} + VAL_GPIOI_ODR, VAL_GPIOI_AFRL, VAL_GPIOI_AFRH}, +#endif +#if STM32_HAS_GPIOJ + {VAL_GPIOJ_MODER, VAL_GPIOJ_OTYPER, VAL_GPIOJ_OSPEEDR, VAL_GPIOJ_PUPDR, + VAL_GPIOJ_ODR, VAL_GPIOJ_AFRL, VAL_GPIOJ_AFRH}, +#endif +#if STM32_HAS_GPIOK + {VAL_GPIOK_MODER, VAL_GPIOK_OTYPER, VAL_GPIOK_OSPEEDR, VAL_GPIOK_PUPDR, + VAL_GPIOK_ODR, VAL_GPIOK_AFRL, VAL_GPIOK_AFRH} #endif }; #endif diff --git a/os/hal/ports/STM32/LLD/GPIOv2/pal_lld.h b/os/hal/ports/STM32/LLD/GPIOv2/pal_lld.h index 6165530c4..9936be707 100644 --- a/os/hal/ports/STM32/LLD/GPIOv2/pal_lld.h +++ b/os/hal/ports/STM32/LLD/GPIOv2/pal_lld.h @@ -143,6 +143,8 @@ #undef GPIOG #undef GPIOH #undef GPIOI +#undef GPIOJ +#undef GPIOK /** * @name GPIO ports definitions @@ -157,6 +159,8 @@ #define GPIOG ((stm32_gpio_t *)GPIOG_BASE) #define GPIOH ((stm32_gpio_t *)GPIOH_BASE) #define GPIOI ((stm32_gpio_t *)GPIOI_BASE) +#define GPIOJ ((stm32_gpio_t *)GPIOJ_BASE) +#define GPIOK ((stm32_gpio_t *)GPIOK_BASE) /** @} */ /*===========================================================================*/ @@ -251,6 +255,14 @@ typedef struct { /** @brief Port I setup data.*/ stm32_gpio_setup_t PIData; #endif +#if STM32_HAS_GPIOJ || defined(__DOXYGEN__) + /** @brief Port I setup data.*/ + stm32_gpio_setup_t PJData; +#endif +#if STM32_HAS_GPIOK || defined(__DOXYGEN__) + /** @brief Port I setup data.*/ + stm32_gpio_setup_t PKData; +#endif } PALConfig; /** -- cgit v1.2.3