diff --git a/platformio.ini b/platformio.ini
index 95db806e9..9e8abddd1 100644
--- a/platformio.ini
+++ b/platformio.ini
@@ -9,7 +9,7 @@
; https://docs.platformio.org/page/projectconf.html
[platformio]
-default_envs = linux # nrf52840dk-geeksville # linux # or if you'd like to change the default to something like lora-relay-v1 put that here
+default_envs = tbeam # lora-relay-v1 # nrf52840dk-geeksville # linux # or if you'd like to change the default to something like lora-relay-v1 put that here
[common]
; common is not currently used
@@ -74,12 +74,14 @@ lib_deps =
build_flags = ${env.build_flags} -Os
+src_filter = ${env.src_filter} -
+
; Common settings for ESP targes, mixin with extends = esp32_base
[esp32_base]
extends = arduino_base
platform = espressif32
src_filter =
- ${env.src_filter} -
+ ${arduino_base.src_filter} -
upload_speed = 921600
debug_init_break = tbreak setup
build_flags =
@@ -153,7 +155,7 @@ board = cubecell_board_plus
; FIXME, bug in cubecell arduino - they are supposed to set ARDUINO
build_flags = ${arduino_base.build_flags} -DARDUINO=100 -Isrc/cubecell
src_filter =
- ${env.src_filter} - -
+ ${arduino_base.src_filter} - -
; Common settings for NRF52 based targets
[nrf52_base]
@@ -170,7 +172,7 @@ build_flags =
-Isdk-nrfxlib/crypto/nrf_oberon/include -Lsdk-nrfxlib/crypto/nrf_oberon/lib/cortex-m4/hard-float/ -lliboberon_3.0.3
;-DCFG_DEBUG=3
src_filter =
- ${env.src_filter} - -
+ ${arduino_base.src_filter} - -
lib_ignore =
BluetoothOTA
monitor_port = /dev/ttyACM1
@@ -248,6 +250,7 @@ lib_deps =
TFT_eSPI
# Adafruit ST7735 and ST7789 Library
+; The Portduino based sim environment on top of linux
[env:linux]
platform = https://github.com/geeksville/platform-portduino.git
src_filter = ${env.src_filter} - - -
diff --git a/src/concurrency/PosixNotifiedWorkerThread.cpp b/src/concurrency/PosixNotifiedWorkerThread.cpp
index ac24cf86a..e759a871e 100644
--- a/src/concurrency/PosixNotifiedWorkerThread.cpp
+++ b/src/concurrency/PosixNotifiedWorkerThread.cpp
@@ -1,4 +1,7 @@
#include "PosixNotifiedWorkerThread.h"
+
+#ifdef __unix__
+
#include
using namespace concurrency;
@@ -11,4 +14,6 @@ void PosixNotifiedWorkerThread::notify(uint32_t v, eNotifyAction action) NOT_IMP
/**
* A method that should block execution - either waiting ona queue/mutex or a "task notification"
*/
-void PosixNotifiedWorkerThread::block() NOT_IMPLEMENTED("block");
\ No newline at end of file
+void PosixNotifiedWorkerThread::block() NOT_IMPLEMENTED("block");
+
+#endif
\ No newline at end of file
diff --git a/src/mesh/mesh-pb-constants.cpp b/src/mesh/mesh-pb-constants.cpp
index cc6beb73a..337e585de 100644
--- a/src/mesh/mesh-pb-constants.cpp
+++ b/src/mesh/mesh-pb-constants.cpp
@@ -6,10 +6,10 @@
#include
#include
-#if 0 // FIXME NRF52 only
+#ifdef ARDUINO_ARCH_NRF52
#include "Adafruit_LittleFS.h"
using namespace Adafruit_LittleFS_Namespace; // To get File type
-#endif
+#endif
/// helper function for encoding a record as a protobuf, any failures to encode are fatal and we will panic
/// returns the encoded packet size
@@ -49,7 +49,7 @@ bool readcb(pb_istream_t *stream, uint8_t *buf, size_t count)
return count == 0;
}
- status = (file->read(buf, count) == (int) count);
+ status = (file->read(buf, count) == (int)count);
if (file->available() == 0)
stream->bytes_left = 0;