From 9c8b3225efd5ee816ad840ea97ba7bb92ff17941 Mon Sep 17 00:00:00 2001 From: Marti Bolivar Date: Tue, 24 Apr 2012 05:01:28 -0400 Subject: stm32.h: Various updates, mostly to help STM32F1 line support. Add STM32_HAVE_USB feature test macro requirement for . This will let us test if we've got a USB peripheral. wirish/stm32f1/boards_setup.cpp is set up to use this when turning on USB CDC ACM support at init() time. Rework the STM32F1 to make it easier to support the various lines that subdivide that series. We don't really support anything besides performance line yet, but there's been enough enthusiasm for value and connectivity line support in the past that these hooks seem worth adding. This means adding an STM32_F1_LINE macro and STM32_F1_LINE_[PERFORMANCE,VALUE,ACCESS,CONNECTIVITY] macros for values that STM32_F1_LINE can take, and generalizing the rest of the file to begin taking this into account. Some TODOs remain, but filling these in is the responsibility of future libmaple porting efforts. One pleasant consequence of the F1 stm32.h rework is that the build system no longer has to tell us what density of F103 we're building for, so remove that from the relevant support/make/board-includes/ files. Add some tweaks to and the STM32F2 stm32.h header to make sure this went through properly, and continues to go through properly in the future. --- support/make/board-includes/maple.mk | 2 -- support/make/board-includes/maple_RET6.mk | 2 -- support/make/board-includes/maple_mini.mk | 2 -- support/make/board-includes/maple_native.mk | 2 -- support/make/board-includes/olimex_stm32_h103.mk | 2 -- 5 files changed, 10 deletions(-) (limited to 'support') diff --git a/support/make/board-includes/maple.mk b/support/make/board-includes/maple.mk index a84f0ac..d31ad83 100644 --- a/support/make/board-includes/maple.mk +++ b/support/make/board-includes/maple.mk @@ -2,6 +2,4 @@ MCU := STM32F103RB PRODUCT_ID := 0003 ERROR_LED_PORT := GPIOA ERROR_LED_PIN := 5 -DENSITY := STM32_MEDIUM_DENSITY -TARGET_FLAGS += -D$(DENSITY) MCU_SERIES := stm32f1 diff --git a/support/make/board-includes/maple_RET6.mk b/support/make/board-includes/maple_RET6.mk index 8bd9b90..d06f068 100644 --- a/support/make/board-includes/maple_RET6.mk +++ b/support/make/board-includes/maple_RET6.mk @@ -2,6 +2,4 @@ MCU := STM32F103RE PRODUCT_ID := 0003 ERROR_LED_PORT := GPIOA ERROR_LED_PIN := 5 -DENSITY := STM32_HIGH_DENSITY -TARGET_FLAGS += -D$(DENSITY) MCU_SERIES := stm32f1 diff --git a/support/make/board-includes/maple_mini.mk b/support/make/board-includes/maple_mini.mk index 4a3e2ab..835adc3 100644 --- a/support/make/board-includes/maple_mini.mk +++ b/support/make/board-includes/maple_mini.mk @@ -2,6 +2,4 @@ MCU := STM32F103CB PRODUCT_ID := 0003 ERROR_LED_PORT := GPIOB ERROR_LED_PIN := 1 -DENSITY := STM32_MEDIUM_DENSITY -TARGET_FLAGS += -D$(DENSITY) MCU_SERIES := stm32f1 diff --git a/support/make/board-includes/maple_native.mk b/support/make/board-includes/maple_native.mk index cd07c21..3e88e7b 100644 --- a/support/make/board-includes/maple_native.mk +++ b/support/make/board-includes/maple_native.mk @@ -2,6 +2,4 @@ MCU := STM32F103ZE PRODUCT_ID := 0003 ERROR_LED_PORT := GPIOC ERROR_LED_PIN := 15 -DENSITY := STM32_HIGH_DENSITY -TARGET_FLAGS += -D$(DENSITY) MCU_SERIES := stm32f1 diff --git a/support/make/board-includes/olimex_stm32_h103.mk b/support/make/board-includes/olimex_stm32_h103.mk index 1d84cc2..96d6976 100644 --- a/support/make/board-includes/olimex_stm32_h103.mk +++ b/support/make/board-includes/olimex_stm32_h103.mk @@ -2,6 +2,4 @@ MCU := STM32F103RB PRODUCT_ID := 0003 ERROR_LED_PORT := GPIOC ERROR_LED_PIN := 12 -DENSITY := STM32_MEDIUM_DENSITY -TARGET_FLAGS += -D$(DENSITY) MCU_SERIES := stm32f1 -- cgit v1.2.3