aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal/ports/STM32
diff options
context:
space:
mode:
authorGiovanni Di Sirio <gdisirio@gmail.com>2017-01-17 15:17:45 +0000
committerGiovanni Di Sirio <gdisirio@gmail.com>2017-01-17 15:17:45 +0000
commita9c6dcbe6fc2ba591bd865f8f3014116f44f27cd (patch)
tree4f2c133e7ecba2ebd0e584c748b0a10b3ad2a3e3 /os/hal/ports/STM32
parent4765efbaa9d939601a65b63a7f43cbe44e947aec (diff)
downloadChibiOS-a9c6dcbe6fc2ba591bd865f8f3014116f44f27cd.tar.gz
ChibiOS-a9c6dcbe6fc2ba591bd865f8f3014116f44f27cd.tar.bz2
ChibiOS-a9c6dcbe6fc2ba591bd865f8f3014116f44f27cd.zip
More platform.mk files updated.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@10060 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os/hal/ports/STM32')
-rw-r--r--os/hal/ports/STM32/STM32F0xx/platform.mk115
-rw-r--r--os/hal/ports/STM32/STM32F1xx/platform.mk116
-rw-r--r--os/hal/ports/STM32/STM32F1xx/platform_f105_f107.mk123
-rw-r--r--os/hal/ports/STM32/STM32F3xx/platform.mk110
-rw-r--r--os/hal/ports/STM32/STM32F4xx/platform.mk133
-rw-r--r--os/hal/ports/STM32/STM32F7xx/platform.mk1
6 files changed, 139 insertions, 459 deletions
diff --git a/os/hal/ports/STM32/STM32F0xx/platform.mk b/os/hal/ports/STM32/STM32F0xx/platform.mk
index 4a33ceec5..e2f9528f4 100644
--- a/os/hal/ports/STM32/STM32F0xx/platform.mk
+++ b/os/hal/ports/STM32/STM32F0xx/platform.mk
@@ -1,97 +1,34 @@
-# List of all the STM32F0xx platform files.
+# Required platform files.
+PLATFORMSRC := $(CHIBIOS)/os/hal/ports/common/ARMCMx/nvic.c \
+ $(CHIBIOS)/os/hal/ports/STM32/STM32F0xx/hal_lld.c
+
+# Required include directories.
+PLATFORMINC := $(CHIBIOS)/os/hal/ports/common/ARMCMx \
+ $(CHIBIOS)/os/hal/ports/STM32/STM32F0xx
+
+# Optional platform files.
ifeq ($(USE_SMART_BUILD),yes)
HALCONF := $(strip $(shell cat halconf.h | egrep -e "\#define"))
-PLATFORMSRC := $(CHIBIOS)/os/hal/ports/common/ARMCMx/nvic.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F0xx/hal_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv1/stm32_dma.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_st_lld.c
-ifneq ($(findstring HAL_USE_ADC TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/ADCv1/hal_adc_lld.c
-endif
-ifneq ($(findstring HAL_USE_CAN TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1/hal_can_lld.c
-endif
-ifneq ($(findstring HAL_USE_DAC TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1/hal_dac_lld.c
-endif
ifneq ($(findstring HAL_USE_EXT TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1/hal_ext_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F0xx/hal_ext_lld_isr.c
-endif
-ifneq ($(findstring HAL_USE_PAL TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv2/hal_pal_lld.c
-endif
-ifneq ($(findstring HAL_USE_I2C TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/I2Cv2/hal_i2c_lld.c
-endif
-ifneq ($(findstring HAL_USE_RTC TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/RTCv2/hal_rtc_lld.c
-endif
-ifneq ($(findstring HAL_USE_I2S TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv2/hal_i2s_lld.c
-endif
-ifneq ($(findstring HAL_USE_SPI TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv2/hal_spi_lld.c
-endif
-ifneq ($(findstring HAL_USE_GPT TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_gpt_lld.c
-endif
-ifneq ($(findstring HAL_USE_ICU TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_icu_lld.c
-endif
-ifneq ($(findstring HAL_USE_PWM TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_pwm_lld.c
-endif
-ifneq ($(findstring HAL_USE_SERIAL TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv2/hal_serial_lld.c
-endif
-ifneq ($(findstring HAL_USE_UART TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv2/hal_uart_lld.c
-endif
-ifneq ($(findstring HAL_USE_USB TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/USBv1/hal_usb_lld.c
-endif
-ifneq ($(findstring HAL_USE_WDG TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/xWDGv1/hal_wdg_lld.c
+PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/STM32F0xx/hal_ext_lld_isr.c
endif
else
-PLATFORMSRC := $(CHIBIOS)/os/hal/ports/common/ARMCMx/nvic.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F0xx/hal_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F0xx/hal_ext_lld_isr.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/ADCv1/hal_adc_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1/hal_can_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1/hal_dac_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv1/stm32_dma.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1/hal_ext_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv2/hal_pal_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/I2Cv2/hal_i2c_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/RTCv2/hal_rtc_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv2/hal_i2s_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv2/hal_spi_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_gpt_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_icu_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_pwm_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_st_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv2/hal_serial_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv2/hal_uart_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USBv1/hal_usb_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/xWDGv1/hal_wdg_lld.c
+PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/STM32F0xx/hal_ext_lld_isr.c
endif
-# Required include directories
-PLATFORMINC := $(CHIBIOS)/os/hal/ports/common/ARMCMx \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F0xx \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/ADCv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv2 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/I2Cv2 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/RTCv2 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv2 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv2 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USBv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/xWDGv1
+# Drivers compatible with the platform.
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/ADCv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv2/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/I2Cv2/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/RTCv2/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv2/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv2/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/USBv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/xWDGv1/driver.mk
+ \ No newline at end of file
diff --git a/os/hal/ports/STM32/STM32F1xx/platform.mk b/os/hal/ports/STM32/STM32F1xx/platform.mk
index e52e9d66c..7703bc9be 100644
--- a/os/hal/ports/STM32/STM32F1xx/platform.mk
+++ b/os/hal/ports/STM32/STM32F1xx/platform.mk
@@ -1,98 +1,38 @@
-# List of all the STM32F1xx platform files.
+# Required platform files.
+PLATFORMSRC := $(CHIBIOS)/os/hal/ports/common/ARMCMx/nvic.c \
+ $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_lld.c
+
+# Required include directories.
+PLATFORMINC := $(CHIBIOS)/os/hal/ports/common/ARMCMx \
+ $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx
+
+# Optional platform files.
ifeq ($(USE_SMART_BUILD),yes)
HALCONF := $(strip $(shell cat halconf.h | egrep -e "\#define"))
-PLATFORMSRC := $(CHIBIOS)/os/hal/ports/common/ARMCMx/nvic.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv1/stm32_dma.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_st_lld.c
-ifneq ($(findstring HAL_USE_ADC TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_adc_lld.c
-endif
-ifneq ($(findstring HAL_USE_CAN TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1/hal_can_lld.c
-endif
-ifneq ($(findstring HAL_USE_DAC TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1/hal_dac_lld.c
-endif
ifneq ($(findstring HAL_USE_EXT TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1/hal_ext_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_ext_lld_isr.c
-endif
-ifneq ($(findstring HAL_USE_PAL TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv1/hal_pal_lld.c
-endif
-ifneq ($(findstring HAL_USE_I2C TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/I2Cv1/hal_i2c_lld.c
-endif
-ifneq ($(findstring HAL_USE_RTC TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/RTCv1/hal_rtc_lld.c
+PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_ext_lld_isr.c
endif
-ifneq ($(findstring HAL_USE_SDC TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/SDIOv1/hal_sdc_lld.c
-endif
-ifneq ($(findstring HAL_USE_SPI TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv1/hal_spi_lld.c
-endif
-ifneq ($(findstring HAL_USE_GPT TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_gpt_lld.c
-endif
-ifneq ($(findstring HAL_USE_ICU TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_icu_lld.c
-endif
-ifneq ($(findstring HAL_USE_PWM TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_pwm_lld.c
-endif
-ifneq ($(findstring HAL_USE_SERIAL TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv1/hal_serial_lld.c
-endif
-ifneq ($(findstring HAL_USE_UART TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv1/hal_uart_lld.c
-endif
-ifneq ($(findstring HAL_USE_USB TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/USBv1/hal_usb_lld.c
-endif
-ifneq ($(findstring HAL_USE_WDG TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/xWDGv1/hal_wdg_lld.c
+ifneq ($(findstring HAL_USE_ADC TRUE,$(HALCONF)),)
+PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_adc_lld.c
endif
else
-PLATFORMSRC := $(CHIBIOS)/os/hal/ports/common/ARMCMx/nvic.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_adc_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_ext_lld_isr.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1/hal_can_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1/hal_dac_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv1/stm32_dma.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1/hal_ext_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv1/hal_pal_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/I2Cv1/hal_i2c_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/RTCv1/hal_rtc_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/SDIOv1/hal_sdc_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv1/hal_spi_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_gpt_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_icu_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_pwm_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_st_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv1/hal_serial_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv1/hal_uart_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USBv1/hal_usb_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/xWDGv1/hal_wdg_lld.c
+ $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_adc_lld.c
+PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_ext_lld_isr.c
endif
-# Required include directories
-PLATFORMINC := $(CHIBIOS)/os/hal/ports/common/ARMCMx \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/I2Cv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/RTCv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/SDIOv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USBv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/xWDGv1
+# Drivers compatible with the platform.
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/I2Cv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/RTCv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/SDIOv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/USBv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/xWDGv1/driver.mk
diff --git a/os/hal/ports/STM32/STM32F1xx/platform_f105_f107.mk b/os/hal/ports/STM32/STM32F1xx/platform_f105_f107.mk
index 41526dc9b..b57677d74 100644
--- a/os/hal/ports/STM32/STM32F1xx/platform_f105_f107.mk
+++ b/os/hal/ports/STM32/STM32F1xx/platform_f105_f107.mk
@@ -1,102 +1,39 @@
-# List of all the STM32F1xx platform files.
+# Required platform files.
+PLATFORMSRC := $(CHIBIOS)/os/hal/ports/common/ARMCMx/nvic.c \
+ $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_lld.c
+
+# Required include directories.
+PLATFORMINC := $(CHIBIOS)/os/hal/ports/common/ARMCMx \
+ $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx
+
+# Optional platform files.
ifeq ($(USE_SMART_BUILD),yes)
HALCONF := $(strip $(shell cat halconf.h | egrep -e "\#define"))
-PLATFORMSRC := $(CHIBIOS)/os/hal/ports/common/ARMCMx/nvic.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv1/stm32_dma.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_st_lld.c
-ifneq ($(findstring HAL_USE_ADC TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_adc_lld.c
-endif
-ifneq ($(findstring HAL_USE_CAN TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1/hal_can_lld.c
-endif
-ifneq ($(findstring HAL_USE_DAC TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1/hal_dac_lld.c
-endif
ifneq ($(findstring HAL_USE_EXT TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1/hal_ext_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_ext_lld_isr.c
-endif
-ifneq ($(findstring HAL_USE_PAL TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv1/hal_pal_lld.c
-endif
-ifneq ($(findstring HAL_USE_I2C TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/I2Cv1/hal_i2c_lld.c
-endif
-ifneq ($(findstring HAL_USE_MAC TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/MACv1/hal_mac_lld.c
-endif
-ifneq ($(findstring HAL_USE_USB TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/OTGv1/hal_usb_lld.c
+PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_ext_lld_isr.c
endif
-ifneq ($(findstring HAL_USE_RTC TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/RTCv1/hal_rtc_lld.c
-endif
-ifneq ($(findstring HAL_USE_SDC TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/SDIOv1/hal_sdc_lld.c
-endif
-ifneq ($(findstring HAL_USE_SPI TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv1/hal_spi_lld.c
-endif
-ifneq ($(findstring HAL_USE_GPT TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_gpt_lld.c
-endif
-ifneq ($(findstring HAL_USE_ICU TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_icu_lld.c
-endif
-ifneq ($(findstring HAL_USE_PWM TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_pwm_lld.c
-endif
-ifneq ($(findstring HAL_USE_SERIAL TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv1/hal_serial_lld.c
-endif
-ifneq ($(findstring HAL_USE_UART TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv1/hal_uart_lld.c
-endif
-ifneq ($(findstring HAL_USE_WDG TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/xWDGv1/hal_wdg_lld.c
+ifneq ($(findstring HAL_USE_ADC TRUE,$(HALCONF)),)
+PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_adc_lld.c
endif
else
-PLATFORMSRC := $(CHIBIOS)/os/hal/ports/common/ARMCMx/nvic.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_adc_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_ext_lld_isr.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1/hal_can_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1/hal_dac_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv1/stm32_dma.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1/hal_ext_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv1/hal_pal_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/I2Cv1/hal_i2c_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/MACv1/hal_mac_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/OTGv1/hal_usb_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/RTCv1/hal_rtc_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/SDIOv1/hal_sdc_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv1/hal_spi_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_gpt_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_icu_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_pwm_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_st_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv1/hal_serial_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv1/hal_uart_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/xWDGv1/hal_wdg_lld.c
+ $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_adc_lld.c
+PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx/hal_ext_lld_isr.c
endif
-# Required include directories
-PLATFORMINC := $(CHIBIOS)/os/hal/ports/common/ARMCMx \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F1xx \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/I2Cv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/MACv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/OTGv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/RTCv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/SDIOv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/xWDGv1
+# Drivers compatible with the platform.
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/I2Cv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/MACv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/OTGv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/RTCv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/xWDGv1/driver.mk
+
+ \ No newline at end of file
diff --git a/os/hal/ports/STM32/STM32F3xx/platform.mk b/os/hal/ports/STM32/STM32F3xx/platform.mk
index 028a707cc..61094702e 100644
--- a/os/hal/ports/STM32/STM32F3xx/platform.mk
+++ b/os/hal/ports/STM32/STM32F3xx/platform.mk
@@ -1,93 +1,33 @@
-# List of all the STM32F3xx platform files.
+# Required platform files.
+PLATFORMSRC := $(CHIBIOS)/os/hal/ports/common/ARMCMx/nvic.c \
+ $(CHIBIOS)/os/hal/ports/STM32/STM32F3xx/hal_lld.c
+
+# Required include directories.
+PLATFORMINC := $(CHIBIOS)/os/hal/ports/common/ARMCMx \
+ $(CHIBIOS)/os/hal/ports/STM32/STM32F3xx
+
+# Optional platform files.
ifeq ($(USE_SMART_BUILD),yes)
HALCONF := $(strip $(shell cat halconf.h | egrep -e "\#define"))
-PLATFORMSRC := $(CHIBIOS)/os/hal/ports/common/ARMCMx/nvic.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F3xx/hal_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv1/stm32_dma.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_st_lld.c
-ifneq ($(findstring HAL_USE_ADC TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/ADCv3/hal_adc_lld.c
-endif
-ifneq ($(findstring HAL_USE_CAN TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1/hal_can_lld.c
-endif
-ifneq ($(findstring HAL_USE_DAC TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1/hal_dac_lld.c
-endif
ifneq ($(findstring HAL_USE_EXT TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1/hal_ext_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F3xx/hal_ext_lld_isr.c
-endif
-ifneq ($(findstring HAL_USE_PAL TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv2/hal_pal_lld.c
-endif
-ifneq ($(findstring HAL_USE_I2C TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/I2Cv2/hal_i2c_lld.c
-endif
-ifneq ($(findstring HAL_USE_RTC TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/RTCv2/hal_rtc_lld.c
-endif
-ifneq ($(findstring HAL_USE_SPI TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv2/hal_spi_lld.c
-endif
-ifneq ($(findstring HAL_USE_GPT TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_gpt_lld.c
-endif
-ifneq ($(findstring HAL_USE_ICU TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_icu_lld.c
-endif
-ifneq ($(findstring HAL_USE_PWM TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_pwm_lld.c
-endif
-ifneq ($(findstring HAL_USE_SERIAL TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv2/hal_serial_lld.c
-endif
-ifneq ($(findstring HAL_USE_UART TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv2/hal_uart_lld.c
-endif
-ifneq ($(findstring HAL_USE_USB TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/USBv1/hal_usb_lld.c
-endif
-ifneq ($(findstring HAL_USE_WDG TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/xWDGv1/hal_wdg_lld.c
+PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/STM32F3xx/hal_ext_lld_isr.c
endif
else
-PLATFORMSRC := $(CHIBIOS)/os/hal/ports/common/ARMCMx/nvic.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F3xx/hal_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F3xx/hal_ext_lld_isr.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/ADCv3/hal_adc_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1/hal_can_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1/hal_dac_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv1/stm32_dma.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1/hal_ext_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv2/hal_pal_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/I2Cv2/hal_i2c_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/RTCv2/hal_rtc_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv2/hal_spi_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_gpt_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_icu_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_pwm_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_st_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv2/hal_serial_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv2/hal_uart_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USBv1/hal_usb_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/xWDGv1/hal_wdg_lld.c
+PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/STM32F3xx/hal_ext_lld_isr.c
endif
-# Required include directories
-PLATFORMINC := $(CHIBIOS)/os/hal/ports/common/ARMCMx \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F3xx \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/ADCv3 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv2 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/I2Cv2 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/RTCv2 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv2 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv2 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USBv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/xWDGv1
+# Drivers compatible with the platform.
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/ADCv3/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv2/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/I2Cv2/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/RTCv2/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv2/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv2/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/USBv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/xWDGv1/driver.mk
diff --git a/os/hal/ports/STM32/STM32F4xx/platform.mk b/os/hal/ports/STM32/STM32F4xx/platform.mk
index ced19b83e..7bf1e8701 100644
--- a/os/hal/ports/STM32/STM32F4xx/platform.mk
+++ b/os/hal/ports/STM32/STM32F4xx/platform.mk
@@ -1,112 +1,37 @@
-# List of all the STM32F2xx/STM32F4xx platform files.
+# Required platform files.
+PLATFORMSRC := $(CHIBIOS)/os/hal/ports/common/ARMCMx/nvic.c \
+ $(CHIBIOS)/os/hal/ports/STM32/STM32F4xx/hal_lld.c
+
+# Required include directories.
+PLATFORMINC := $(CHIBIOS)/os/hal/ports/common/ARMCMx \
+ $(CHIBIOS)/os/hal/ports/STM32/STM32F4xx
+
+# Optional platform files.
ifeq ($(USE_SMART_BUILD),yes)
HALCONF := $(strip $(shell cat halconf.h | egrep -e "\#define"))
-PLATFORMSRC := $(CHIBIOS)/os/hal/ports/common/ARMCMx/nvic.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F4xx/hal_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv2/stm32_dma.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_st_lld.c
-ifneq ($(findstring HAL_USE_ADC TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/ADCv2/hal_adc_lld.c
-endif
-ifneq ($(findstring HAL_USE_CAN TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1/hal_can_lld.c
-endif
-ifneq ($(findstring HAL_USE_DAC TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1/hal_dac_lld.c
-endif
ifneq ($(findstring HAL_USE_EXT TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1/hal_ext_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F4xx/hal_ext_lld_isr.c
-endif
-ifneq ($(findstring HAL_USE_PAL TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv2/hal_pal_lld.c
-endif
-ifneq ($(findstring HAL_USE_I2C TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/I2Cv1/hal_i2c_lld.c
-endif
-ifneq ($(findstring HAL_USE_MAC TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/MACv1/hal_mac_lld.c
-endif
-ifneq ($(findstring HAL_USE_USB TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/OTGv1/hal_usb_lld.c
-endif
-ifneq ($(findstring HAL_USE_QSPI TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/QUADSPIv1/hal_qspi_lld.c
-endif
-ifneq ($(findstring HAL_USE_RTC TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/RTCv2/hal_rtc_lld.c
-endif
-ifneq ($(findstring HAL_USE_I2S TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv1/hal_i2s_lld.c
-endif
-ifneq ($(findstring HAL_USE_SDC TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/SDIOv1/hal_sdc_lld.c
-endif
-ifneq ($(findstring HAL_USE_SPI TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv1/hal_spi_lld.c
-endif
-ifneq ($(findstring HAL_USE_GPT TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_gpt_lld.c
-endif
-ifneq ($(findstring HAL_USE_ICU TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_icu_lld.c
-endif
-ifneq ($(findstring HAL_USE_PWM TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_pwm_lld.c
-endif
-ifneq ($(findstring HAL_USE_SERIAL TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv1/hal_serial_lld.c
-endif
-ifneq ($(findstring HAL_USE_UART TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv1/hal_uart_lld.c
-endif
-ifneq ($(findstring HAL_USE_WDG TRUE,$(HALCONF)),)
-PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/LLD/xWDGv1/hal_wdg_lld.c
+PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/STM32F4xx/hal_ext_lld_isr.c
endif
else
-PLATFORMSRC := $(CHIBIOS)/os/hal/ports/common/ARMCMx/nvic.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F4xx/hal_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F4xx/hal_ext_lld_isr.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/ADCv2/hal_adc_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1/hal_can_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1/hal_ext_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1/hal_dac_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv2/stm32_dma.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv2/hal_pal_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/I2Cv1/hal_i2c_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/MACv1/hal_mac_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/OTGv1/hal_usb_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/QUADSPIv1/hal_qspi_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/RTCv2/hal_rtc_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/SDIOv1/hal_sdc_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv1/hal_i2s_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv1/hal_spi_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_gpt_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_icu_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_pwm_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/hal_st_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv1/hal_serial_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv1/hal_uart_lld.c \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/xWDGv1/hal_wdg_lld.c
+PLATFORMSRC += $(CHIBIOS)/os/hal/ports/STM32/STM32F4xx/hal_ext_lld_isr.c
endif
-# Required include directories
-PLATFORMINC := $(CHIBIOS)/os/hal/ports/common/ARMCMx \
- $(CHIBIOS)/os/hal/ports/STM32/STM32F4xx \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/ADCv2 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv2 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv2 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/I2Cv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/MACv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/OTGv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/QUADSPIv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/RTCv2 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/SDIOv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv1 \
- $(CHIBIOS)/os/hal/ports/STM32/LLD/xWDGv1
+# Drivers compatible with the platform.
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/ADCv2/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv2/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv2/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/I2Cv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/MACv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/OTGv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/QUADSPIv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/RTCv2/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/SPIv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/SDIOv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/xWDGv1/driver.mk
+ \ No newline at end of file
diff --git a/os/hal/ports/STM32/STM32F7xx/platform.mk b/os/hal/ports/STM32/STM32F7xx/platform.mk
index 93777223c..5c6d14a23 100644
--- a/os/hal/ports/STM32/STM32F7xx/platform.mk
+++ b/os/hal/ports/STM32/STM32F7xx/platform.mk
@@ -20,6 +20,7 @@ endif
# Drivers compatible with the platform.
include $(CHIBIOS)/os/hal/ports/STM32/LLD/ADCv2/driver.mk
include $(CHIBIOS)/os/hal/ports/STM32/LLD/CANv1/driver.mk
+include $(CHIBIOS)/os/hal/ports/STM32/LLD/DACv1/driver.mk
include $(CHIBIOS)/os/hal/ports/STM32/LLD/DMAv2/driver.mk
include $(CHIBIOS)/os/hal/ports/STM32/LLD/EXTIv1/driver.mk
include $(CHIBIOS)/os/hal/ports/STM32/LLD/GPIOv2/driver.mk