From bd321d4b7c1cb9a64956c953b64fed8586ac61fc Mon Sep 17 00:00:00 2001 From: Lino Barreca Date: Thu, 14 Nov 2019 12:21:23 +0100 Subject: [PATCH] Don't compile STM32 SoftwareSerial unless STM32 (#15894) --- Marlin/src/HAL/HAL_STM32/SoftwareSerial.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Marlin/src/HAL/HAL_STM32/SoftwareSerial.cpp b/Marlin/src/HAL/HAL_STM32/SoftwareSerial.cpp index 39fed33826..2d2883f4ce 100644 --- a/Marlin/src/HAL/HAL_STM32/SoftwareSerial.cpp +++ b/Marlin/src/HAL/HAL_STM32/SoftwareSerial.cpp @@ -34,6 +34,8 @@ // // Includes // +#if defined(ARDUINO_ARCH_STM32) && !defined(STM32GENERIC) + #include "SoftwareSerial.h" #include "timers.h" @@ -389,3 +391,5 @@ int SoftwareSerial::peek() { // Read from "head" return _receive_buffer[_receive_buffer_head]; } + +#endif // ARDUINO_ARCH_STM32 && !STM32GENERIC