nix: rewire configure-fpga command

This commit is contained in:
occheung 2020-09-17 13:19:23 +08:00
parent c084da1848
commit 537a375f2c
3 changed files with 6 additions and 5 deletions

View File

@ -2,4 +2,5 @@ init
reset init
halt
flash write_image erase target/thumbv7em-none-eabihf/debug/examples/ethernet
reset run
shutdown

View File

@ -2,4 +2,5 @@ init
reset init
halt
flash write_image erase target/thumbv7em-none-eabihf/debug/examples/fpga_config
reset run
shutdown

View File

@ -40,14 +40,13 @@ let
'';
flashFPGAConfig = writeShellScriptBin "flash-fpga-config" ''
set-gdb-config-file "fpga_config" && cargo run --example fpga_config
openocd-flash fpga-config
'';
configureFPGA = writeShellScriptBin "configure-fpga" ''
nc -zv localhost 3333 \
&& compile-migen-script \
&& flash-fpga-config \
|| echo "Please run OpenOcd first."
compile-migen-script \
&& cargo build --example fpga_config \
&& flash-fpga-config
'';
verifyFPGAConfig = writeShellScriptBin "verify-fpga-config" ''