From 6b49bb1e116702a300c896af7aa6e7793e1d4a20 Mon Sep 17 00:00:00 2001 From: Kelvin Ly Date: Sun, 5 Jan 2020 15:17:28 -0500 Subject: [PATCH] Get ice timing reporting working --- rtl/.gitignore | 1 + rtl/Makefile | 5 +++-- rtl/bldc.v | 6 +++--- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/rtl/.gitignore b/rtl/.gitignore index ca64527..a18e158 100644 --- a/rtl/.gitignore +++ b/rtl/.gitignore @@ -1,3 +1,4 @@ *.asc *.bin *.json +*.rpt diff --git a/rtl/Makefile b/rtl/Makefile index 5100818..6a140b8 100644 --- a/rtl/Makefile +++ b/rtl/Makefile @@ -15,12 +15,13 @@ ${FN}.json: ${FN}.v ${FN}.asc: ${FN}.json ${FN}.pcf nextpnr-ice40 ${NEXTPNR_OPTS} --pcf "${FN}.pcf" --json "${FN}.json" --asc "${FN}.asc" -#${FN}.rpt: ${FN}.pcf ${FN}.txt -# icetime $ICETIME_OPTS -p "${FN}.pcf" -mtr "${FN}.rpt" "${FN}.txt" +${FN}.rpt: ${FN}.pcf ${FN}.asc + icetime ${ICETIME_OPTS} -p "${FN}.pcf" -mtr "${FN}.rpt" "${FN}.asc" ${FN}.bin: ${FN}.asc icepack ${FN}.asc ${FN}.bin +timing: ${FN}.rpt clean: rm ${FN}.json ${FN}.asc ${FN}.bin ${FN}_filled.bin diff --git a/rtl/bldc.v b/rtl/bldc.v index 4de35f1..ceb3799 100644 --- a/rtl/bldc.v +++ b/rtl/bldc.v @@ -3,11 +3,11 @@ module bldc ( output if_int ); -reg tmp = 0; -assign if_int = tmp; +reg [3:0] tmp = 0; +assign if_int = tmp[3]; always @(posedge clk) begin - tmp <= ~tmp; + tmp <= tmp + 1; end endmodule