|
12 | 12 | required: true
|
13 | 13 |
|
14 | 14 | jobs:
|
| 15 | + build-esp32sx-esptool: |
| 16 | + name: Build WipperSnapper ESP32-Sx |
| 17 | + runs-on: ubuntu-latest |
| 18 | + strategy: |
| 19 | + fail-fast: false |
| 20 | + matrix: |
| 21 | + arduino-platform: ["funhouse_noota"] |
| 22 | + include: |
| 23 | + - offset: "0x1000" |
| 24 | + steps: |
| 25 | + - uses: actions/setup-python@v4 |
| 26 | + with: |
| 27 | + python-version: '3.x' |
| 28 | + - uses: actions/checkout@v4 |
| 29 | + - name: Get WipperSnapper version |
| 30 | + run: | |
| 31 | + git fetch --prune --unshallow --tags |
| 32 | + git describe --dirty --tags |
| 33 | + echo >>$GITHUB_ENV WS_VERSION=$(git describe --dirty --tags) |
| 34 | + - uses: actions/checkout@v4 |
| 35 | + with: |
| 36 | + repository: adafruit/ci-arduino |
| 37 | + path: ci |
| 38 | + - name: Checkout Board Definitions |
| 39 | + uses: actions/checkout@v4 |
| 40 | + with: |
| 41 | + repository: adafruit/Wippersnapper_Boards |
| 42 | + path: ws-boards |
| 43 | + ref: funhouse-web-native-usb |
| 44 | + - name: Install CI-Arduino |
| 45 | + run: bash ci/actions_install.sh |
| 46 | + - name: Install extra Arduino libraries |
| 47 | + run: | |
| 48 | + git clone --quiet https://github.com/milesburton/Arduino-Temperature-Control-Library.git /home/runner/Arduino/libraries/Arduino-Temperature-Control-Library |
| 49 | + git clone --quiet https://github.com/pstolarz/OneWireNg.git /home/runner/Arduino/libraries/OneWireNg |
| 50 | + git clone --quiet https://github.com/adafruit/Adafruit_HX8357_Library.git /home/runner/Arduino/libraries/Adafruit_HX8357_Library |
| 51 | + git clone --quiet https://github.com/adafruit/Adafruit_ILI9341.git /home/runner/Arduino/libraries/Adafruit_ILI9341 |
| 52 | + git clone --quiet https://github.com/adafruit/Adafruit_STMPE610.git /home/runner/Arduino/libraries/Adafruit_STMPE610 |
| 53 | + git clone --quiet https://github.com/adafruit/Adafruit-ST7735-Library.git /home/runner/Arduino/libraries/Adafruit-ST7735-Library |
| 54 | + git clone --quiet https://github.com/adafruit/Adafruit_TouchScreen.git /home/runner/Arduino/libraries/Adafruit_TouchScreen |
| 55 | + git clone --depth 1 --branch wippersnapper https://github.com/brentru/lvgl.git /home/runner/Arduino/libraries/lvgl |
| 56 | + git clone --depth 1 --branch development https://github.com/brentru/Adafruit_LvGL_Glue.git /home/runner/Arduino/libraries/Adafruit_LittlevGL_Glue_Library |
| 57 | + - name: Download and install stable Nanopb |
| 58 | + run: | |
| 59 | + # Download and extract nanopb |
| 60 | + wget https://jpa.kapsi.fi/nanopb/download/nanopb-0.4.8.tar.gz |
| 61 | + tar -xf nanopb-0.4.8.tar.gz |
| 62 | + # Copy files to WipperSnapper's src/nanopb directory |
| 63 | + cp nanopb/pb_common.* nanopb/pb_encode.* nanopb/pb_decode.* src/nanopb |
| 64 | + mv nanopb/pb.h src/nanopb/nanopb.pb.h |
| 65 | + - name: List all files in Adafruit_LittlevGL_Glue_Library folder |
| 66 | + run: | |
| 67 | + ls /home/runner/Arduino/libraries/Adafruit_LittlevGL_Glue_Library |
| 68 | + - name: Copy lv_conf.h file in Adafruit_LittlevGL_Glue_Library to the arduino library folder |
| 69 | + run: | |
| 70 | + cp /home/runner/Arduino/libraries/Adafruit_LittlevGL_Glue_Library/lv_conf.h /home/runner/Arduino/libraries |
| 71 | + - name: Install Dependencies (esptool) |
| 72 | + run: | |
| 73 | + pip3 install esptool |
| 74 | + - name: Build for ESP32-SX |
| 75 | + run: python3 ci/build_platform.py ${{ matrix.arduino-platform }} --build_timeout 48000 |
| 76 | + - name: list files |
| 77 | + run: | |
| 78 | + ls -Rla examples/ |
| 79 | + - name: Rename build artifacts to reflect the platform name |
| 80 | + run: | |
| 81 | + mv examples/Wippersnapper_demo/build/*/Wippersnapper_demo.ino.bin wippersnapper.${{ matrix.arduino-platform }}.fatfs.${{ env.WS_VERSION }}.bin |
| 82 | + mv examples/Wippersnapper_demo/build/*/Wippersnapper_demo.ino.elf wippersnapper.${{ matrix.arduino-platform }}.fatfs.${{ env.WS_VERSION }}.elf |
| 83 | + mv examples/Wippersnapper_demo/build/*/Wippersnapper_demo.ino.map wippersnapper.${{ matrix.arduino-platform }}.fatfs.${{ env.WS_VERSION }}.map |
| 84 | + mv examples/Wippersnapper_demo/build/*/Wippersnapper_demo.ino.bootloader.bin wippersnapper.${{ matrix.arduino-platform }}.fatfs.${{ env.WS_VERSION }}.bootloader.bin |
| 85 | + mv examples/Wippersnapper_demo/build/*/Wippersnapper_demo.ino.partitions.bin wippersnapper.${{ matrix.arduino-platform }}.fatfs.${{ env.WS_VERSION }}.partitions.bin |
| 86 | + - name: Get Board Flash Parameters |
| 87 | + id: get_board_json |
| 88 | + run: | |
| 89 | + board_name=${{ matrix.arduino-platform }} |
| 90 | + # Remove '_noota' suffix if present |
| 91 | + board_name=${board_name%_noota} |
| 92 | + # Remove 'wippersnapper_' prefix if present |
| 93 | + board_name=${board_name#wippersnapper_} |
| 94 | + content=$(cat ws-boards/boards/${board_name//_/-}/definition.json) |
| 95 | + { |
| 96 | + echo 'boardJson<<EOF' |
| 97 | + echo $content |
| 98 | + echo EOF |
| 99 | + } >> "$GITHUB_OUTPUT" |
| 100 | + - name: list arduino esp32 core files |
| 101 | + run: | |
| 102 | + ls /home/runner/.arduino15/packages/esp32/hardware/esp32/*/tools/partitions |
| 103 | + - name: Check boot_app0 file existence (esp32sx built from core, not-source) |
| 104 | + id: check_files |
| 105 | + uses: andstor/file-existence-action@v2 |
| 106 | + with: |
| 107 | + files: "/home/runner/.arduino15/packages/esp32/hardware/esp32/*/tools/partitions/boot_app0.bin" |
| 108 | + - name: boot_app0 file from arduino-cli core |
| 109 | + if: steps.check_files.outputs.files_exists == 'true' |
| 110 | + run: mv /home/runner/.arduino15/packages/esp32/hardware/esp32/*/tools/partitions/boot_app0.bin wippersnapper.${{ matrix.arduino-platform }}.fatfs.${{ env.WS_VERSION }}.boot_app0.bin |
| 111 | + - name: boot_app0 file from esp32 source bsp |
| 112 | + if: steps.check_files.outputs.files_exists == 'false' |
| 113 | + run: mv /home/runner/Arduino/hardware/espressif/esp32/tools/partitions/boot_app0.bin wippersnapper.${{ matrix.arduino-platform }}.fatfs.${{ env.WS_VERSION }}.boot_app0.bin |
| 114 | + - name: Create combined binary using Esptool merge_bin |
| 115 | + run: | |
| 116 | + echo ${{ steps.get_board_json.outputs.boardJson }} |
| 117 | + echo ${{ fromJson(steps.get_board_json.outputs.boardJson) }} |
| 118 | + python3 -m esptool --chip ${{fromJson(steps.get_board_json.outputs.boardJson).esptool.chip}} merge_bin \ |
| 119 | + --flash_mode ${{fromJson(steps.get_board_json.outputs.boardJson).esptool.flashMode}} \ |
| 120 | + --flash_freq ${{fromJson(steps.get_board_json.outputs.boardJson).esptool.flashFreq}} \ |
| 121 | + --flash_size ${{fromJson(steps.get_board_json.outputs.boardJson).esptool.flashSize}} \ |
| 122 | + -o wippersnapper.${{ matrix.arduino-platform }}.fatfs.${{ env.WS_VERSION }}.combined.bin \ |
| 123 | + ${{ matrix.offset }} wippersnapper.${{ matrix.arduino-platform }}.fatfs.${{ env.WS_VERSION }}.bootloader.bin \ |
| 124 | + 0x8000 wippersnapper.${{ matrix.arduino-platform }}.fatfs.${{ env.WS_VERSION }}.partitions.bin \ |
| 125 | + 0xe000 wippersnapper.${{ matrix.arduino-platform }}.fatfs.${{ env.WS_VERSION }}.boot_app0.bin \ |
| 126 | + 0x10000 wippersnapper.${{ matrix.arduino-platform }}.fatfs.${{ env.WS_VERSION }}.bin |
| 127 | + - name: Zip build artifacts |
| 128 | + run: | |
| 129 | + zip -r wippersnapper.${{ matrix.arduino-platform }}.fatfs.${{ env.WS_VERSION }}.zip wippersnapper.${{ matrix.arduino-platform }}.fatfs.${{ env.WS_VERSION }}.* |
| 130 | + - name: upload build artifacts zip |
| 131 | + uses: actions/upload-artifact@v3 |
| 132 | + with: |
| 133 | + name: build-files |
| 134 | + path: | |
| 135 | + wippersnapper.${{ matrix.arduino-platform }}.fatfs.${{ env.WS_VERSION }}.zip |
| 136 | + - name: Rename build artifacts to reflect the platform name |
| 137 | + run: | |
| 138 | + mv examples/*/build/*/Wippersnapper_demo.ino.uf2 wippersnapper.${{ matrix.arduino-platform }}.${{ env.WS_VERSION }}.uf2 |
| 139 | + - name: upload build artifacts |
| 140 | + uses: actions/upload-artifact@v3 |
| 141 | + with: |
| 142 | + name: build-files |
| 143 | + path: | |
| 144 | + wippersnapper.${{ matrix.arduino-platform }}.${{ env.WS_VERSION }}.uf2 |
| 145 | +
|
| 146 | +
|
15 | 147 | build-esp32sx:
|
16 | 148 | name: Build WipperSnapper ESP32-Sx
|
17 | 149 | runs-on: ubuntu-latest
|
18 | 150 | strategy:
|
19 | 151 | fail-fast: false
|
20 | 152 | matrix:
|
21 |
| - arduino-platform: ["funhouse_noota", "magtag", |
22 |
| - "metroesp32s2", "feather_esp32s2", |
| 153 | + arduino-platform: ["magtag", "metroesp32s2", "feather_esp32s2", |
23 | 154 | "feather_esp32s2_tft", "feather_esp32s2_reverse_tft",
|
24 | 155 | "feather_esp32s3", "feather_esp32s3_4mbflash_2mbpsram",
|
25 | 156 | "feather_esp32s3_tft", "qtpy_esp32s3",
|
|
0 commit comments