66 strategy :
77 fail-fast : false
88 matrix :
9- os : [ubuntu-latest, windows-latest, macos-14 ]
9+ os : [ubuntu-latest, windows-latest, macos-15 ]
1010 runs-on : ${{ matrix.os }}
1111 steps :
1212 - name : Checkout PicoRVD
13- uses : actions/checkout@v3
13+ uses : actions/checkout@v6
1414 with :
1515 path : PicoRVD
1616
17- - name : Checkout pico-sdk/1.5.1
18- uses : actions/checkout@v3
17+ - name : Checkout pico-sdk/2.2.0
18+ uses : actions/checkout@v6
1919 with :
2020 repository : raspberrypi/pico-sdk
21- ref : 1.5.1
21+ ref : 2.2.0
2222 path : pico-sdk
2323
2424 - name : Checkout pico-sdk submodules
@@ -29,21 +29,64 @@ jobs:
2929 if : ${{ matrix.os == 'windows-latest' }}
3030 working-directory : ${{github.workspace}}/PicoRVD
3131 run : choco install .github/workflows/choco_packages.config
32+
33+ - name : Download and setup libusb
34+ if : ${{ matrix.os == 'windows-latest' }}
35+ shell : bash
36+ run : |
37+ echo "Downloading libusb..."
38+ wget https://github.com/libusb/libusb/releases/download/v1.0.29/libusb-1.0.29.7z -O libusb.7z
39+ echo "Extracting libusb..."
40+ 7z x libusb.7z -oC:/libusb -y
41+
42+ echo "Cloning picotool..."
43+ git clone https://github.com/raspberrypi/picotool.git --branch 2.2.0 --depth 1 C:/picotool-src
44+
45+ echo "Building picotool with libusb support..."
46+ mkdir C:/picotool-src/build
47+ cd C:/picotool-src/build
48+
49+ # Configure picotool with explicit libusb paths
50+ cmake -G "Ninja" \
51+ -DCMAKE_BUILD_TYPE=Release \
52+ -DPICO_SDK_PATH="${{github.workspace}}/pico-sdk" \
53+ -DLIBUSB_LIBRARIES="C:/libusb/MinGW64/dll/libusb-1.0.dll.a" \
54+ -DLIBUSB_INCLUDE_DIR="C:/libusb/include/libusb-1.0" \
55+ ..
56+
57+ # Build
58+ ninja
59+
60+ # Verify picotool was built
61+ if [ ! -f "picotool.exe" ]; then
62+ echo "ERROR: picotool.exe was not built!"
63+ exit 1
64+ fi
65+
66+ # Create deployment directory
67+ mkdir -p C:/picotool-bin
68+
69+ # Copy picotool executable and required DLL
70+ cp picotool.exe C:/picotool-bin/
71+ cp C:/libusb/MinGW64/dll/libusb-1.0.dll C:/picotool-bin/
72+
73+ # Add to PATH for subsequent steps
74+ echo "C:/picotool-bin" >> $GITHUB_PATH
3275
3376 - name : Install dependencies (Linux)
3477 if : ${{ matrix.os == 'ubuntu-latest' }}
3578 run : sudo apt-get update && sudo apt-get install -y build-essential git cmake gcc-arm-none-eabi gcc-riscv64-unknown-elf
3679
3780 - name : Install dependencies (Mac)
38- if : ${{ matrix.os == 'macos-14 ' }}
81+ if : ${{ matrix.os == 'macos-15 ' }}
3982 run : |
4083 brew install cmake make
4184 brew install gcc-arm-embedded
4285 brew tap riscv-software-src/riscv
4386 brew install riscv-tools
4487
4588 - name : Build Project (CH32V003 Blinky)
46- if : ${{ matrix.os == 'ubuntu-latest' || matrix.os == 'macos-14 ' }}
89+ if : ${{ matrix.os == 'ubuntu-latest' || matrix.os == 'macos-15 ' }}
4790 working-directory : ${{github.workspace}}/PicoRVD
4891 shell : bash
4992 run : |
65108
66109 - name : Upload UF2 File
67110 if : ${{ matrix.os == 'ubuntu-latest' }}
68- uses : actions/upload-artifact@v3
111+ uses : actions/upload-artifact@v6
69112 with :
70113 name : PicoRVD.uf2
71114 path : ${{github.workspace}}/PicoRVD/bin/picorvd.uf2
0 commit comments