cleanup serial instanciation on boards where we might not use it

1.2-legacy
geeksville 2020-04-24 08:05:56 -07:00
rodzic 5ad30caf67
commit 4f7e85c1a4
1 zmienionych plików z 4 dodań i 3 usunięć

Wyświetl plik

@ -46,9 +46,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
//#define USE_JTAG //#define USE_JTAG
#endif #endif
#define DEBUG_PORT Serial // Serial debug port
#define SERIAL_BAUD 921600 // Serial debug baud rate
#define REQUIRE_RADIO true // If true, we will fail to start if the radio is not found #define REQUIRE_RADIO true // If true, we will fail to start if the radio is not found
#define xstr(s) str(s) #define xstr(s) str(s)
@ -225,6 +222,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
// DEBUG // DEBUG
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
#define SERIAL_BAUD 921600 // Serial debug baud rate
#ifdef NO_ESP32 #ifdef NO_ESP32
#define USE_SEGGER #define USE_SEGGER
#endif #endif
@ -232,6 +231,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#include "SEGGER_RTT.h" #include "SEGGER_RTT.h"
#define DEBUG_MSG(...) SEGGER_RTT_printf(0, __VA_ARGS__) #define DEBUG_MSG(...) SEGGER_RTT_printf(0, __VA_ARGS__)
#else #else
#define DEBUG_PORT Serial // Serial debug port
#ifdef DEBUG_PORT #ifdef DEBUG_PORT
#define DEBUG_MSG(...) DEBUG_PORT.printf(__VA_ARGS__) #define DEBUG_MSG(...) DEBUG_PORT.printf(__VA_ARGS__)
#else #else