Skip to content

Commit

Permalink
Release v2.1.0
Browse files Browse the repository at this point in the history
- I2S Audio
- TFT Support
  • Loading branch information
xrip committed Jan 10, 2024
1 parent a201b24 commit a4c167b
Show file tree
Hide file tree
Showing 2 changed files with 81 additions and 78 deletions.
155 changes: 79 additions & 76 deletions .github/workflows/BuildAndRelease.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,95 +2,98 @@ name: Build and create a release when tag is pushed

# Only deploy when a new tag is pushed
on:
push:
tags:
- "v*.*-alpha"
- "v*.*.*"
# branches: [ master ]
# pull_request:
# branches: [ master ]
push:
tags:
- "v*.*-alpha"
- "v*.*.*"
# branches: [ master ]
# pull_request:
# branches: [ master ]

# Must match the project() name in CMakeLists.txt
env:
APP_NAME: dendy
APP_NAME: dendy

# Allow this workflow to write back to the repository
permissions:
contents: write
contents: write

# Build binary and send to releases
jobs:
build-release:
runs-on: ubuntu-latest
name: Build and release
steps:

- name: Install dependencies
run: |
sudo apt update && \
sudo apt install -y git python3 && \
sudo apt install -y cmake gcc-arm-none-eabi libnewlib-arm-none-eabi build-essential libusb-1.0-0-dev && \
sudo apt install -y ninja-build
- name: Check out this repository
uses: actions/checkout@v3
build-release:
runs-on: ubuntu-latest
name: Build and release
steps:

- name: Install dependencies
run: |
sudo apt update && \
sudo apt install -y git python3 && \
sudo apt install -y cmake gcc-arm-none-eabi libnewlib-arm-none-eabi build-essential libusb-1.0-0-dev && \
sudo apt install -y ninja-build
- name: Print Working directory
run: echo $HOME && pwd && ls -la
- name: Check out this repository
uses: actions/checkout@v3

- name: Update line containing pico_set_program_version() in CMakelists.txt with tag name.
run: |
# Extract the tag name that triggered the event and remove the 'refs/tags/' prefix
input_string=${{ github.ref }}
prefix="refs/tags/"
tag="No versioninfo found"
if [[ $input_string == $prefix* ]]; then
echo "The string starts with 'refs/tags/'."
tag="${input_string#$prefix}"
echo "Tag is ${tag}"
sed -i "s/^[[:space:]]*pico_set_program_version(.*/pico_set_program_version(${{ env.APP_NAME }} \"$tag\")/" CMakeLists.txt
else
echo "The string does not start with 'refs/tags/'."
fi
grep "pico_set_program_version" CMakeLists.txt
- name: Install Pico SDk
run: |
cd $HOME && \
git clone https://github.com/raspberrypi/pico-sdk.git --branch master && \
cd pico-sdk/ && \
git submodule update --init && \
cd lib/tinyusb &&
git checkout 08f9ed67c92421cbd0bc09270d2f363886681866
- name: Print Working directory
run: echo $HOME && pwd && ls -la

- name: Install picotool
run: |
cd $HOME && \
export PICO_SDK_PATH=$HOME/pico-sdk && \
git clone https://github.com/raspberrypi/picotool.git --branch master && \
cd picotool/ && \
mkdir build && \
cd build && \
cmake -G Ninja .. && \
cmake --build .
- name: Update line containing pico_set_program_version() in CMakelists.txt with tag name.
run: |
# Extract the tag name that triggered the event and remove the 'refs/tags/' prefix
input_string=${{ github.ref }}
prefix="refs/tags/"
tag="No versioninfo found"
if [[ $input_string == $prefix* ]]; then
echo "The string starts with 'refs/tags/'."
tag="${input_string#$prefix}"
echo "Tag is ${tag}"
sed -i "s/^[[:space:]]*pico_set_program_version(.*/pico_set_program_version(${{ env.APP_NAME }} \"$tag\")/" CMakeLists.txt
else
echo "The string does not start with 'refs/tags/'."
fi
grep "pico_set_program_version" CMakeLists.txt
- name: Build the project
run: |
export PICO_SDK_PATH=$HOME/pico-sdk && \
mkdir build && cd build && \
cmake -G Ninja -DCMAKE_BUILD_TYPE=MinSizeRel .. && cmake --build . &&\
cmake -G Ninja -DCMAKE_BUILD_TYPE=MinSizeRel -DI2S_SOUND=ON .. && cmake --build . &&\
cmake -G Ninja -DCMAKE_BUILD_TYPE=MinSizeRel -DTFT=ON .. && cmake --build . &&\
cmake -G Ninja -DCMAKE_BUILD_TYPE=MinSizeRel -DTFT=ON -DILI9341=ON .. && cmake --build . &&\
echo done
- name: Install Pico SDk
run: |
cd $HOME && \
git clone https://github.com/raspberrypi/pico-sdk.git --branch master && \
cd pico-sdk/ && \
git submodule update --init && \
cd lib/tinyusb &&
git checkout 08f9ed67c92421cbd0bc09270d2f363886681866
- name: Install picotool
run: |
cd $HOME && \
export PICO_SDK_PATH=$HOME/pico-sdk && \
git clone https://github.com/raspberrypi/picotool.git --branch master && \
cd picotool/ && \
mkdir build && \
cd build && \
cmake -G Ninja .. && \
cmake --build .
- name: Build the project
run: |
export PICO_SDK_PATH=$HOME/pico-sdk && \
mkdir build && cd build && \
cmake -G Ninja -DCMAKE_BUILD_TYPE=MinSizeRel .. && cmake --build . &&\
cmake -G Ninja -DCMAKE_BUILD_TYPE=MinSizeRel -DTFT=ON .. && cmake --build . &&\
cmake -G Ninja -DCMAKE_BUILD_TYPE=MinSizeRel -DTFT=ON -DILI9341=ON .. && cmake --build . &&\
cmake -G Ninja -DCMAKE_BUILD_TYPE=MinSizeRel -DI2S_SOUND=ON .. && cmake --build . &&\
cmake -G Ninja -DCMAKE_BUILD_TYPE=MinSizeRel -DTFT=ON .. && cmake --build . &&\
cmake -G Ninja -DCMAKE_BUILD_TYPE=MinSizeRel -DTFT=ON -DILI9341=ON .. && cmake --build . &&\
echo done
- name: Create release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
files: |
bin/MinSizeRel/**.uf2
- name: Create release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
files: |
bin/MinSizeRel/**.uf2
body_path: CHANGELOG.md
body_path: CHANGELOG.md


4 changes: 2 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# v2.1.0
- I2S Audio support PCM5102
- TFT Displays support: ILI9341/ST7789
- I2S Audio support PCM5102 CS4334
- TFT Displays support: ILI9341 ST7789
- Fixes and optimizations

# v2.0.0
Expand Down

0 comments on commit a4c167b

Please sign in to comment.