[platformio]
src_dir = .

[env]
lib_extra_dirs = ../../
lib_ldf_mode = deep+
lib_ignore = examples
build_flags = ; -DMQTT_BUFFER_SIZE=768 -D_IR_LOCALE_=en-AU
framework = arduino
platform = espressif8266
monitor_speed = 115200

[common]
lib_deps_builtin =
lib_deps_external =
  PubSubClient@>=2.8.0
  ArduinoJson@>=6.0

[common_esp8266]
lib_deps_external =
  ${common.lib_deps_builtin}
  ${common.lib_deps_external}
  WifiManager@>=0.14

[common_esp32]
lib_deps_external =
  ${common.lib_deps_builtin}
  ${common.lib_deps_external}
  https://github.com/tzapu/WiFiManager.git#development

[env:nodemcuv2]
board = nodemcuv2
lib_deps = ${common_esp8266.lib_deps_external}

[env:d1_mini]
board = d1_mini
lib_deps = ${common_esp8266.lib_deps_external}

[env:d1_mini_no_mqtt]
board = d1_mini
build_flags =
  ${env.build_flags}
  -DMQTT_ENABLE=false
lib_deps = ${common_esp8266.lib_deps_external}

[env:esp32dev]
platform = espressif32
board = esp32dev
lib_deps = ${common_esp32.lib_deps_external}

[env:esp01_1m]
board = esp01_1m
build_flags =
  ${env.build_flags}
  -Wl,-Teagle.flash.1m64.ld
lib_deps = ${common_esp8266.lib_deps_external}
