platformio.ini 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106
  1. ; PlatformIO Project Configuration File
  2. ;
  3. ; Build options: build flags, source filter
  4. ; Upload options: custom upload port, speed and extra flags
  5. ; Library options: dependencies, extra library storages
  6. ; Advanced options: extra scripting
  7. ;
  8. ; Please visit documentation for the other options and examples
  9. ; https://docs.platformio.org/page/projectconf.html
  10. [platformio]
  11. default_envs = view
  12. [base_config]
  13. platform = espressif32@3.4
  14. framework = arduino
  15. monitor_speed = 115200
  16. monitor_flags =
  17. --eol=CRLF
  18. --echo
  19. --filter=esp32_exception_decoder
  20. lib_deps =
  21. askuric/Simple FOC @ 2.2.0
  22. infineon/TLV493D-Magnetic-Sensor @ 1.0.3
  23. bxparks/AceButton @ 1.9.1
  24. build_flags =
  25. -DCORE_DEBUG_LEVEL=ARDUHAL_LOG_LEVEL_DEBUG
  26. -DMONITOR_SPEED=115200
  27. [env:view]
  28. extends = base_config
  29. board = esp32doit-devkit-v1
  30. lib_deps =
  31. ${base_config.lib_deps}
  32. bodmer/TFT_eSPI@2.4.25
  33. fastled/FastLED @ 3.5.0
  34. bogde/HX711 @ 0.7.5
  35. adafruit/Adafruit VEML7700 Library @ 1.1.1
  36. bakercp/PacketSerial @ 1.4.0
  37. nanopb/Nanopb @ 0.4.6 ; Ideally this would reference the nanopb submodule, but that would require
  38. ; everyone to check out submodules to just compile, so we use the library
  39. ; registry for the runtime. The submodule is available for manually updating
  40. ; the pre-compiled (checked in) .pb.h/c files when proto files change, but is
  41. ; otherwise not used during application firmware compilation.
  42. build_flags =
  43. ${base_config.build_flags}
  44. -DSK_DISPLAY=1
  45. -DSK_LEDS=1
  46. -DNUM_LEDS=8
  47. -DSENSOR_MT6701=1
  48. -DSK_STRAIN=1
  49. -DSK_INVERT_ROTATION=1
  50. -DSK_ALS=1
  51. -DPIN_UH=26
  52. -DPIN_UL=25
  53. -DPIN_VH=27
  54. -DPIN_VL=32
  55. -DPIN_WH=12
  56. -DPIN_WL=33
  57. -DPIN_BUTTON_NEXT=-1
  58. -DPIN_BUTTON_PREV=-1
  59. -DPIN_SDA=15
  60. -DPIN_SCL=8
  61. -DPIN_MT_DATA=37
  62. -DPIN_MT_CLOCK=13
  63. -DPIN_MT_CSN=14
  64. -DPIN_LED_DATA=7
  65. -DPIN_LCD_BACKLIGHT=19
  66. -DDESCRIPTION_FONT=Roboto_Thin_24
  67. -DDESCRIPTION_Y_OFFSET=20
  68. -DVALUE_OFFSET=30
  69. -DDRAW_ARC=0
  70. -DUSER_SETUP_LOADED=1
  71. -DGC9A01_DRIVER=1
  72. -DCGRAM_OFFSET=1
  73. -DTFT_WIDTH=240
  74. -DTFT_HEIGHT=240
  75. -DTFT_MISO=-1
  76. -DTFT_MOSI=5
  77. -DTFT_SCLK=20
  78. -DTFT_CS=21
  79. -DTFT_DC=22
  80. -DTFT_RST=4
  81. -DTFT_BL=-1
  82. -DLOAD_GLCD=1
  83. -DLOAD_GFXFF=1
  84. -DSPI_FREQUENCY=40000000
  85. ; Reduce loop task stack size (only works on newer IDF Arduino core)
  86. ; -DARDUINO_LOOP_STACK_SIZE=2048
  87. ; Modify the default unusable pin mask to allow GPIO 7 (allowed to use on ESP32-PICO-V3-02)
  88. ; Unusable bits: 6, 8, 9, 10, 20
  89. ; (0ULL | _FL_BIT(6) | _FL_BIT(8) | _FL_BIT(9) | _FL_BIT(10) | _FL_BIT(20))
  90. -DFASTLED_UNUSABLE_PIN_MASK=0x100740LL
  91. ; 0~39 except from 24, 28~31 are valid
  92. ; (0xFFFFFFFFFFULL & ~(0ULL | _FL_BIT(24) | _FL_BIT(28) | _FL_BIT(29) | _FL_BIT(30) | _FL_BIT(31)))
  93. -DSOC_GPIO_VALID_GPIO_MASK=0xFF0EFFFFFF
  94. ; GPIO >= 34 are input only
  95. ; (SOC_GPIO_VALID_GPIO_MASK & ~(0ULL | _FL_BIT(34) | _FL_BIT(35) | _FL_BIT(36) | _FL_BIT(37) | _FL_BIT(38) | _FL_BIT(39)))
  96. -DSOC_GPIO_VALID_OUTPUT_GPIO_MASK=0x30EFFFFFF