Skip to content

Commit b55aeae

Browse files
authored
exclude swser in all code
1 parent b6aba6c commit b55aeae

File tree

4 files changed

+14
-0
lines changed

4 files changed

+14
-0
lines changed

src/VS1/VS1.cpp

+3
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ VS1::VS1(HardwareSerial* interface)
3737
}
3838
}
3939

40+
#if defined(ARDUINO_ARCH_ESP8266)
4041
VS1::VS1(SoftwareSerial* interface)
4142
: _state(State::UNDEFINED)
4243
, _currentMillis(vw_millis())
@@ -62,6 +63,8 @@ VS1::VS1(SoftwareSerial* interface)
6263
vw_abort();
6364
}
6465
}
66+
#endif
67+
6568
#else
6669
VS1::VS1(const char* interface)
6770
: _state(State::UNDEFINED)

src/VS1/VS1.h

+4
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,9 @@ the LICENSE file.
1717
#include "../Datapoint/Datapoint.h"
1818
#if defined(ARDUINO_ARCH_ESP8266) || defined(ARDUINO_ARCH_ESP32)
1919
#include "../Interface/HardwareSerialInterface.h"
20+
#if defined(ARDUINO_ARCH_ESP8266)
2021
#include "../Interface/SoftwareSerialInterface.h"
22+
#endif
2123
#elif defined(__linux__)
2224
#include "../Interface/LinuxSerialInterface.h"
2325
#else
@@ -33,7 +35,9 @@ class VS1 {
3335

3436
#if defined(ARDUINO_ARCH_ESP8266) || defined(ARDUINO_ARCH_ESP32)
3537
explicit VS1(HardwareSerial* interface);
38+
#if defined(ARDUINO_ARCH_ESP8266)
3639
explicit VS1(SoftwareSerial* interface);
40+
#endif
3741
#else
3842
explicit VS1(const char* interface);
3943
#endif

src/VS2/VS2.cpp

+3
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ VS2::VS2(HardwareSerial* interface)
3131
}
3232
}
3333

34+
#if defined(ARDUINO_ARCH_ESP8266)
3435
VS2::VS2(SoftwareSerial* interface)
3536
: _state(State::UNDEFINED)
3637
, _currentMillis(vw_millis())
@@ -50,6 +51,8 @@ VS2::VS2(SoftwareSerial* interface)
5051
vw_abort();
5152
}
5253
}
54+
#endif
55+
5356
#else
5457
VS2::VS2(const char* interface)
5558
: _state(State::UNDEFINED)

src/VS2/VS2.h

+4
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,9 @@ the LICENSE file.
1717
#include "../Datapoint/Datapoint.h"
1818
#if defined(ARDUINO_ARCH_ESP8266) || defined(ARDUINO_ARCH_ESP32)
1919
#include "../Interface/HardwareSerialInterface.h"
20+
#if defined(ARDUINO_ARCH_ESP8266)
2021
#include "../Interface/SoftwareSerialInterface.h"
22+
#endif
2123
#elif defined(__linux__)
2224
#include "../Interface/LinuxSerialInterface.h"
2325
#else
@@ -33,7 +35,9 @@ class VS2 {
3335

3436
#if defined(ARDUINO_ARCH_ESP8266) || defined(ARDUINO_ARCH_ESP32)
3537
explicit VS2(HardwareSerial* interface);
38+
#if defined(ARDUINO_ARCH_ESP8266)
3639
explicit VS2(SoftwareSerial* interface);
40+
#endif
3741
#else
3842
explicit VS2(const char* interface);
3943
#endif

0 commit comments

Comments
 (0)