summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHenry Cook2015-10-12 11:46:07 -0700
committerHenry Cook2015-10-12 11:46:07 -0700
commita95c922b904ed6c564f1b19f75337128c9cd0d1f (patch)
tree320c26aa2e2559fd40d5f3843c0f0bbc2659878d
parent6a5a13e20fcf41fd146d05cc72ef2cea54757568 (diff)
parent37bfa06ae7e1dba3c55a1da84b9390d347446953 (diff)
Merge pull request #15 from ucb-bar/readme
Update README with Mem(seqRead) -> SeqMem()
-rw-r--r--README.md15
1 files changed, 15 insertions, 0 deletions
diff --git a/README.md b/README.md
index 12423672..3fe2130b 100644
--- a/README.md
+++ b/README.md
@@ -17,6 +17,21 @@ modifications are:
val wire = Wire(Bits(width = 15))
```
+ - Sequential memories:
+ ```
+ val addr = Reg(UInt())
+ val mem = Mem(UInt(width=8), 1024, seqRead = true)
+ val dout = when(enable) { mem(addr) }
+ ```
+ becomes (in Chisel3):
+ ```
+ val addr = UInt()
+ val mem = SeqMem(1024, UInt(width=8))
+ val dout = mem.read(addr, enable)
+ ```
+ Notice the address register is now internal to the SeqMem(), but the data
+ will still return on the subsequent cycle.
+
## Getting Started
### Overview