Browse Source

Fix wrappers on HAL/STM32F1 .cpp files (#19581)

Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com>
ellensp 3 years ago
parent
commit
b3c2ee56f9
No account linked to committer's email address

+ 0
- 3
Marlin/src/HAL/STM32F1/HAL_SPI.cpp View File

@@ -24,9 +24,6 @@
24 24
 /**
25 25
  * Software SPI functions originally from Arduino Sd2Card Library
26 26
  * Copyright (c) 2009 by William Greiman
27
- */
28
-
29
-/**
30 27
  * Adapted to the STM32F1 HAL
31 28
  */
32 29
 

+ 3
- 0
Marlin/src/HAL/STM32F1/eeprom_bl24cxx.cpp View File

@@ -25,6 +25,8 @@
25 25
  * with simple implementations supplied by Marlin.
26 26
  */
27 27
 
28
+#ifdef __STM32F1__
29
+
28 30
 #include "../../inc/MarlinConfig.h"
29 31
 
30 32
 #if ENABLED(IIC_BL24CXX_EEPROM)
@@ -79,3 +81,4 @@ bool PersistentStore::read_data(int &pos, uint8_t* value, size_t size, uint16_t
79 81
 }
80 82
 
81 83
 #endif // IIC_BL24CXX_EEPROM
84
+#endif // __STM32F1__

+ 3
- 0
Marlin/src/HAL/STM32F1/eeprom_if_iic.cpp View File

@@ -25,6 +25,8 @@
25 25
  * Enable USE_SHARED_EEPROM if not supplied by the framework.
26 26
  */
27 27
 
28
+#ifdef __STM32F1__
29
+
28 30
 #include "../../inc/MarlinConfig.h"
29 31
 
30 32
 #if ENABLED(IIC_BL24CXX_EEPROM)
@@ -49,3 +51,4 @@ uint8_t eeprom_read_byte(uint8_t *pos) {
49 51
 }
50 52
 
51 53
 #endif // IIC_BL24CXX_EEPROM
54
+#endif // __STM32F1__

+ 5
- 5
Marlin/src/HAL/STM32F1/eeprom_wired.cpp View File

@@ -17,17 +17,17 @@
17 17
  * along with this program.  If not, see <https://www.gnu.org/licenses/>.
18 18
  *
19 19
  */
20
+
21
+/**
22
+ * HAL PersistentStore for STM32F1
23
+ */
24
+
20 25
 #ifdef __STM32F1__
21 26
 
22 27
 #include "../../inc/MarlinConfig.h"
23 28
 
24 29
 #if USE_WIRED_EEPROM
25 30
 
26
-/**
27
- * PersistentStore for Arduino-style EEPROM interface
28
- * with simple implementations supplied by Marlin.
29
- */
30
-
31 31
 #include "../shared/eeprom_if.h"
32 32
 #include "../shared/eeprom_api.h"
33 33
 

+ 2
- 2
Marlin/src/HAL/STM32F1/msc_sd.cpp View File

@@ -13,7 +13,7 @@
13 13
  * along with this program.  If not, see <https://www.gnu.org/licenses/>.
14 14
  *
15 15
  */
16
-#ifdef USE_USB_COMPOSITE
16
+#if defined(__STM32F1__) && defined(USE_USB_COMPOSITE)
17 17
 
18 18
 #include "msc_sd.h"
19 19
 #include "SPI.h"
@@ -77,4 +77,4 @@ void MSC_SD_init() {
77 77
   #endif
78 78
 }
79 79
 
80
-#endif // USE_USB_COMPOSITE
80
+#endif // __STM32F1__ && USE_USB_COMPOSITE

+ 3
- 0
Marlin/src/HAL/STM32F1/onboard_sd.cpp View File

@@ -11,6 +11,8 @@
11 11
  * Redistributions of source code must retain the above copyright notice.
12 12
  */
13 13
 
14
+#ifdef __STM32F1__
15
+
14 16
 #include "../../inc/MarlinConfig.h"
15 17
 
16 18
 #if SD_CONNECTION_IS(ONBOARD)
@@ -553,3 +555,4 @@ DRESULT disk_read (
553 555
 #endif // _DISKIO_IOCTL
554 556
 
555 557
 #endif // SD_CONNECTION_IS(ONBOARD)
558
+#endif // __STM32F1__

Loading…
Cancel
Save