platformio.ini 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132
  1. ; RAK11310
  2. ; Pinout from https://github.com/beegee-tokyo/SX126x-Arduino/blob/6be1f87b84ad4d445a38ec53d65be4425f2383f3/src/boards/mcu/board.cpp#L259
  3. [rak11310]
  4. extends = rp2040_base
  5. board = rakwireless_rak11300
  6. board_build.filesystem_size = 0.5m
  7. build_flags = ${rp2040_base.build_flags}
  8. -I variants/rak11310
  9. -D ARDUINO_RAKWIRELESS_RAK11300=1
  10. -D SX126X_CURRENT_LIMIT=140
  11. -D RADIO_CLASS=CustomSX1262
  12. -D WRAPPER_CLASS=CustomSX1262Wrapper
  13. -D P_LORA_DIO_1=29
  14. -D P_LORA_NSS=13 ; CS
  15. -D P_LORA_RESET=14
  16. -D P_LORA_BUSY=15
  17. -D P_LORA_SCLK=10
  18. -D P_LORA_MISO=12
  19. -D P_LORA_MOSI=11
  20. -D P_LORA_TX_LED=24 ; green led = 23, blue led = 24
  21. -D SX126X_DIO2_AS_RF_SWITCH=true
  22. -D SX126X_DIO3_TCXO_VOLTAGE=1.8
  23. -D SX126X_RX_BOOSTED_GAIN=1
  24. -D LORA_TX_POWER=22
  25. ; Debug options
  26. ; -D DEBUG_RP2040_WIRE=1
  27. ; -D DEBUG_RP2040_SPI=1
  28. ; -D DEBUG_RP2040_CORE=1
  29. ; -D RADIOLIB_DEBUG_SPI=1
  30. ; -D DEBUG_RP2040_PORT=Serial
  31. build_src_filter = ${rp2040_base.build_src_filter}
  32. +<RAK11310Board.cpp>
  33. +<../variants/rak11310>
  34. lib_deps = ${rp2040_base.lib_deps}
  35. [env:rak11310_repeater]
  36. extends = rak11310
  37. build_flags = ${rak11310.build_flags}
  38. -D ADVERT_NAME='"RAK11310 Repeater"'
  39. -D ADVERT_LAT=0.0
  40. -D ADVERT_LON=0.0
  41. -D ADMIN_PASSWORD='"password"'
  42. -D MAX_NEIGHBOURS=50
  43. ; -D MESH_PACKET_LOGGING=1
  44. ; -D MESH_DEBUG=1
  45. build_src_filter = ${rak11310.build_src_filter}
  46. +<../examples/simple_repeater>
  47. [env:rak11310_repeater_bridge_rs232]
  48. extends = rak11310
  49. build_flags = ${rak11310.build_flags}
  50. -D ADVERT_NAME='"RS232 Bridge"'
  51. -D ADVERT_LAT=0.0
  52. -D ADVERT_LON=0.0
  53. -D ADMIN_PASSWORD='"password"'
  54. -D MAX_NEIGHBOURS=50
  55. -D WITH_RS232_BRIDGE=Serial2
  56. -D WITH_RS232_BRIDGE_RX=9
  57. -D WITH_RS232_BRIDGE_TX=8
  58. ; -D BRIDGE_DEBUG=1
  59. ; -D MESH_PACKET_LOGGING=1
  60. ; -D MESH_DEBUG=1
  61. build_src_filter = ${rak11310.build_src_filter}
  62. +<helpers/bridges/RS232Bridge.cpp>
  63. +<../examples/simple_repeater>
  64. [env:rak11310_room_server]
  65. extends = rak11310
  66. build_flags = ${rak11310.build_flags}
  67. -D ADVERT_NAME='"RAK11310 Room"'
  68. -D ADVERT_LAT=0.0
  69. -D ADVERT_LON=0.0
  70. -D ADMIN_PASSWORD='"password"'
  71. -D ROOM_PASSWORD='"hello"'
  72. ; -D MESH_PACKET_LOGGING=1
  73. ; -D MESH_DEBUG=1
  74. build_src_filter = ${rak11310.build_src_filter}
  75. +<../examples/simple_room_server>
  76. [env:rak11310_companion_radio_usb]
  77. extends = rak11310
  78. build_flags = ${rak11310.build_flags}
  79. -D MAX_CONTACTS=100
  80. -D MAX_GROUP_CHANNELS=8
  81. ; NOTE: DO NOT ENABLE --> -D MESH_PACKET_LOGGING=1
  82. ; NOTE: DO NOT ENABLE --> -D MESH_DEBUG=1
  83. build_src_filter = ${rak11310.build_src_filter}
  84. +<../examples/companion_radio/*.cpp>
  85. lib_deps = ${rak11310.lib_deps}
  86. densaugeo/base64 @ ~1.4.0
  87. ; [env:rak11310_companion_radio_ble]
  88. ; extends = rak11310
  89. ; build_flags = ${rak11310.build_flags}
  90. ; -D MAX_CONTACTS=100
  91. ; -D MAX_GROUP_CHANNELS=8
  92. ; -D BLE_PIN_CODE=123456
  93. ; -D BLE_DEBUG_LOGGING=1
  94. ; ; -D MESH_PACKET_LOGGING=1
  95. ; ; -D MESH_DEBUG=1
  96. ; build_src_filter = ${rak11310.build_src_filter}
  97. ; +<../examples/companion_radio/*.cpp>
  98. ; lib_deps = ${rak11310.lib_deps}
  99. ; densaugeo/base64 @ ~1.4.0
  100. ; [env:rak11310_companion_radio_wifi]
  101. ; extends = rak11310
  102. ; build_flags = ${rak11310.build_flags}
  103. ; -D MAX_CONTACTS=100
  104. ; -D MAX_GROUP_CHANNELS=8
  105. ; -D WIFI_DEBUG_LOGGING=1
  106. ; -D WIFI_SSID='"myssid"'
  107. ; -D WIFI_PWD='"mypwd"'
  108. ; ; -D MESH_PACKET_LOGGING=1
  109. ; ; -D MESH_DEBUG=1
  110. ; build_src_filter = ${rak11310.build_src_filter}
  111. ; +<../examples/companion_radio/*.cpp>
  112. ; lib_deps = ${rak11310.lib_deps}
  113. ; densaugeo/base64 @ ~1.4.0
  114. [env:rak11310_terminal_chat]
  115. extends = rak11310
  116. build_flags = ${rak11310.build_flags}
  117. -D MAX_CONTACTS=100
  118. -D MAX_GROUP_CHANNELS=1
  119. ; -D MESH_PACKET_LOGGING=1
  120. ; -D MESH_DEBUG=1
  121. build_src_filter = ${rak11310.build_src_filter}
  122. +<../examples/simple_secure_chat/main.cpp>
  123. lib_deps = ${rak11310.lib_deps}
  124. densaugeo/base64 @ ~1.4.0