diff options
author | Marti Bolivar <mbolivar@leaflabs.com> | 2012-01-10 13:51:48 -0500 |
---|---|---|
committer | Marti Bolivar <mbolivar@leaflabs.com> | 2012-04-11 16:56:53 -0400 |
commit | 0ac67559bb4d69557c866bd6bdde4a9402bc2ff0 (patch) | |
tree | a431fc89cfbe159aa5b547a9f00fcb2f61ad76d9 /libmaple | |
parent | 59e02b35a7714a6d10afbf33dd4ea933cfaebab4 (diff) | |
download | librambutan-0ac67559bb4d69557c866bd6bdde4a9402bc2ff0.tar.gz librambutan-0ac67559bb4d69557c866bd6bdde4a9402bc2ff0.zip |
stm32f2/stm32.h: Add support for STM32F207IG.
Signed-off-by: Marti Bolivar <mbolivar@leaflabs.com>
Diffstat (limited to 'libmaple')
-rw-r--r-- | libmaple/include/libmaple/stm32.h | 27 | ||||
-rw-r--r-- | libmaple/stm32f2/include/series/stm32.h | 2 |
2 files changed, 19 insertions, 10 deletions
diff --git a/libmaple/include/libmaple/stm32.h b/libmaple/include/libmaple/stm32.h index 4c0898b..3f86faa 100644 --- a/libmaple/include/libmaple/stm32.h +++ b/libmaple/include/libmaple/stm32.h @@ -36,15 +36,20 @@ extern "C" { #endif -/** - * @brief STM32 series identifiers. +/* + * STM32 series identifiers. + * + * Don't make these into an enum; the preprocessor needs them. */ -typedef enum stm32_series { - STM32_SERIES_F1, /**< F1 series */ - STM32_SERIES_F2, /**< F2 series */ - STM32_SERIES_L1, /**< L1 series */ - STM32_SERIES_F4, /**< F4 series */ -} stm32_series; + +/** STM32F1 series. */ +#define STM32_SERIES_F1 0 +/** STM32F2 series. */ +#define STM32_SERIES_F2 1 +/** STM32L1 series. */ +#define STM32_SERIES_L1 2 +/** STM32F4 series. */ +#define STM32_SERIES_F4 3 /* The series header is responsible for defining: * @@ -83,7 +88,11 @@ typedef enum stm32_series { */ /** - * @brief enum stm32_series value for the MCU being targeted. + * @brief STM32 series value for the MCU being targeted. + * + * At time of writing, allowed values are: STM32_SERIES_F1, + * STM32_SERIES_F2. This set of values will expand as libmaple adds + * support for more STM32 series MCUs. */ #define STM32_MCU_SERIES diff --git a/libmaple/stm32f2/include/series/stm32.h b/libmaple/stm32f2/include/series/stm32.h index 8b14a7d..7ae53b2 100644 --- a/libmaple/stm32f2/include/series/stm32.h +++ b/libmaple/stm32f2/include/series/stm32.h @@ -68,7 +68,7 @@ extern "C" { #define STM32_MCU_SERIES STM32_SERIES_F2 -#if defined(MCU_STM32F207IC) +#if defined(MCU_STM32F207IC) || defined(MCU_STM32F207IG) # define STM32_NR_GPIO_PORTS 9 # define STM32_SRAM_END ((void*)0x20020000) |