[nibble_zero_connect_base]
extends = esp32_base
board = esp32-s3-zero
build_flags =
  ${esp32_base.build_flags}
  -I variants/nibble_zero_connect
  -D NIBBLE_ZERO_CONNECT
  -D P_LORA_DIO_1=4
  -D P_LORA_NSS=10
  -D P_LORA_RESET=6
  -D P_LORA_BUSY=5
  -D P_LORA_SCLK=12
  -D P_LORA_MISO=13
  -D P_LORA_MOSI=11
  -D PIN_USER_BTN=1
  -D PIN_BOARD_SDA=8
  -D PIN_BOARD_SCL=7
  -D PIN_STATUS_LED=39
  -D P_LORA_TX_LED=39
  -D DISPLAY_ROTATION=0
  -D SX126X_DIO2_AS_RF_SWITCH=true
  -D SX126X_DIO3_TCXO_VOLTAGE=1.8
  -D SX126X_CURRENT_LIMIT=140
  -D RADIO_CLASS=CustomSX1262
  -D WRAPPER_CLASS=CustomSX1262Wrapper
  -D LORA_TX_POWER=22
  -D SX126X_RX_BOOSTED_GAIN=1
build_src_filter = ${esp32_base.build_src_filter}
  +<../variants/nibble_zero_connect>
lib_deps =
  ${esp32_base.lib_deps}
  adafruit/Adafruit SSD1306 @ ^2.5.13

[env:nibble_zero_connect_repeater_]
extends = nibble_zero_connect_base
build_flags =
  ${nibble_zero_connect_base.build_flags}
  -D DISPLAY_CLASS=SSD1306Display
  -D ADVERT_NAME='"Nibble Repeater"'
  -D ADVERT_LAT=0.0
  -D ADVERT_LON=0.0
  -D ADMIN_PASSWORD='"password"'
  -D MAX_NEIGHBOURS=50
build_src_filter = ${nibble_zero_connect_base.build_src_filter}
  +<helpers/ui/SSD1306Display.cpp>
  +<../examples/simple_repeater>
lib_deps =
  ${nibble_zero_connect_base.lib_deps}
  ${esp32_ota.lib_deps}

[env:nibble_zero_connect_repeater_bridge_espnow_]
extends = nibble_zero_connect_base
build_flags =
  ${nibble_zero_connect_base.build_flags}
  -D DISPLAY_CLASS=SSD1306Display
  -D ADVERT_NAME='"ESPNow Bridge"'
  -D ADVERT_LAT=0.0
  -D ADVERT_LON=0.0
  -D ADMIN_PASSWORD='"password"'
  -D MAX_NEIGHBOURS=50
  -D WITH_ESPNOW_BRIDGE=1
build_src_filter = ${nibble_zero_connect_base.build_src_filter}
  +<helpers/bridges/ESPNowBridge.cpp>
  +<helpers/ui/SSD1306Display.cpp>
  +<../examples/simple_repeater>
lib_deps =
  ${nibble_zero_connect_base.lib_deps}
  ${esp32_ota.lib_deps}

[env:nibble_zero_connect_terminal_chat_]
extends = nibble_zero_connect_base
build_flags =
  ${nibble_zero_connect_base.build_flags}
  -D MAX_CONTACTS=300
  -D MAX_GROUP_CHANNELS=1
build_src_filter = ${nibble_zero_connect_base.build_src_filter}
  +<../examples/simple_secure_chat/main.cpp>
lib_deps =
  ${nibble_zero_connect_base.lib_deps}
  densaugeo/base64 @ ~1.4.0

[env:nibble_zero_connect_room_server_]
extends = nibble_zero_connect_base
build_flags =
  ${nibble_zero_connect_base.build_flags}
  -D DISPLAY_CLASS=SSD1306Display
  -D ADVERT_NAME='"Nibble Room"'
  -D ADVERT_LAT=0.0
  -D ADVERT_LON=0.0
  -D ADMIN_PASSWORD='"password"'
  -D ROOM_PASSWORD='"hello"'
build_src_filter = ${nibble_zero_connect_base.build_src_filter}
  +<helpers/ui/SSD1306Display.cpp>
  +<../examples/simple_room_server>
lib_deps =
  ${nibble_zero_connect_base.lib_deps}
  ${esp32_ota.lib_deps}

[env:nibble_zero_connect_companion_radio_usb_]
extends = nibble_zero_connect_base
build_flags =
  ${nibble_zero_connect_base.build_flags}
  -I examples/companion_radio/ui-new
  -D DISPLAY_CLASS=SSD1306Display
  -D MAX_CONTACTS=300
  -D MAX_GROUP_CHANNELS=8
  -D ENABLE_USB_INTERFACE
build_src_filter = ${nibble_zero_connect_base.build_src_filter}
  +<helpers/ui/SSD1306Display.cpp>
  +<helpers/ui/MomentaryButton.cpp>
  +<../examples/companion_radio/*.cpp>
  +<../examples/companion_radio/ui-new/*.cpp>
lib_deps =
  ${nibble_zero_connect_base.lib_deps}
  densaugeo/base64 @ ~1.4.0

[env:nibble_zero_connect_companion_radio_ble_]
extends = nibble_zero_connect_base
build_flags =
  ${nibble_zero_connect_base.build_flags}
  -I examples/companion_radio/ui-new
  -D DISPLAY_CLASS=SSD1306Display
  -D MAX_CONTACTS=300
  -D MAX_GROUP_CHANNELS=8
  -D BLE_PIN_CODE=123456
  -D BLE_DEBUG_LOGGING=1
  -D OFFLINE_QUEUE_SIZE=256
build_src_filter = ${nibble_zero_connect_base.build_src_filter}
  +<helpers/esp32/*.cpp>
  +<helpers/ui/SSD1306Display.cpp>
  +<helpers/ui/MomentaryButton.cpp>
  +<../examples/companion_radio/*.cpp>
  +<../examples/companion_radio/ui-new/*.cpp>
lib_deps =
  ${nibble_zero_connect_base.lib_deps}
  densaugeo/base64 @ ~1.4.0

[env:nibble_zero_connect_companion_radio_wifi_]
extends = nibble_zero_connect_base
build_flags =
  ${nibble_zero_connect_base.build_flags}
  -I examples/companion_radio/ui-new
  -D DISPLAY_CLASS=SSD1306Display
  -D MAX_CONTACTS=300
  -D MAX_GROUP_CHANNELS=8
  -D WIFI_DEBUG_LOGGING=1
  -D WIFI_SSID='"myssid"'
  -D WIFI_PWD='"mypwd"'
build_src_filter = ${nibble_zero_connect_base.build_src_filter}
  +<helpers/ui/SSD1306Display.cpp>
  +<helpers/ui/MomentaryButton.cpp>
  +<helpers/esp32/*.cpp>
  +<../examples/companion_radio/*.cpp>
  +<../examples/companion_radio/ui-new/*.cpp>
lib_deps =
  ${nibble_zero_connect_base.lib_deps}
  densaugeo/base64 @ ~1.4.0


