From 7d0efb452a7b0da2ce81a5c13ed444e0507aa33e Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Fri, 13 Aug 2021 18:49:27 -0500 Subject: [PATCH] =?UTF-8?q?=F0=9F=8E=A8=20Update=20HAL/STM32=20wrappers?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Followup to #22537 --- Marlin/src/HAL/STM32/MarlinSPI.cpp | 2 ++ Marlin/src/HAL/STM32/eeprom_bl24cxx.cpp | 6 ++++-- Marlin/src/HAL/STM32/eeprom_if_iic.cpp | 7 ++++--- 3 files changed, 10 insertions(+), 5 deletions(-) diff --git a/Marlin/src/HAL/STM32/MarlinSPI.cpp b/Marlin/src/HAL/STM32/MarlinSPI.cpp index 330c895697..e1be50820f 100644 --- a/Marlin/src/HAL/STM32/MarlinSPI.cpp +++ b/Marlin/src/HAL/STM32/MarlinSPI.cpp @@ -19,6 +19,8 @@ * along with this program. If not, see . * */ +#include "../platforms.h" + #if defined(HAL_STM32) && !defined(STM32H7xx) #include "MarlinSPI.h" diff --git a/Marlin/src/HAL/STM32/eeprom_bl24cxx.cpp b/Marlin/src/HAL/STM32/eeprom_bl24cxx.cpp index 165b3c6bab..5bd4c18577 100644 --- a/Marlin/src/HAL/STM32/eeprom_bl24cxx.cpp +++ b/Marlin/src/HAL/STM32/eeprom_bl24cxx.cpp @@ -19,7 +19,9 @@ * along with this program. If not, see . * */ -#ifdef STM32F1 +#include "../platforms.h" + +#ifdef HAL_STM32 /** * PersistentStore for Arduino-style EEPROM interface @@ -79,4 +81,4 @@ bool PersistentStore::read_data(int &pos, uint8_t *value, size_t size, uint16_t } #endif // IIC_BL24CXX_EEPROM -#endif // STM32F1 +#endif // HAL_STM32 diff --git a/Marlin/src/HAL/STM32/eeprom_if_iic.cpp b/Marlin/src/HAL/STM32/eeprom_if_iic.cpp index 5c6cc802a6..26b3d9044e 100644 --- a/Marlin/src/HAL/STM32/eeprom_if_iic.cpp +++ b/Marlin/src/HAL/STM32/eeprom_if_iic.cpp @@ -19,14 +19,15 @@ * along with this program. If not, see . * */ +#include "../platforms.h" + +#ifdef HAL_STM32 /** * Platform-independent Arduino functions for I2C EEPROM. * Enable USE_SHARED_EEPROM if not supplied by the framework. */ -#ifdef STM32F1 - #include "../../inc/MarlinConfig.h" #if ENABLED(IIC_BL24CXX_EEPROM) @@ -51,4 +52,4 @@ uint8_t eeprom_read_byte(uint8_t *pos) { } #endif // IIC_BL24CXX_EEPROM -#endif // STM32F1 +#endif // HAL_STM32