Skip to content

Commit 7d49e4b

Browse files
nbdd0121AlexJones0
authored andcommitted
[ci] fix CI to select correct device for openFPGALoader
1 parent aaf4ef8 commit 7d49e4b

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

.github/workflows/ci.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ jobs:
150150
151151
- name: Flash bitstream
152152
run: |
153-
nix run .#bitstream-load
153+
DEVICE=/dev/ttySONATA_JTAG_FPGA nix run .#bitstream-load
154154
155155
- name: Run software tests
156156
run: |

nix/bitstream.nix

+5-1
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,11 @@ in {
6161
runtimeInputs = [pythonEnv pkgs.openfpgaloader];
6262
text = ''
6363
BITSTREAM=$(find ./ -type f -name "lowrisc_sonata_system_0.bit")
64-
openFPGALoader -c ft4232 "$BITSTREAM"
64+
if [[ -n "''${DEVICE-}" ]]; then
65+
openFPGALoader -c ft4232 -d "$DEVICE" "$BITSTREAM"
66+
else
67+
openFPGALoader -c ft4232 "$BITSTREAM"
68+
fi
6569
'';
6670
};
6771
}

0 commit comments

Comments
 (0)