platformio.ini 7.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254
  1. ;
  2. ; Heltec T114 without display
  3. ;
  4. [Heltec_t114]
  5. extends = nrf52_base
  6. board = heltec_t114
  7. board_build.ldscript = boards/nrf52840_s140_v6.ld
  8. build_flags = ${nrf52_base.build_flags}
  9. ${sensor_base.build_flags}
  10. -I lib/nrf52/s140_nrf52_6.1.1_API/include
  11. -I lib/nrf52/s140_nrf52_6.1.1_API/include/nrf52
  12. -I variants/heltec_t114
  13. -I src/helpers/ui
  14. -D HELTEC_T114
  15. -D NRF52_POWER_MANAGEMENT
  16. -D P_LORA_DIO_1=20
  17. -D P_LORA_NSS=24
  18. -D P_LORA_RESET=25
  19. -D P_LORA_BUSY=17
  20. -D P_LORA_SCLK=19
  21. -D P_LORA_MISO=23
  22. -D P_LORA_MOSI=22
  23. -D P_LORA_TX_LED=35
  24. -D RADIO_CLASS=CustomSX1262
  25. -D WRAPPER_CLASS=CustomSX1262Wrapper
  26. -D LORA_TX_POWER=22
  27. -D SX126X_POWER_EN=37
  28. -D SX126X_DIO2_AS_RF_SWITCH=true
  29. -D SX126X_DIO3_TCXO_VOLTAGE=1.8
  30. -D SX126X_CURRENT_LIMIT=140
  31. -D SX126X_RX_BOOSTED_GAIN=1
  32. -D PIN_GPS_RX=39
  33. -D PIN_GPS_TX=37
  34. -D PIN_GPS_EN=21
  35. -D PIN_GPS_RESET=38
  36. -D PIN_GPS_RESET_ACTIVE=LOW
  37. -D ENV_PIN_SDA=PIN_WIRE1_SDA
  38. -D ENV_PIN_SCL=PIN_WIRE1_SCL
  39. build_src_filter = ${nrf52_base.build_src_filter}
  40. +<helpers/*.cpp>
  41. +<helpers/sensors>
  42. +<../variants/heltec_t114>
  43. lib_deps =
  44. ${nrf52_base.lib_deps}
  45. ${sensor_base.lib_deps}
  46. debug_tool = jlink
  47. upload_protocol = nrfutil
  48. [env:Heltec_t114_without_display_repeater]
  49. extends = Heltec_t114
  50. build_src_filter = ${Heltec_t114.build_src_filter}
  51. +<../examples/simple_repeater>
  52. build_flags =
  53. ${Heltec_t114.build_flags}
  54. -D ADVERT_NAME='"Heltec_T114 Repeater"'
  55. -D ADVERT_LAT=0.0
  56. -D ADVERT_LON=0.0
  57. -D ADMIN_PASSWORD='"password"'
  58. -D MAX_NEIGHBOURS=50
  59. ; -D MESH_PACKET_LOGGING=1
  60. ; -D MESH_DEBUG=1
  61. [env:Heltec_t114_without_display_repeater_bridge_rs232]
  62. extends = Heltec_t114
  63. build_flags =
  64. ${Heltec_t114.build_flags}
  65. -D ADVERT_NAME='"RS232 Bridge"'
  66. -D ADVERT_LAT=0.0
  67. -D ADVERT_LON=0.0
  68. -D ADMIN_PASSWORD='"password"'
  69. -D MAX_NEIGHBOURS=50
  70. -D WITH_RS232_BRIDGE=Serial2
  71. -D WITH_RS232_BRIDGE_RX=9
  72. -D WITH_RS232_BRIDGE_TX=10
  73. ; -D BRIDGE_DEBUG=1
  74. ; -D MESH_PACKET_LOGGING=1
  75. ; -D MESH_DEBUG=1
  76. build_src_filter = ${Heltec_t114.build_src_filter}
  77. +<helpers/bridges/RS232Bridge.cpp>
  78. +<../examples/simple_repeater>
  79. [env:Heltec_t114_without_display_room_server]
  80. extends = Heltec_t114
  81. build_src_filter = ${Heltec_t114.build_src_filter}
  82. +<../examples/simple_room_server>
  83. build_flags =
  84. ${Heltec_t114.build_flags}
  85. -D ADVERT_NAME='"Heltec_T114 Room"'
  86. -D ADVERT_LAT=0.0
  87. -D ADVERT_LON=0.0
  88. -D ADMIN_PASSWORD='"password"'
  89. -D ROOM_PASSWORD='"hello"'
  90. ; -D MESH_PACKET_LOGGING=1
  91. ; -D MESH_DEBUG=1
  92. [env:Heltec_t114_without_display_companion_radio_ble]
  93. extends = Heltec_t114
  94. board_build.ldscript = boards/nrf52840_s140_v6_extrafs.ld
  95. board_upload.maximum_size = 712704
  96. build_flags =
  97. ${Heltec_t114.build_flags}
  98. -I examples/companion_radio/ui-new
  99. -D DISPLAY_CLASS=NullDisplayDriver
  100. -D MAX_CONTACTS=350
  101. -D MAX_GROUP_CHANNELS=40
  102. -D BLE_PIN_CODE=123456
  103. ; -D BLE_DEBUG_LOGGING=1
  104. -D OFFLINE_QUEUE_SIZE=256
  105. ; -D MESH_PACKET_LOGGING=1
  106. ; -D MESH_DEBUG=1
  107. build_src_filter = ${Heltec_t114.build_src_filter}
  108. +<helpers/nrf52/SerialBLEInterface.cpp>
  109. +<../examples/companion_radio/*.cpp>
  110. +<../examples/companion_radio/ui-new/*.cpp>
  111. lib_deps =
  112. ${Heltec_t114.lib_deps}
  113. densaugeo/base64 @ ~1.4.0
  114. [env:Heltec_t114_without_display_companion_radio_usb]
  115. extends = Heltec_t114
  116. board_build.ldscript = boards/nrf52840_s140_v6_extrafs.ld
  117. board_upload.maximum_size = 712704
  118. build_flags =
  119. ${Heltec_t114.build_flags}
  120. -I examples/companion_radio/ui-new
  121. -D DISPLAY_CLASS=NullDisplayDriver
  122. -D MAX_CONTACTS=350
  123. -D MAX_GROUP_CHANNELS=40
  124. build_src_filter = ${Heltec_t114.build_src_filter}
  125. +<helpers/nrf52/*.cpp>
  126. +<../examples/companion_radio/*.cpp>
  127. +<../examples/companion_radio/ui-new/*.cpp>
  128. lib_deps =
  129. ${Heltec_t114.lib_deps}
  130. densaugeo/base64 @ ~1.4.0
  131. ;
  132. ; Heltec T114 with ST7789 display
  133. ;
  134. [Heltec_t114_with_display]
  135. extends = Heltec_t114
  136. board = heltec_t114
  137. board_build.ldscript = boards/nrf52840_s140_v6.ld
  138. build_flags = ${Heltec_t114.build_flags}
  139. -D ST7789
  140. -D HELTEC_T114_WITH_DISPLAY
  141. -D DISPLAY_CLASS=ST7789Display
  142. build_src_filter = ${Heltec_t114.build_src_filter}
  143. +<helpers/ui/ST7789Display.cpp>
  144. +<helpers/ui/MomentaryButton.cpp>
  145. +<helpers/ui/OLEDDisplay.cpp>
  146. +<helpers/ui/OLEDDisplayFonts.cpp>
  147. lib_deps =
  148. ${Heltec_t114.lib_deps}
  149. adafruit/Adafruit SSD1306 @ ^2.5.13
  150. debug_tool = jlink
  151. upload_protocol = nrfutil
  152. [env:Heltec_t114_repeater]
  153. extends = Heltec_t114_with_display
  154. build_src_filter = ${Heltec_t114_with_display.build_src_filter}
  155. +<../examples/simple_repeater>
  156. build_flags =
  157. ${Heltec_t114_with_display.build_flags}
  158. -D ADVERT_NAME='"Heltec_T114 Repeater"'
  159. -D ADVERT_LAT=0.0
  160. -D ADVERT_LON=0.0
  161. -D ADMIN_PASSWORD='"password"'
  162. -D MAX_NEIGHBOURS=50
  163. ; -D MESH_PACKET_LOGGING=1
  164. ; -D MESH_DEBUG=1
  165. [env:Heltec_t114_repeater_bridge_rs232]
  166. extends = Heltec_t114
  167. build_flags =
  168. ${Heltec_t114.build_flags}
  169. -D ADVERT_NAME='"RS232 Bridge"'
  170. -D ADVERT_LAT=0.0
  171. -D ADVERT_LON=0.0
  172. -D ADMIN_PASSWORD='"password"'
  173. -D MAX_NEIGHBOURS=50
  174. -D WITH_RS232_BRIDGE=Serial2
  175. -D WITH_RS232_BRIDGE_RX=9
  176. -D WITH_RS232_BRIDGE_TX=10
  177. ; -D BRIDGE_DEBUG=1
  178. ; -D MESH_PACKET_LOGGING=1
  179. ; -D MESH_DEBUG=1
  180. build_src_filter = ${Heltec_t114_with_display.build_src_filter}
  181. +<helpers/bridges/RS232Bridge.cpp>
  182. +<../examples/simple_repeater>
  183. [env:Heltec_t114_room_server]
  184. extends = Heltec_t114_with_display
  185. build_src_filter = ${Heltec_t114_with_display.build_src_filter}
  186. +<../examples/simple_room_server>
  187. build_flags =
  188. ${Heltec_t114_with_display.build_flags}
  189. -D ADVERT_NAME='"Heltec_T114 Room"'
  190. -D ADVERT_LAT=0.0
  191. -D ADVERT_LON=0.0
  192. -D ADMIN_PASSWORD='"password"'
  193. -D ROOM_PASSWORD='"hello"'
  194. ; -D MESH_PACKET_LOGGING=1
  195. ; -D MESH_DEBUG=1
  196. [env:Heltec_t114_companion_radio_ble]
  197. extends = Heltec_t114_with_display
  198. board_build.ldscript = boards/nrf52840_s140_v6_extrafs.ld
  199. board_upload.maximum_size = 712704
  200. build_flags =
  201. ${Heltec_t114_with_display.build_flags}
  202. -I examples/companion_radio/ui-new
  203. -D MAX_CONTACTS=350
  204. -D MAX_GROUP_CHANNELS=40
  205. -D BLE_PIN_CODE=123456
  206. -D ENV_INCLUDE_GPS=1 ; enable the GPS page in UI
  207. ; -D BLE_DEBUG_LOGGING=1
  208. -D OFFLINE_QUEUE_SIZE=256
  209. ; -D MESH_PACKET_LOGGING=1
  210. ; -D MESH_DEBUG=1
  211. build_src_filter = ${Heltec_t114_with_display.build_src_filter}
  212. +<helpers/nrf52/SerialBLEInterface.cpp>
  213. +<../examples/companion_radio/*.cpp>
  214. +<../examples/companion_radio/ui-new/*.cpp>
  215. lib_deps =
  216. ${Heltec_t114_with_display.lib_deps}
  217. densaugeo/base64 @ ~1.4.0
  218. [env:Heltec_t114_companion_radio_usb]
  219. extends = Heltec_t114_with_display
  220. board_build.ldscript = boards/nrf52840_s140_v6_extrafs.ld
  221. board_upload.maximum_size = 712704
  222. build_flags =
  223. ${Heltec_t114_with_display.build_flags}
  224. -I examples/companion_radio/ui-new
  225. -D MAX_CONTACTS=350
  226. -D MAX_GROUP_CHANNELS=40
  227. ; -D BLE_PIN_CODE=123456
  228. ; -D BLE_DEBUG_LOGGING=1
  229. ; -D MESH_PACKET_LOGGING=1
  230. ; -D MESH_DEBUG=1
  231. build_src_filter = ${Heltec_t114_with_display.build_src_filter}
  232. +<helpers/nrf52/*.cpp>
  233. +<../examples/companion_radio/*.cpp>
  234. +<../examples/companion_radio/ui-new/*.cpp>
  235. lib_deps =
  236. ${Heltec_t114_with_display.lib_deps}
  237. densaugeo/base64 @ ~1.4.0
  238. [env:Heltec_t114_kiss_modem]
  239. extends = Heltec_t114
  240. build_src_filter = ${Heltec_t114.build_src_filter}
  241. +<../examples/kiss_modem/>