From 6f6c1a6558bff0b5f0cb382187cc7e313f4706a3 Mon Sep 17 00:00:00 2001 From: "Frederic.Pillon" Date: Wed, 17 Jan 2018 14:40:31 +0100 Subject: [PATCH] Provides access to Low Layer (LL) API Includes all Low Layer header files. Note: use #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wunused-parameter" #pragma GCC diagnostic ignored "-Wstrict-aliasing" #pragma GCC diagnostic pop to avoid several warnings due to LL. Signed-off-by: Frederic Pillon --- cores/arduino/stm32/HAL/stm32yyxx_ll.h | 236 +++++++++++++++++++++++++ cores/arduino/stm32/stm32_def.h | 8 + 2 files changed, 244 insertions(+) create mode 100644 cores/arduino/stm32/HAL/stm32yyxx_ll.h diff --git a/cores/arduino/stm32/HAL/stm32yyxx_ll.h b/cores/arduino/stm32/HAL/stm32yyxx_ll.h new file mode 100644 index 0000000000..df8d2cb020 --- /dev/null +++ b/cores/arduino/stm32/HAL/stm32yyxx_ll.h @@ -0,0 +1,236 @@ +#ifdef STM32F0xx +#include "stm32f0xx_ll_adc.h" +#include "stm32f0xx_ll_bus.h" +#include "stm32f0xx_ll_comp.h" +#include "stm32f0xx_ll_cortex.h" +#include "stm32f0xx_ll_crc.h" +#include "stm32f0xx_ll_crs.h" +#include "stm32f0xx_ll_dac.h" +#include "stm32f0xx_ll_dma.h" +#include "stm32f0xx_ll_exti.h" +#include "stm32f0xx_ll_gpio.h" +#include "stm32f0xx_ll_i2c.h" +#include "stm32f0xx_ll_iwdg.h" +#include "stm32f0xx_ll_pwr.h" +#include "stm32f0xx_ll_rcc.h" +#include "stm32f0xx_ll_rtc.h" +#include "stm32f0xx_ll_spi.h" +#include "stm32f0xx_ll_system.h" +#include "stm32f0xx_ll_tim.h" +#include "stm32f0xx_ll_usart.h" +#include "stm32f0xx_ll_utils.h" +#include "stm32f0xx_ll_wwdg.h" +#endif +#ifdef STM32F1xx +#include "stm32f1xx_ll_adc.h" +#include "stm32f1xx_ll_bus.h" +#include "stm32f1xx_ll_cortex.h" +#include "stm32f1xx_ll_crc.h" +#include "stm32f1xx_ll_dac.h" +#include "stm32f1xx_ll_dma.h" +#include "stm32f1xx_ll_exti.h" +#include "stm32f1xx_ll_fsmc.h" +#include "stm32f1xx_ll_gpio.h" +#include "stm32f1xx_ll_i2c.h" +#include "stm32f1xx_ll_iwdg.h" +#include "stm32f1xx_ll_pwr.h" +#include "stm32f1xx_ll_rcc.h" +#include "stm32f1xx_ll_rtc.h" +#include "stm32f1xx_ll_sdmmc.h" +#include "stm32f1xx_ll_spi.h" +#include "stm32f1xx_ll_system.h" +#include "stm32f1xx_ll_tim.h" +#include "stm32f1xx_ll_usart.h" +#include "stm32f1xx_ll_usb.h" +#include "stm32f1xx_ll_utils.h" +#include "stm32f1xx_ll_wwdg.h" +#endif +#ifdef STM32F2xx +#include "stm32f2xx_ll_adc.h" +#include "stm32f2xx_ll_bus.h" +#include "stm32f2xx_ll_cortex.h" +#include "stm32f2xx_ll_crc.h" +#include "stm32f2xx_ll_dac.h" +#include "stm32f2xx_ll_dma.h" +#include "stm32f2xx_ll_exti.h" +#include "stm32f2xx_ll_fsmc.h" +#include "stm32f2xx_ll_gpio.h" +#include "stm32f2xx_ll_i2c.h" +#include "stm32f2xx_ll_iwdg.h" +#include "stm32f2xx_ll_pwr.h" +#include "stm32f2xx_ll_rcc.h" +#include "stm32f2xx_ll_rng.h" +#include "stm32f2xx_ll_rtc.h" +#include "stm32f2xx_ll_sdmmc.h" +#include "stm32f2xx_ll_spi.h" +#include "stm32f2xx_ll_system.h" +#include "stm32f2xx_ll_tim.h" +#include "stm32f2xx_ll_usart.h" +#include "stm32f2xx_ll_usb.h" +#include "stm32f2xx_ll_utils.h" +#include "stm32f2xx_ll_wwdg.h" +#endif +#ifdef STM32F3xx +#include "stm32f3xx_ll_adc.h" +#include "stm32f3xx_ll_bus.h" +#include "stm32f3xx_ll_comp.h" +#include "stm32f3xx_ll_cortex.h" +#include "stm32f3xx_ll_crc.h" +#include "stm32f3xx_ll_dac.h" +#include "stm32f3xx_ll_dma.h" +#include "stm32f3xx_ll_exti.h" +#include "stm32f3xx_ll_fmc.h" +#include "stm32f3xx_ll_gpio.h" +#include "stm32f3xx_ll_hrtim.h" +#include "stm32f3xx_ll_i2c.h" +#include "stm32f3xx_ll_iwdg.h" +#include "stm32f3xx_ll_opamp.h" +#include "stm32f3xx_ll_pwr.h" +#include "stm32f3xx_ll_rcc.h" +#include "stm32f3xx_ll_rtc.h" +#include "stm32f3xx_ll_spi.h" +#include "stm32f3xx_ll_system.h" +#include "stm32f3xx_ll_tim.h" +#include "stm32f3xx_ll_usart.h" +#include "stm32f3xx_ll_utils.h" +#include "stm32f3xx_ll_wwdg.h" +#endif +#ifdef STM32F4xx +#include "stm32f4xx_ll_adc.h" +#include "stm32f4xx_ll_bus.h" +#include "stm32f4xx_ll_cortex.h" +#include "stm32f4xx_ll_crc.h" +#include "stm32f4xx_ll_dac.h" +#include "stm32f4xx_ll_dma.h" +#include "stm32f4xx_ll_dma2d.h" +#include "stm32f4xx_ll_exti.h" +#include "stm32f4xx_ll_fmc.h" +#include "stm32f4xx_ll_fsmc.h" +#include "stm32f4xx_ll_gpio.h" +#include "stm32f4xx_ll_i2c.h" +#include "stm32f4xx_ll_iwdg.h" +#include "stm32f4xx_ll_lptim.h" +#include "stm32f4xx_ll_pwr.h" +#include "stm32f4xx_ll_rcc.h" +#include "stm32f4xx_ll_rng.h" +#include "stm32f4xx_ll_rtc.h" +#include "stm32f4xx_ll_sdmmc.h" +#include "stm32f4xx_ll_spi.h" +#include "stm32f4xx_ll_system.h" +#include "stm32f4xx_ll_tim.h" +#include "stm32f4xx_ll_usart.h" +#include "stm32f4xx_ll_usb.h" +#include "stm32f4xx_ll_utils.h" +#include "stm32f4xx_ll_wwdg.h" +#endif +#ifdef STM32F7xx +#include "stm32f7xx_ll_adc.h" +#include "stm32f7xx_ll_bus.h" +#include "stm32f7xx_ll_cortex.h" +#include "stm32f7xx_ll_crc.h" +#include "stm32f7xx_ll_dac.h" +#include "stm32f7xx_ll_dma.h" +#include "stm32f7xx_ll_dma2d.h" +#include "stm32f7xx_ll_exti.h" +#include "stm32f7xx_ll_fmc.h" +#include "stm32f7xx_ll_gpio.h" +#include "stm32f7xx_ll_i2c.h" +#include "stm32f7xx_ll_iwdg.h" +#include "stm32f7xx_ll_lptim.h" +#include "stm32f7xx_ll_pwr.h" +#include "stm32f7xx_ll_rcc.h" +#include "stm32f7xx_ll_rng.h" +#include "stm32f7xx_ll_rtc.h" +#include "stm32f7xx_ll_sdmmc.h" +#include "stm32f7xx_ll_spi.h" +#include "stm32f7xx_ll_system.h" +#include "stm32f7xx_ll_tim.h" +#include "stm32f7xx_ll_usart.h" +#include "stm32f7xx_ll_usb.h" +#include "stm32f7xx_ll_utils.h" +#include "stm32f7xx_ll_wwdg.h" +#endif +#ifdef STM32L0xx +#include "stm32l0xx_ll_adc.h" +#include "stm32l0xx_ll_bus.h" +#include "stm32l0xx_ll_comp.h" +#include "stm32l0xx_ll_cortex.h" +#include "stm32l0xx_ll_crc.h" +#include "stm32l0xx_ll_crs.h" +#include "stm32l0xx_ll_dac.h" +#include "stm32l0xx_ll_dma.h" +#include "stm32l0xx_ll_exti.h" +#include "stm32l0xx_ll_gpio.h" +#include "stm32l0xx_ll_i2c.h" +#include "stm32l0xx_ll_iwdg.h" +#include "stm32l0xx_ll_lptim.h" +#include "stm32l0xx_ll_lpuart.h" +#include "stm32l0xx_ll_pwr.h" +#include "stm32l0xx_ll_rcc.h" +#include "stm32l0xx_ll_rng.h" +#include "stm32l0xx_ll_rtc.h" +#include "stm32l0xx_ll_spi.h" +#include "stm32l0xx_ll_system.h" +#include "stm32l0xx_ll_tim.h" +#include "stm32l0xx_ll_usart.h" +#include "stm32l0xx_ll_utils.h" +#include "stm32l0xx_ll_wwdg.h" +#endif +#ifdef STM32L1xx +#include "stm32l1xx_ll_adc.h" +#include "stm32l1xx_ll_bus.h" +#include "stm32l1xx_ll_comp.h" +#include "stm32l1xx_ll_cortex.h" +#include "stm32l1xx_ll_crc.h" +#include "stm32l1xx_ll_dac.h" +#include "stm32l1xx_ll_dma.h" +#include "stm32l1xx_ll_exti.h" +#include "stm32l1xx_ll_fsmc.h" +#include "stm32l1xx_ll_gpio.h" +#include "stm32l1xx_ll_i2c.h" +#include "stm32l1xx_ll_iwdg.h" +#include "stm32l1xx_ll_opamp.h" +#include "stm32l1xx_ll_pwr.h" +#include "stm32l1xx_ll_rcc.h" +#include "stm32l1xx_ll_rtc.h" +#include "stm32l1xx_ll_sdmmc.h" +#include "stm32l1xx_ll_spi.h" +#include "stm32l1xx_ll_system.h" +#include "stm32l1xx_ll_tim.h" +#include "stm32l1xx_ll_usart.h" +#include "stm32l1xx_ll_utils.h" +#include "stm32l1xx_ll_wwdg.h" +#endif +#ifdef STM32L4xx +#include "stm32l4xx_ll_adc.h" +#include "stm32l4xx_ll_bus.h" +#include "stm32l4xx_ll_comp.h" +#include "stm32l4xx_ll_cortex.h" +#include "stm32l4xx_ll_crc.h" +#include "stm32l4xx_ll_crs.h" +#include "stm32l4xx_ll_dac.h" +#include "stm32l4xx_ll_dma.h" +#include "stm32l4xx_ll_dma2d.h" +#include "stm32l4xx_ll_dmamux.h" +#include "stm32l4xx_ll_exti.h" +#include "stm32l4xx_ll_fmc.h" +#include "stm32l4xx_ll_gpio.h" +#include "stm32l4xx_ll_i2c.h" +#include "stm32l4xx_ll_iwdg.h" +#include "stm32l4xx_ll_lptim.h" +#include "stm32l4xx_ll_lpuart.h" +#include "stm32l4xx_ll_opamp.h" +#include "stm32l4xx_ll_pwr.h" +#include "stm32l4xx_ll_rcc.h" +#include "stm32l4xx_ll_rng.h" +#include "stm32l4xx_ll_rtc.h" +#include "stm32l4xx_ll_sdmmc.h" +#include "stm32l4xx_ll_spi.h" +#include "stm32l4xx_ll_swpmi.h" +#include "stm32l4xx_ll_system.h" +#include "stm32l4xx_ll_tim.h" +#include "stm32l4xx_ll_usart.h" +#include "stm32l4xx_ll_usb.h" +#include "stm32l4xx_ll_utils.h" +#include "stm32l4xx_ll_wwdg.h" +#endif diff --git a/cores/arduino/stm32/stm32_def.h b/cores/arduino/stm32/stm32_def.h index b75432ed94..ad0247a727 100644 --- a/cores/arduino/stm32/stm32_def.h +++ b/cores/arduino/stm32/stm32_def.h @@ -50,6 +50,14 @@ #error "STM32YYxx chip series is not defined in boards.txt." #endif +// Include Low Layers drivers +// LL raised several warnings, ignore them +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wunused-parameter" +#pragma GCC diagnostic ignored "-Wstrict-aliasing" +#include "HAL/stm32yyxx_ll.h" +#pragma GCC diagnostic pop + // Here define some compatibility #ifndef CAN1 #define CAN1 CAN