Explorar o código

fix RAK build errors

recrof hai 11 meses
pai
achega
d145d5936d
Modificáronse 2 ficheiros con 6 adicións e 4 borrados
  1. 2 4
      variants/rak4631/platformio.ini
  2. 4 0
      variants/rak4631/target.cpp

+ 2 - 4
variants/rak4631/platformio.ini

@@ -22,6 +22,8 @@ build_flags = ${nrf52_base.build_flags}
 build_src_filter = ${nrf52_base.build_src_filter}
   +<../variants/rak4631>
   +<helpers/sensors>
+  +<helpers/ui/SSD1306Display.cpp>
+  +<helpers/ui/MomentaryButton.cpp>
 lib_deps =
   ${nrf52_base.lib_deps}
   ${sensor_base.lib_deps}
@@ -73,8 +75,6 @@ build_flags =
 ; NOTE: DO NOT ENABLE -->  -D MESH_PACKET_LOGGING=1
 ; NOTE: DO NOT ENABLE -->  -D MESH_DEBUG=1
 build_src_filter = ${rak4631.build_src_filter}
-  +<helpers/ui/SSD1306Display.cpp>
-  +<helpers/ui/MomentaryButton.cpp>
   +<../examples/companion_radio/*.cpp>
   +<../examples/companion_radio/ui-new/*.cpp>
 lib_deps =
@@ -97,9 +97,7 @@ build_flags =
 ;  -D MESH_PACKET_LOGGING=1
 ;  -D MESH_DEBUG=1
 build_src_filter = ${rak4631.build_src_filter}
-  +<helpers/ui/SSD1306Display.cpp>
   +<helpers/nrf52/SerialBLEInterface.cpp>
-  +<helpers/ui/MomentaryButton.cpp>
   +<../examples/companion_radio/*.cpp>
   +<../examples/companion_radio/ui-new/*.cpp>
 lib_deps =

+ 4 - 0
variants/rak4631/target.cpp

@@ -4,6 +4,10 @@
 
 RAK4631Board board;
 
+#ifndef PIN_USER_BTN
+  #define PIN_USER_BTN (-1)
+#endif
+
 #ifdef DISPLAY_CLASS
   DISPLAY_CLASS display;
   MomentaryButton user_btn(PIN_USER_BTN, 1000, true);