diff --git a/.github/workflows/cron.yml b/.github/workflows/cron.yml deleted file mode 100644 index 117ca8361..000000000 --- a/.github/workflows/cron.yml +++ /dev/null @@ -1,39 +0,0 @@ -name: Cron Build - -on: - schedule: -# ┌───────────── minute (0 - 59) -# │ ┌───────────── hour (0 - 23) -# │ │ ┌───────────── day of the month (1 - 31) -# │ │ │ ┌───────────── month (1 - 12 or JAN-DEC) -# │ │ │ │ ┌───────────── day of the week (0 - 6 or SUN-SAT) -# │ │ │ │ │ -# │ │ │ │ │ -# │ │ │ │ │ -# * * * * * - - cron: '0 */6 * * *' - -jobs: - run: - name: Build with IDF ${{ matrix.idf_branch }} - runs-on: ubuntu-latest - - strategy: - matrix: - idf_branch: [release/v4.4] #, release/v3.3] - steps: - - uses: actions/checkout@v1 - - name: Install dependencies - run: bash ./tools/prepare-ci.sh - - name: Build - env: - GITHUB_TOKEN: ${{ secrets.PUSH_TOKEN }} - GIT_AUTHOR_EMAIL: ${{ secrets.PUSH_EMAIL }} - GIT_COMMITTER_EMAIL: ${{ secrets.PUSH_EMAIL }} - IDF_BRANCH: ${{ matrix.idf_branch }} - run: bash ./tools/cron.sh - - name: Upload archive - uses: actions/upload-artifact@v1 - with: - name: artifacts - path: dist diff --git a/.gitignore b/.gitignore index 18043de7e..b74965aea 100644 --- a/.gitignore +++ b/.gitignore @@ -1,7 +1,8 @@ .DS_Store .vscode components/arduino/ -components/esp-face/ +components/esp-dl/ +components/esp-sr/ components/esp32-camera/ components/esp_littlefs/ components/esp-rainmaker/ diff --git a/build.sh b/build.sh index e66c36b09..fb53e375b 100755 --- a/build.sh +++ b/build.sh @@ -97,9 +97,22 @@ if [ "$BUILD_TYPE" != "all" ]; then print_help fi configs="configs/defconfig.common;configs/defconfig.$TARGET" + + # Target Features Configs + for target_json in `jq -c '.targets[]' configs/builds.json`; do + target=$(echo "$target_json" | jq -c '.target' | tr -d '"') + if [ "$TARGET" == "$target" ]; then + for defconf in `echo "$target_json" | jq -c '.features[]' | tr -d '"'`; do + configs="$configs;configs/defconfig.$defconf" + done + fi + done + + # Configs From Arguments for conf in $CONFIGS; do configs="$configs;configs/defconfig.$conf" done + echo "idf.py -DIDF_TARGET=\"$TARGET\" -DSDKCONFIG_DEFAULTS=\"$configs\" $BUILD_TYPE" rm -rf build sdkconfig idf.py -DIDF_TARGET="$TARGET" -DSDKCONFIG_DEFAULTS="$configs" $BUILD_TYPE @@ -121,7 +134,12 @@ for target_json in `jq -c '.targets[]' configs/builds.json`; do fi echo "* Target: $target" + + # Build Main Configs List main_configs="configs/defconfig.common;configs/defconfig.$target" + for defconf in `echo "$target_json" | jq -c '.features[]' | tr -d '"'`; do + main_configs="$main_configs;configs/defconfig.$defconf" + done # Build IDF Libs idf_libs_configs="$main_configs" diff --git a/configs/defconfig.common b/configs/defconfig.common index 68135c3a8..67ee16fb1 100644 --- a/configs/defconfig.common +++ b/configs/defconfig.common @@ -1,2 +1,3 @@ CONFIG_AUTOSTART_ARDUINO=y CONFIG_ARDUINO_UDP_RUN_CORE0=y +# CONFIG_WS2812_LED_ENABLE is not set \ No newline at end of file diff --git a/configs/defconfig.esp32 b/configs/defconfig.esp32 index 447b45021..82e013c82 100644 --- a/configs/defconfig.esp32 +++ b/configs/defconfig.esp32 @@ -75,6 +75,8 @@ CONFIG_SPI_FLASH_ERASE_YIELD_DURATION_MS=10 CONFIG_SPI_FLASH_ERASE_YIELD_TICKS=2 CONFIG_SPI_FLASH_WRITE_CHUNK_SIZE=4096 CONFIG_ULP_COPROC_ENABLED=y +# CONFIG_USE_WAKENET is not set +# CONFIG_USE_MULTINET is not set # CONFIG_VFS_SUPPORT_SELECT is not set # CONFIG_VFS_SUPPRESS_SELECT_DEBUG_OUTPUT is not set # CONFIG_VFS_SUPPORT_TERMIOS is not set diff --git a/configs/defconfig.opi_flash b/configs/defconfig.opi similarity index 100% rename from configs/defconfig.opi_flash rename to configs/defconfig.opi diff --git a/configs/defconfig.opi_ram b/configs/defconfig.opi_ram index 8e157ad01..16e6a278c 100644 --- a/configs/defconfig.opi_ram +++ b/configs/defconfig.opi_ram @@ -1 +1,3 @@ -CONFIG_SPIRAM_MODE_OCT=y \ No newline at end of file +CONFIG_SPIRAM_MODE_OCT=y +CONFIG_SPIRAM_IGNORE_NOTFOUND=y +# CONFIG_SPIRAM_MEMTEST is not set \ No newline at end of file diff --git a/configs/defconfig.qio_ram b/configs/defconfig.qio_ram new file mode 100644 index 000000000..902680b3a --- /dev/null +++ b/configs/defconfig.qio_ram @@ -0,0 +1 @@ +# CONFIG_SPIRAM_BOOT_INIT is not set \ No newline at end of file diff --git a/tools/copy-libs.sh b/tools/copy-libs.sh index 8e19c23e6..0c06f4b2b 100755 --- a/tools/copy-libs.sh +++ b/tools/copy-libs.sh @@ -196,7 +196,7 @@ for item; do add_next=0 is_script=0 is_dir=0 - elif [[ "${item:0:23}" != "-mfix-esp32-psram-cache" && "${item:0:18}" != "-fmacro-prefix-map" ]]; then + elif [[ "${item:0:23}" != "-mfix-esp32-psram-cache" && "${item:0:18}" != "-fmacro-prefix-map" && "${item:0:17}" != "-Wl,--start-group" && "${item:0:15}" != "-Wl,--end-group" ]]; then LD_FLAGS+="$item " PIO_LD_FLAGS+="$item " fi @@ -359,6 +359,7 @@ for item; do done fi done +echo " join(FRAMEWORK_DIR, \"tools\", \"sdk\", \"$IDF_TARGET\", env.BoardConfig().get(\"build.arduino.memory_type\", \"$MEMCONF\"), \"include\")," >> "$AR_PLATFORMIO_PY" echo " join(FRAMEWORK_DIR, \"cores\", env.BoardConfig().get(\"build.core\"))" >> "$AR_PLATFORMIO_PY" echo " ]," >> "$AR_PLATFORMIO_PY" echo "" >> "$AR_PLATFORMIO_PY" @@ -383,7 +384,7 @@ done echo " LIBPATH=[" >> "$AR_PLATFORMIO_PY" echo " join(FRAMEWORK_DIR, \"tools\", \"sdk\", \"$IDF_TARGET\", \"lib\")," >> "$AR_PLATFORMIO_PY" echo " join(FRAMEWORK_DIR, \"tools\", \"sdk\", \"$IDF_TARGET\", \"ld\")," >> "$AR_PLATFORMIO_PY" -echo " join(FRAMEWORK_DIR, \"tools\", \"sdk\", \"$IDF_TARGET\", \"$MEMCONF\")" >> "$AR_PLATFORMIO_PY" +echo " join(FRAMEWORK_DIR, \"tools\", \"sdk\", \"$IDF_TARGET\", env.BoardConfig().get(\"build.arduino.memory_type\", \"$MEMCONF\"))" >> "$AR_PLATFORMIO_PY" echo " ]," >> "$AR_PLATFORMIO_PY" echo "" >> "$AR_PLATFORMIO_PY" @@ -473,7 +474,8 @@ echo "#define CONFIG_ARDUINO_IDF_COMMIT \"$IDF_COMMIT\"" >> "$AR_SDK/include/con echo "#define CONFIG_ARDUINO_IDF_BRANCH \"$IDF_BRANCH\"" >> "$AR_SDK/include/config/sdkconfig.h" # Handle Mem Variants -mkdir -p "$AR_SDK/$MEMCONF" +mkdir -p "$AR_SDK/$MEMCONF/include" +mv "$AR_SDK/include/config/sdkconfig.h" "$AR_SDK/$MEMCONF/include/sdkconfig.h" for mem_variant in `jq -c '.mem_variants_files[]' configs/builds.json`; do file=$(echo "$mem_variant" | jq -c '.file' | tr -d '"') out=$(echo "$mem_variant" | jq -c '.out' | tr -d '"') diff --git a/tools/copy-mem-variant.sh b/tools/copy-mem-variant.sh index c7b4765e2..b9366ad75 100755 --- a/tools/copy-mem-variant.sh +++ b/tools/copy-mem-variant.sh @@ -21,9 +21,14 @@ source ./tools/config.sh echo "IDF_TARGET: $IDF_TARGET, MEMCONF: $MEMCONF" +# Add IDF versions to sdkconfig +echo "#define CONFIG_ARDUINO_IDF_COMMIT \"$IDF_COMMIT\"" >> "build/config/sdkconfig.h" +echo "#define CONFIG_ARDUINO_IDF_BRANCH \"$IDF_BRANCH\"" >> "build/config/sdkconfig.h" + # Handle Mem Variants rm -rf "$AR_SDK/$MEMCONF" -mkdir -p "$AR_SDK/$MEMCONF" +mkdir -p "$AR_SDK/$MEMCONF/include" +mv "build/config/sdkconfig.h" "$AR_SDK/$MEMCONF/include/sdkconfig.h" for mem_variant in `jq -c '.mem_variants_files[]' configs/builds.json`; do file=$(echo "$mem_variant" | jq -c '.file' | tr -d '"') src=$(echo "$mem_variant" | jq -c '.src' | tr -d '"')