From fa2920340cc6df6c4a326d1a7c326f04c8137d6c Mon Sep 17 00:00:00 2001 From: Verkehrsrot Date: Thu, 6 Feb 2020 16:53:50 +0100 Subject: [PATCH] SDS011read.cpp: bugfix conditional compile --- src/sds011read.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/sds011read.cpp b/src/sds011read.cpp index 0b66c747..71be06d9 100644 --- a/src/sds011read.cpp +++ b/src/sds011read.cpp @@ -3,15 +3,19 @@ // Local logging tag static const char TAG[] = __FILE__; +#if (HAS_SDS) + #include "sds011read.h" // UART(2) is unused in this project #if (HAS_IF482) #error cannot use IF482 together with SDS011 (both use UART#2) #endif + #ifndef SDS011_SERIAL #error serial settings for SDS011 connection missing #endif + static HardwareSerial sdsSerial(2); // so we use it here static SDS011 sdsSensor; // fine dust sensor @@ -58,3 +62,5 @@ void sds011_wakeup() { isSDS011Active = true; } } + +#endif // HAS_SDS \ No newline at end of file