Skip to content

Commit

Permalink
Removed usage of case class to maintain consistency (#168)
Browse files Browse the repository at this point in the history
  • Loading branch information
sgandham2 authored Jun 16, 2022
1 parent a064e05 commit d715bba
Showing 1 changed file with 4 additions and 12 deletions.
16 changes: 4 additions & 12 deletions 2.6_chiseltest.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -210,21 +210,13 @@
"metadata": {},
"outputs": [],
"source": [
"case class QueueModule[T <: Data](ioType: T, entries: Int) extends MultiIOModule {\n",
"class QueueModule[T <: Data](ioType: T, entries: Int) extends MultiIOModule {\n",
" val in = IO(Flipped(Decoupled(ioType)))\n",
" val out = IO(Decoupled(ioType))\n",
" out <> Queue(in, entries)\n",
"}"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"> Note the `case` class modifer is not generally required but seems to be in order for\n",
"this example to be re-used in multiple cells in Jupyter"
]
},
{
"cell_type": "markdown",
"metadata": {},
Expand All @@ -249,7 +241,7 @@
"metadata": {},
"outputs": [],
"source": [
"test(QueueModule(UInt(9.W), entries = 200)) { c =>\n",
"test(new QueueModule(UInt(9.W), entries = 200)) { c =>\n",
" // Example testsequence showing the use and behavior of Queue\n",
" c.in.initSource()\n",
" c.in.setSourceClock(c.clock)\n",
Expand Down Expand Up @@ -286,7 +278,7 @@
"metadata": {},
"outputs": [],
"source": [
"test(QueueModule(UInt(9.W), entries = 200)) { c =>\n",
"test(new QueueModule(UInt(9.W), entries = 200)) { c =>\n",
" // Example testsequence showing the use and behavior of Queue\n",
" c.in.initSource()\n",
" c.in.setSourceClock(c.clock)\n",
Expand Down Expand Up @@ -339,7 +331,7 @@
"metadata": {},
"outputs": [],
"source": [
"test(QueueModule(UInt(9.W), entries = 200)) { c =>\n",
"test(new QueueModule(UInt(9.W), entries = 200)) { c =>\n",
" // Example testsequence showing the use and behavior of Queue\n",
" c.in.initSource()\n",
" c.in.setSourceClock(c.clock)\n",
Expand Down

0 comments on commit d715bba

Please sign in to comment.