Skip to content

Commit

Permalink
Merge pull request #178 from tobozo/1.2.4
Browse files Browse the repository at this point in the history
1.2.4
  • Loading branch information
tobozo authored Apr 30, 2023
2 parents 4ce1679 + 389235b commit 011a3db
Show file tree
Hide file tree
Showing 49 changed files with 4,035 additions and 2,167 deletions.
54 changes: 35 additions & 19 deletions .github/workflows/ArduinoBuild.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@ on:
paths:
- '**.ino'
- '**.cpp'
- '**.hpp'
- '**.h'
- '**.c'
- '**ArduinoBuild.yml'
pull_request:
release:
Expand All @@ -13,19 +15,23 @@ on:
jobs:

matrix_build:
name: ${{ matrix.matrix-context }}@${{ matrix.sdk-version }})
name: ${{ matrix.matrix-context }}@${{ matrix.sdk-version }}
runs-on: ubuntu-latest

strategy:
matrix:

sdk-version:
- 1.0.6
#- 1.0.6
#- 2.0.0
#- 2.0.1
# - 2.0.2 # has broken SD Support
- 2.0.3
- 2.0.4
#- 2.0.3
#- 2.0.4
#- 2.0.5
- 2.0.6
- 2.0.7
- 2.0.8

matrix-context:
- M5Core2-test
Expand All @@ -39,26 +45,29 @@ jobs:
- M5Core2
- M5Fire
- OdroidGo
- SdFat-test

exclude:
- sdk-version: 2.0.2 # has broken SD Support
#exclude:
#- sdk-version: 2.0.2 # has broken SD Support
# There's no esp32s3box support before 2.0.3
- { matrix-context: S3Box-Test, sdk-version: 1.0.6 }
#- { matrix-context: S3Box-Test, sdk-version: 1.0.6 }
#- { matrix-context: S3Box-Test, sdk-version: 2.0.0 }
#- { matrix-context: S3Box-Test, sdk-version: 2.0.1 }
#- { matrix-context: S3Box-Test sdk-version: 2.0.2 }
- { matrix-context: S3Box-Test, sdk-version: 2.0.4 } # will be fixed in 2.0.5 https://github.com/espressif/arduino-esp32/pull/6962/files
- { matrix-context: M5Core2-test, sdk-version: 1.0.6 } # M5Core2.h suddenly ceased to support 1.0.6 (I2S and I2C broken)
#- { matrix-context: S3Box-Test, sdk-version: 2.0.4 } # will be fixed in 2.0.5 https://github.com/espressif/arduino-esp32/pull/6962/files
#- { matrix-context: M5Core2-test, sdk-version: 1.0.6 } # M5Core2.h suddenly ceased to support espressif package 1.0.6/2.0.0 (I2S and I2C broken)


include:

# buildable sdk versions
- sdk-version: 1.0.6
#- sdk-version: 1.0.6
#- sdk-version: 2.0.0
#- sdk-version: 2.0.1
- sdk-version: 2.0.3
- sdk-version: 2.0.4
#- sdk-version: 2.0.5
- sdk-version: 2.0.6
- sdk-version: 2.0.7
- sdk-version: 2.0.8

# library health test sketches
- { matrix-context: M5Core2-test, arduino-board: m5stack-core2, sketch-names: M5Core2-SDLoader-Snippet.ino, required-libraries: "M5Core2", ... }
Expand All @@ -67,6 +76,7 @@ jobs:
- { matrix-context: M5Unified-test, arduino-board: m5stack-core2, sketch-names: M5Unified.ino, required-libraries: "M5GFX,M5Unified", ... }
- { matrix-context: M5StickC-test, arduino-board: m5stick-c, sketch-names: M5StickC-SPIFFS-Loader-Snippet.ino, required-libraries: "M5StickC", ... }
- { matrix-context: LGFX-test, arduino-board: m5stack-core-esp32, sketch-names: LGFX-SDLoader-Snippet.ino, required-libraries: "LovyanGFX", ... }
- { matrix-context: SdFat-test, arduino-board: m5stack-core2, sketch-names: SdFatUpdater.ino, required-libraries: "SdFat,M5GFX,M5Unified", ... }

# Launcher and Appstore
- matrix-context: M5Stack
Expand All @@ -93,21 +103,27 @@ jobs:
launcher-name: OdroidGo-Launcher
appstore-name: OdroidGo-AppStore
extra-fqbn: ":PartitionScheme=min_spiffs"
required-libraries: "ESP32-Chimera-Core,LovyanGFX,ArduinoJson,ESP32-targz"
required-libraries: "ESP32-Chimera-Core,LovyanGFX,ArduinoJson,ESP32-targz,Button2"
#- matrix-context: TTGO-LoRa32-V2-test
#arduino-board: ttgo-lora32-v2
#sketch-names: TTGO-test.ino
#required-libraries: "ESP32-Chimera-Core,LovyanGFX,ArduinoJson"
- matrix-context: M5Atom
sdk-version: 2.0.8
arduino-board: m5stack-atom
sketch-names: M5Stack-SD-Menu.ino
launcher-name: M5Atom-Launcher
required-libraries: "ESP32-Chimera-Core,LovyanGFX,ArduinoJson,ESP32-targz,Button2"

fail-fast: false

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
ref: ${{ github.event.pull_request.head.sha }}
- name: ${{ matrix.matrix-context }}
uses: ArminJo/arduino-test-compile@v3
uses: ArminJo/arduino-test-compile@v3.2.0
with:
platform-url: https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_dev_index.json
#platform-url: ${{ matrix.platform-url }}
Expand All @@ -125,9 +141,9 @@ jobs:
if: startsWith(matrix.sketch-names, 'M5Stack-SD-Menu')
run: |
cp examples/M5Stack-SD-Menu/build/M5Stack-SD-Menu.ino.bin examples/M5Stack-SD-Menu/build/${{ matrix.launcher-name }}-${{ matrix.sdk-version }}.bin
cp examples/AppStore/build/AppStore.ino.bin examples/M5Stack-SD-Menu/build/${{ matrix.appstore-name }}-${{ matrix.sdk-version }}.bin
FILE=examples/AppStore/build/AppStore.ino.bin && [ -f "$FILE" ] && cp $FILE examples/M5Stack-SD-Menu/build/${{ matrix.appstore-name }}-${{ matrix.sdk-version }}.bin || true
- name: Upload artifact ${{ matrix.matrix-context }}
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v3
if: startsWith(matrix.sketch-names, 'M5Stack-SD-Menu')
with:
name: ${{ matrix.matrix-context }}
Expand All @@ -142,12 +158,12 @@ jobs:
needs: matrix_build
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
- name: Create artifacts dir
#if: startsWith(github.ref, 'refs/tags/')
run: mkdir -p /home/runner/builds
- name: Download artifacts
uses: actions/download-artifact@v2
uses: actions/download-artifact@v3
#if: startsWith(github.ref, 'refs/tags/')
with:
path: builds
Expand Down
39 changes: 23 additions & 16 deletions .github/workflows/PlatformioBuild.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,22 +35,27 @@ jobs:
- m5stack-core2
- m5unified
- s3box
- m5stack-atom

platform-version:
- 1.0.6
- 2.0.0
- 2.0.1
#- 1.0.6
#- 2.0.0
#- 2.0.1
#- 2.0.2 # has broken SD Support
- 2.0.3
- 2.0.4

exclude:
- { piocontext: s3box, platform-version: 1.0.6 }
- { piocontext: s3box, platform-version: 2.0.0 }
- { piocontext: s3box, platform-version: 2.0.1 }
#- 2.0.3
#- 2.0.4
#- 2.0.5
- 2.0.6
- 2.0.7
- 2.0.8

#exclude:
#- { piocontext: s3box, platform-version: 1.0.6 }
#- { piocontext: s3box, platform-version: 2.0.0 }
#- { piocontext: s3box, platform-version: 2.0.1 }
#- { piocontext: s3box, platform-version: 2.0.2 }
- { piocontext: m5stack-core2, platform-version: 1.0.6 } # M5Core2.h broken I2S support with 1.0.6
- { piocontext: m5stack-core2, platform-version: 2.0.0 } # M5Core2.h broken I2S support with 2.0.0
#- { piocontext: m5stack-core2, platform-version: 1.0.6 } # M5Core2.h broken I2S support with 1.0.6
#- { piocontext: m5stack-core2, platform-version: 2.0.0 } # M5Core2.h broken I2S support with 2.0.0

include:
- piocontext: lgfx
Expand All @@ -64,24 +69,26 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
ref: ${{ github.event.pull_request.head.sha }}

- name: Cache pip
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
- name: Cache PlatformIO
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: ~/.platformio
key: ${{ runner.os }}-${{ hashFiles('**/lockfiles') }}
- name: Set up Python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: '3.9'

- name: Install PlatformIO
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/onrelease.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
ref: master # this must match the main/master branch name !!
- name: Semver-Iterator
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
build
.pio/
.directory
28 changes: 24 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
![Arduino Build](https://github.com/tobozo/M5Stack-SD-Updater/actions/workflows/ArduinoBuild.yml/badge.svg?branch=master)
![Platformio Build](https://github.com/tobozo/M5Stack-SD-Updater/actions/workflows/PlatformioBuild.yml/badge.svg?branch=master)

![Library Downloads](https://img.shields.io/github/downloads/tobozo/M5Stack-SD-Updater/total)

# M5Stack-SD-Updater

<br />
Expand Down Expand Up @@ -36,7 +38,7 @@
<br />

**Micro SD Card (TF Card)** - formatted using FAT32. Max size 32 Gb.
SDCard is recommended but the SDUpdater supports other filesystems such as SD_MMC, SPIFFS, LittleFS and PSRamFS.
SDCard is recommended but the SDUpdater supports other filesystems such as SdFat, SD_MMC and LittleFS (SPIFFS will soon be deprecated).

<br />

Expand All @@ -48,6 +50,8 @@ SDCard is recommended but the SDUpdater supports other filesystems such as SD_MM

- [ArduinoJSON](https://github.com/bblanchon/ArduinoJson/) (Optional, used by SD-Menu).

- [ESP32-targz](https://github.com/tobozo/ESP32-targz) (Optional if using gzipped firmwares)

All those are available in the [Arduino Library Manager](https://www.arduinolibraries.info/libraries/m5-stack-sd-updater) or by performing a [manual installation](https://www.arduino.cc/en/Guide/Libraries#toc5).


Expand Down Expand Up @@ -105,6 +109,7 @@ The snippet of code in the `M5Stack-SDLoader-Snippet.ino` sketch can be used as
And add this after the include:

```C
// #define SDU_ENABLE_GZ // optional: support for gzipped firmwares
#include <M5StackUpdater.h>
```

Expand Down Expand Up @@ -392,11 +397,11 @@ The default SD-Menu application will scan for these file types:

- .bin compiled application binary

- .jpg image/icon (max 200x100)
- .jpg image/icon (max 100x100)

- .json file with dimensions descriptions:

`{"width":128,"height":128,"authorName":"tobozo","projectURL":"http://short.url","credits":"** http://very.very.long.url ~~"}`
`{"width":120,"height":120,"authorName":"tobozo","projectURL":"http://short.url","credits":"** http://very.very.long.url ~~"}`


<br />
Expand Down Expand Up @@ -449,6 +454,19 @@ This can be triggered manually by using `saveSketchToFS(SD, fileName, TFCARD_CS_
#include "M5StackUpdater.h"
```
- Gzipped firmwares are supported when `SDU_ENABLE_GZ` macro is defined or when [ESP32-targz.h](https://github.com/tobozo/ESP32-targz) was previously included.
The firmware must have the `.gz.` extension and be a valid gzip file to trigger the decompression.
```C++
#define SDU_ENABLE_GZ // enable support for gzipped firmwares
#include "M5StackUpdater.h"
void setup()
{
checkSDUpdater( SD, "/menu.gz", 2000 );
}
```


- The JoyPSP and [M5Stack-Faces](https://github.com/m5stack/faces) Controls for M5Stack SD Menu necessary code are now disabled in the menu example but the code stays here and can be used as a boilerplate for any other two-wires input device.

Expand Down Expand Up @@ -500,5 +518,7 @@ This can be triggered manually by using `saveSketchToFS(SD, fileName, TFCARD_CS_
| 👍 | QRCode | Richard Moore | https://github.com/ricmoo/qrcode |
| 👍 | @Reaper7 | Reaper7 | https://github.com/reaper7 |
| 👍 | @PartsandCircuits | PartsandCircuits | https://github.com/PartsandCircuits |
| 👍 | @lovyan03 | らびやん | https://github.com/lovyan03 |
| 👍 | @lovyan03 | らびやん | https://github.com/lovyan03 |
| 👍 | @matsumo | Matsumo | https://github.com/matsumo |
| 👍 | @riraosan | Riraosan | https://github.com/riraosan |
| 👍 | @ockernuts | ockernuts | https://github.com/ockernuts |
2 changes: 1 addition & 1 deletion examples/AppStore/modules/misc/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@
#endif

#if !defined BUTTON_WIDTH
#define BUTTON_HEIGHT 60
#define BUTTON_WIDTH 60
#endif

#if !defined BUTTON_HWIDTH
Expand Down
Loading

0 comments on commit 011a3db

Please sign in to comment.