summaryrefslogtreecommitdiff
path: root/Makefile
blob: 564aac67158f1c506daf54942f748160915f5ddb (plain)
  1. BUILD_DIR = $(CURDIR)/.build
  2. OPTS_HARDWARE = -hardware /usr/share/arduino/hardware -hardware /home/jonas/.arduino15/packages
  3. OPTS_TOOLS = -tools /usr/share/arduino/hardware/tools/avr -tools /home/jonas/.arduino15/packages
  4. OPTS_LIBS = -libraries /home/jonas/Arduino/libraries
  5. FQBN = -fqbn=esp32:esp32:esp32:JTAGAdapter=default,PSRAM=disabled,PartitionScheme=default,CPUFreq=240,FlashMode=qio,FlashFreq=80,FlashSize=4M,UploadSpeed=921600,LoopCore=1,EventsCore=1,DebugLevel=none,EraseFlash=none
  6. all: build upload
  7. build:
  8. rm -rf .build
  9. mkdir --parents .build .cache
  10. arduino-builder -compile -logger=machine \
  11. $(OPTS_HARDWARE) $(OPTS_TOOLS) $(OPTS_LIBS) $(FQBN) \
  12. -ide-version=10819 -build-path $(BUILD_DIR) -warnings=none -build-cache $(CURDIR)/.cache \
  13. -prefs=build.warn_data_percentage=75 \
  14. -prefs=runtime.tools.riscv32-esp-elf-gcc.path=/home/jonas/.arduino15/packages/esp32/tools/riscv32-esp-elf-gcc/esp-2021r2-patch5-8.4.0 \
  15. -prefs=runtime.tools.riscv32-esp-elf-gcc-esp-2021r2-patch5-8.4.0.path=/home/jonas/.arduino15/packages/esp32/tools/riscv32-esp-elf-gcc/esp-2021r2-patch5-8.4.0 \
  16. -prefs=runtime.tools.esptool_py.path=/home/jonas/.arduino15/packages/esp32/tools/esptool_py/4.5.1 \
  17. -prefs=runtime.tools.esptool_py-4.5.1.path=/home/jonas/.arduino15/packages/esp32/tools/esptool_py/4.5.1 \
  18. -prefs=runtime.tools.mkspiffs.path=/home/jonas/.arduino15/packages/esp32/tools/mkspiffs/0.2.3 \
  19. -prefs=runtime.tools.mkspiffs-0.2.3.path=/home/jonas/.arduino15/packages/esp32/tools/mkspiffs/0.2.3 \
  20. -prefs=runtime.tools.xtensa-esp32-elf-gcc.path=/home/jonas/.arduino15/packages/esp32/tools/xtensa-esp32-elf-gcc/esp-2021r2-patch5-8.4.0 \
  21. -prefs=runtime.tools.xtensa-esp32-elf-gcc-esp-2021r2-patch5-8.4.0.path=/home/jonas/.arduino15/packages/esp32/tools/xtensa-esp32-elf-gcc/esp-2021r2-patch5-8.4.0 \
  22. -prefs=runtime.tools.xtensa-esp32s3-elf-gcc.path=/home/jonas/.arduino15/packages/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0 \
  23. -prefs=runtime.tools.xtensa-esp32s3-elf-gcc-esp-2021r2-patch5-8.4.0.path=/home/jonas/.arduino15/packages/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0 \
  24. -prefs=runtime.tools.xtensa-esp-elf-gdb.path=/home/jonas/.arduino15/packages/esp32/tools/xtensa-esp-elf-gdb/11.2_20220823 \
  25. -prefs=runtime.tools.xtensa-esp-elf-gdb-11.2_20220823.path=/home/jonas/.arduino15/packages/esp32/tools/xtensa-esp-elf-gdb/11.2_20220823 \
  26. -prefs=runtime.tools.riscv32-esp-elf-gdb.path=/home/jonas/.arduino15/packages/esp32/tools/riscv32-esp-elf-gdb/11.2_20220823 \
  27. -prefs=runtime.tools.riscv32-esp-elf-gdb-11.2_20220823.path=/home/jonas/.arduino15/packages/esp32/tools/riscv32-esp-elf-gdb/11.2_20220823 \
  28. -prefs=runtime.tools.dfu-util.path=/home/jonas/.arduino15/packages/arduino/tools/dfu-util/0.11.0-arduino5 \
  29. -prefs=runtime.tools.dfu-util-0.11.0-arduino5.path=/home/jonas/.arduino15/packages/arduino/tools/dfu-util/0.11.0-arduino5 \
  30. -prefs=runtime.tools.xtensa-esp32s2-elf-gcc.path=/home/jonas/.arduino15/packages/esp32/tools/xtensa-esp32s2-elf-gcc/esp-2021r2-patch5-8.4.0 \
  31. -prefs=runtime.tools.xtensa-esp32s2-elf-gcc-esp-2021r2-patch5-8.4.0.path=/home/jonas/.arduino15/packages/esp32/tools/xtensa-esp32s2-elf-gcc/esp-2021r2-patch5-8.4.0 \
  32. -prefs=runtime.tools.mklittlefs.path=/home/jonas/.arduino15/packages/esp32/tools/mklittlefs/3.0.0-gnu12-dc7f933 \
  33. -prefs=runtime.tools.mklittlefs-3.0.0-gnu12-dc7f933.path=/home/jonas/.arduino15/packages/esp32/tools/mklittlefs/3.0.0-gnu12-dc7f933 \
  34. -prefs=runtime.tools.openocd-esp32.path=/home/jonas/.arduino15/packages/esp32/tools/openocd-esp32/v0.12.0-esp32-20230419 \
  35. -prefs=runtime.tools.openocd-esp32-v0.12.0-esp32-20230419.path=/home/jonas/.arduino15/packages/esp32/tools/openocd-esp32/v0.12.0-esp32-20230419 \
  36. -verbose \
  37. $(CURDIR)/main.ino
  38. clear_cache:
  39. rm -rf .cache
  40. #arduino-builder -compile -logger=machine -hardware /usr/share/arduino/hardware -hardware /home/jonas/.arduino15/packages -tools /usr/share/arduino/hardware/tools/avr -tools /home/jonas/.arduino15/packages -libraries /home/jonas/Arduino/libraries -fqbn=esp32:esp32:esp32:JTAGAdapter=default,PSRAM=disabled,PartitionScheme=default,CPUFreq=240,FlashMode=qio,FlashFreq=80,FlashSize=4M,UploadSpeed=921600,LoopCore=1,EventsCore=1,DebugLevel=none,EraseFlash=none -vid-pid=10C4_EA60 -ide-version=10819 -build-path /tmp/arduino_build_48694 -warnings=none -build-cache /tmp/arduino_cache_282410 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.riscv32-esp-elf-gcc.path=/home/jonas/.arduino15/packages/esp32/tools/riscv32-esp-elf-gcc/esp-2021r2-patch5-8.4.0 -prefs=runtime.tools.riscv32-esp-elf-gcc-esp-2021r2-patch5-8.4.0.path=/home/jonas/.arduino15/packages/esp32/tools/riscv32-esp-elf-gcc/esp-2021r2-patch5-8.4.0 -prefs=runtime.tools.esptool_py.path=/home/jonas/.arduino15/packages/esp32/tools/esptool_py/4.5.1 -prefs=runtime.tools.esptool_py-4.5.1.path=/home/jonas/.arduino15/packages/esp32/tools/esptool_py/4.5.1 -prefs=runtime.tools.mkspiffs.path=/home/jonas/.arduino15/packages/esp32/tools/mkspiffs/0.2.3 -prefs=runtime.tools.mkspiffs-0.2.3.path=/home/jonas/.arduino15/packages/esp32/tools/mkspiffs/0.2.3 -prefs=runtime.tools.xtensa-esp32-elf-gcc.path=/home/jonas/.arduino15/packages/esp32/tools/xtensa-esp32-elf-gcc/esp-2021r2-patch5-8.4.0 -prefs=runtime.tools.xtensa-esp32-elf-gcc-esp-2021r2-patch5-8.4.0.path=/home/jonas/.arduino15/packages/esp32/tools/xtensa-esp32-elf-gcc/esp-2021r2-patch5-8.4.0 -prefs=runtime.tools.xtensa-esp32s3-elf-gcc.path=/home/jonas/.arduino15/packages/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0 -prefs=runtime.tools.xtensa-esp32s3-elf-gcc-esp-2021r2-patch5-8.4.0.path=/home/jonas/.arduino15/packages/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0 -prefs=runtime.tools.xtensa-esp-elf-gdb.path=/home/jonas/.arduino15/packages/esp32/tools/xtensa-esp-elf-gdb/11.2_20220823 -prefs=runtime.tools.xtensa-esp-elf-gdb-11.2_20220823.path=/home/jonas/.arduino15/packages/esp32/tools/xtensa-esp-elf-gdb/11.2_20220823 -prefs=runtime.tools.riscv32-esp-elf-gdb.path=/home/jonas/.arduino15/packages/esp32/tools/riscv32-esp-elf-gdb/11.2_20220823 -prefs=runtime.tools.riscv32-esp-elf-gdb-11.2_20220823.path=/home/jonas/.arduino15/packages/esp32/tools/riscv32-esp-elf-gdb/11.2_20220823 -prefs=runtime.tools.dfu-util.path=/home/jonas/.arduino15/packages/arduino/tools/dfu-util/0.11.0-arduino5 -prefs=runtime.tools.dfu-util-0.11.0-arduino5.path=/home/jonas/.arduino15/packages/arduino/tools/dfu-util/0.11.0-arduino5 -prefs=runtime.tools.xtensa-esp32s2-elf-gcc.path=/home/jonas/.arduino15/packages/esp32/tools/xtensa-esp32s2-elf-gcc/esp-2021r2-patch5-8.4.0 -prefs=runtime.tools.xtensa-esp32s2-elf-gcc-esp-2021r2-patch5-8.4.0.path=/home/jonas/.arduino15/packages/esp32/tools/xtensa-esp32s2-elf-gcc/esp-2021r2-patch5-8.4.0 -prefs=runtime.tools.mklittlefs.path=/home/jonas/.arduino15/packages/esp32/tools/mklittlefs/3.0.0-gnu12-dc7f933 -prefs=runtime.tools.mklittlefs-3.0.0-gnu12-dc7f933.path=/home/jonas/.arduino15/packages/esp32/tools/mklittlefs/3.0.0-gnu12-dc7f933 -prefs=runtime.tools.openocd-esp32.path=/home/jonas/.arduino15/packages/esp32/tools/openocd-esp32/v0.12.0-esp32-20230419 -prefs=runtime.tools.openocd-esp32-v0.12.0-esp32-20230419.path=/home/jonas/.arduino15/packages/esp32/tools/openocd-esp32/v0.12.0-esp32-20230419 -verbose /home/jonas/Arduino/sketch_oct06b/sketch_oct06b.ino
  41. upload:
  42. python3 /home/jonas/.arduino15/packages/esp32/tools/esptool_py/4.5.1/esptool.py \
  43. --chip esp32 --port /dev/ttyUSB0 --baud 921600 \
  44. --before default_reset --after hard_reset write_flash \
  45. -z --flash_mode dio --flash_freq 80m --flash_size 4MB \
  46. 0x1000 $(BUILD_DIR)/main.ino.bootloader.bin \
  47. 0x8000 $(BUILD_DIR)/main.ino.partitions.bin \
  48. 0xe000 /home/jonas/.arduino15/packages/esp32/hardware/esp32/2.0.14/tools/partitions/boot_app0.bin \
  49. 0x10000 $(BUILD_DIR)/main.ino.bin