diff --git a/os/hal/ports/STM32/STM32WBxx/hal_lld.h b/os/hal/ports/STM32/STM32WBxx/hal_lld.h index 72323a14a..c83e3cb0c 100644 --- a/os/hal/ports/STM32/STM32WBxx/hal_lld.h +++ b/os/hal/ports/STM32/STM32WBxx/hal_lld.h @@ -45,6 +45,11 @@ /* Driver constants. */ /*===========================================================================*/ +/** + * @brief Requires use of SPIv2 driver model. + */ +#define HAL_LLD_SELECT_SPI_V2 TRUE + /** * @name Platform identification * @{ @@ -502,6 +507,13 @@ #define STM32_LSI1_ENABLED TRUE #endif +/** + * @brief Enables or disables the LSI2 clock source. + */ +#if !defined(STM32_LSI2_ENABLED) || defined(__DOXYGEN__) +#define STM32_LSI2_ENABLED FALSE +#endif + /** * @brief Enables or disables the HSE clock source. */ @@ -1127,7 +1139,9 @@ #if STM32_RNGSEL == STM32_RNGSEL_LSI #error "LSI1 or LSI2 not enabled, required by STM32_RNGSEL" #endif - +#else + /* Define required for IWDG.*/ + #define STM32_LSI_ENABLED TRUE #endif /* !(STM32_LSI1_ENABLED || STM32_LSI2_ENABLED) */ #if !STM32_LSI1_ENABLED diff --git a/os/hal/ports/STM32/STM32WBxx/platform.mk b/os/hal/ports/STM32/STM32WBxx/platform.mk index b397932b6..1a360510c 100644 --- a/os/hal/ports/STM32/STM32WBxx/platform.mk +++ b/os/hal/ports/STM32/STM32WBxx/platform.mk @@ -35,7 +35,7 @@ include $(CHIBIOS)/os/hal/ports/STM32/LLD/QUADSPIv1/driver.mk include $(CHIBIOS)/os/hal/ports/STM32/LLD/RCCv1/driver.mk include $(CHIBIOS)/os/hal/ports/STM32/LLD/RNGv1/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/SPIv2/driver_v2.mk include $(CHIBIOS)/os/hal/ports/STM32/LLD/SYSTICKv1/driver.mk include $(CHIBIOS)/os/hal/ports/STM32/LLD/TIMv1/driver.mk include $(CHIBIOS)/os/hal/ports/STM32/LLD/USARTv2/driver.mk