platformio.ini 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140
  1. [rak4631]
  2. extends = nrf52_base
  3. platform = https://github.com/maxgerhardt/platform-nordicnrf52.git#rak
  4. board = wiscore_rak4631
  5. board_check = true
  6. build_flags = ${nrf52_base.build_flags}
  7. ${sensor_base.build_flags}
  8. -I variants/rak4631
  9. -D RAK_4631
  10. -D RAK_BOARD
  11. -D PIN_BOARD_SCL=14
  12. -D PIN_BOARD_SDA=13
  13. -D PIN_GPS_TX=16
  14. -D PIN_GPS_RX=15
  15. -D PIN_GPS_EN=-1
  16. -D PIN_OLED_RESET=-1
  17. -D RADIO_CLASS=CustomSX1262
  18. -D WRAPPER_CLASS=CustomSX1262Wrapper
  19. -D LORA_TX_POWER=22
  20. -D SX126X_CURRENT_LIMIT=140
  21. -D SX126X_RX_BOOSTED_GAIN=1
  22. build_src_filter = ${nrf52_base.build_src_filter}
  23. +<../variants/rak4631>
  24. +<helpers/sensors>
  25. +<helpers/ui/SSD1306Display.cpp>
  26. +<helpers/ui/MomentaryButton.cpp>
  27. lib_deps =
  28. ${nrf52_base.lib_deps}
  29. ${sensor_base.lib_deps}
  30. adafruit/Adafruit SSD1306 @ ^2.5.13
  31. sparkfun/SparkFun u-blox GNSS Arduino Library@^2.2.27
  32. [env:RAK_4631_Repeater]
  33. extends = rak4631
  34. build_flags =
  35. ${rak4631.build_flags}
  36. -D DISPLAY_CLASS=SSD1306Display
  37. -D ADVERT_NAME='"RAK4631 Repeater"'
  38. -D ADVERT_LAT=0.0
  39. -D ADVERT_LON=0.0
  40. -D ADMIN_PASSWORD='"password"'
  41. -D MAX_NEIGHBOURS=8
  42. ; -D MESH_PACKET_LOGGING=1
  43. ; -D MESH_DEBUG=1
  44. build_src_filter = ${rak4631.build_src_filter}
  45. +<helpers/ui/SSD1306Display.cpp>
  46. +<../examples/simple_repeater>
  47. [env:RAK_4631_room_server]
  48. extends = rak4631
  49. build_flags =
  50. ${rak4631.build_flags}
  51. -D DISPLAY_CLASS=SSD1306Display
  52. -D ADVERT_NAME='"Test Room"'
  53. -D ADVERT_LAT=0.0
  54. -D ADVERT_LON=0.0
  55. -D ADMIN_PASSWORD='"password"'
  56. -D ROOM_PASSWORD='"hello"'
  57. ; -D MESH_PACKET_LOGGING=1
  58. ; -D MESH_DEBUG=1
  59. build_src_filter = ${rak4631.build_src_filter}
  60. +<helpers/ui/SSD1306Display.cpp>
  61. +<../examples/simple_room_server>
  62. [env:RAK_4631_companion_radio_usb]
  63. extends = rak4631
  64. board_build.ldscript = boards/nrf52840_s140_v6_extrafs.ld
  65. board_upload.maximum_size = 712704
  66. build_flags =
  67. ${rak4631.build_flags}
  68. -I examples/companion_radio/ui-new
  69. -D PIN_USER_BTN=9
  70. -D PIN_USER_BTN_ANA=31
  71. -D DISPLAY_CLASS=SSD1306Display
  72. -D MAX_CONTACTS=350
  73. -D MAX_GROUP_CHANNELS=40
  74. ; NOTE: DO NOT ENABLE --> -D MESH_PACKET_LOGGING=1
  75. ; NOTE: DO NOT ENABLE --> -D MESH_DEBUG=1
  76. build_src_filter = ${rak4631.build_src_filter}
  77. +<../examples/companion_radio/*.cpp>
  78. +<../examples/companion_radio/ui-new/*.cpp>
  79. lib_deps =
  80. ${rak4631.lib_deps}
  81. densaugeo/base64 @ ~1.4.0
  82. [env:RAK_4631_companion_radio_ble]
  83. extends = rak4631
  84. board_build.ldscript = boards/nrf52840_s140_v6_extrafs.ld
  85. board_upload.maximum_size = 712704
  86. build_flags =
  87. ${rak4631.build_flags}
  88. -I examples/companion_radio/ui-new
  89. -D PIN_USER_BTN=9
  90. -D PIN_USER_BTN_ANA=31
  91. -D DISPLAY_CLASS=SSD1306Display
  92. -D MAX_CONTACTS=350
  93. -D MAX_GROUP_CHANNELS=40
  94. -D BLE_PIN_CODE=123456
  95. -D BLE_DEBUG_LOGGING=1
  96. -D OFFLINE_QUEUE_SIZE=256
  97. ; -D MESH_PACKET_LOGGING=1
  98. ; -D MESH_DEBUG=1
  99. build_src_filter = ${rak4631.build_src_filter}
  100. +<helpers/nrf52/SerialBLEInterface.cpp>
  101. +<../examples/companion_radio/*.cpp>
  102. +<../examples/companion_radio/ui-new/*.cpp>
  103. lib_deps =
  104. ${rak4631.lib_deps}
  105. densaugeo/base64 @ ~1.4.0
  106. [env:RAK_4631_terminal_chat]
  107. extends = rak4631
  108. build_flags =
  109. ${rak4631.build_flags}
  110. -D PIN_USER_BTN=9
  111. -D PIN_USER_BTN_ANA=31
  112. -D MAX_CONTACTS=100
  113. -D MAX_GROUP_CHANNELS=1
  114. ; -D MESH_PACKET_LOGGING=1
  115. ; -D MESH_DEBUG=1
  116. build_src_filter = ${rak4631.build_src_filter}
  117. +<../examples/simple_secure_chat/main.cpp>
  118. lib_deps =
  119. ${rak4631.lib_deps}
  120. densaugeo/base64 @ ~1.4.0
  121. [env:RAK_4631_sensor]
  122. extends = rak4631
  123. build_flags =
  124. ${rak4631.build_flags}
  125. -D DISPLAY_CLASS=SSD1306Display
  126. -D ADVERT_NAME='"RAK4631 Sensor"'
  127. -D ADVERT_LAT=0.0
  128. -D ADVERT_LON=0.0
  129. -D ADMIN_PASSWORD='"password"'
  130. ; -D MESH_PACKET_LOGGING=1
  131. -D MESH_DEBUG=1
  132. build_src_filter = ${rak4631.build_src_filter}
  133. +<helpers/ui/SSD1306Display.cpp>
  134. +<../examples/simple_sensor>