diff --git a/ov0/src/main/scala/oppgavetekst.org b/oppgavetekst.org similarity index 98% rename from ov0/src/main/scala/oppgavetekst.org rename to oppgavetekst.org index 9a38af6..b32271f 100644 --- a/ov0/src/main/scala/oppgavetekst.org +++ b/oppgavetekst.org @@ -179,12 +179,15 @@ else dataOut(T - vectorLength) #+end_src - From the figure the principle of operation becomes clearer [inkskape drawing, rm sketch] + From the figure the principle of operation becomes clearer To test your implementation you can run sbt> testOnly Core.daisyVecSpec in your sbt console +#+CAPTION: A vector with 4 registers +[[./tdt4255figs/pngs/vector.png]] + ** Task 2 - Dot Product Your next task is to implement a dot product calculator. daisyDot should calculate the dot product of two vectors, inA and inB. Ensure that validOut diff --git a/ov0/src/main/scala/daisyMatMul.scala b/ov0/src/main/scala/daisyMatMul.scala index 8fd65d7..cfd7fe0 100644 --- a/ov0/src/main/scala/daisyMatMul.scala +++ b/ov0/src/main/scala/daisyMatMul.scala @@ -57,7 +57,6 @@ class daisyMultiplier(dims: Dims, dataWidth: Int) extends Module { matrixB.dataIn := io.dataInB matrixB.writeEnable := io.writeEnableB - //////////////////////////////////////// //////////////////////////////////////// /// Set up counter statemachine diff --git a/tdt4255figs/pngs/vector.png b/tdt4255figs/pngs/vector.png new file mode 100644 index 0000000..489a5e4 Binary files /dev/null and b/tdt4255figs/pngs/vector.png differ diff --git a/tdt4255figs/vector.svg b/tdt4255figs/vector.svg new file mode 100644 index 0000000..59286b5 --- /dev/null +++ b/tdt4255figs/vector.svg @@ -0,0 +1,1410 @@ + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + 0 + 0 + 0 + 0 + 4 + 0 + + + + + + + + + 4 + 0 + 0 + 0 + 3 + 0 + + + + + + + + + 4 + 3 + 8 + 0 + 1 + 0 + + + + + + + + + 4 + 3 + 0 + 0 + 8 + 0 + + + + + + + + + + + 4 + 3 + 8 + 1 + 0 + 4 + + + + + + + + + 0 + 3 + 8 + 1 + 0 + 3 + + + + + + + + + 0 + 0 + 0 + 1 + 0 + 1 + + + + + + + + + 0 + 0 + 8 + 1 + 0 + 8 + + + + + + + + + + + 4 + 3 + 8 + 1 + 0 + 4 + + + + + + + + + 4 + 3 + 8 + 1 + 0 + 3 + + + + + + + + + 4 + 3 + 8 + 1 + 0 + 1 + + + + + + + + + 4 + 3 + 8 + 1 + 0 + 8 + + + Write enabled + Write disabled + Write enabled + +