The Elements of Computing
Systems / Nisan & Schocken / www.idc.ac.il/tecs
Project 3: Sequential Chips
Objective: Build all the chips described in Chapter 3. The only building blocks that you can use are primitive DFF gates, chips that you will build on top of them, and chips described in previous chapters.
Resources: The
only tool needed for this project is the hardware simulator supplied with
the book. All the chips should be implemented in the HDL language specified in
appendix A. As usual, for each chip we supply a skeletal .hdl program with a missing
implementation part, a .tst script file that tells the
hardware simulator how to test it, and a .cmp
compare file. Your job is to complete the missing implementation parts of all
the supplied
.hdl programs.
Contract: When loaded into the Hardware Simulator, your chip design (modified .hdl
program), tested on the supplied .tst
file, should produce the outputs listed in the supplied .cmp
file. If that is not the case, the simulator will let you know.
Chip (HDL) |
Function |
Test script |
Compare file |
DFF | Data Flip-Flop (primitive) | ||
Bit | 1-bit binary cell | Bit.tst | Bit.cmp |
Register | 16-bit Register | Register.tst |
Register.cmp |
RAM8 | 16-bit / 8-register memory | RAM8.tst |
RAM8.cmp |
RAM64 | 16-bit / 64-register memory | RAM64.tst |
RAM64.cmp |
RAM512 | 16-bit / 512-register memory | RAM512.tst |
RAM512.cmp |
RAM4K | 16-bit / 4096-register memory | RAM4K.tst |
RAM4K.cmp |
RAM16K | 16-bit / 16384-register memory | RAM16K.tst |
RAM16K.cmp |
PC | 16-bit Program Counter | PC.tst |
PC.cmp |
The Data Flip-Flop (DFF) gate is considered primitive and thus there is no need to build it: when the simulator encounters a DFF gate in an HDL program, it automatically invokes the built-in tools/builtInChips/DFF.hdl implementation.
The directory structure of
this project:
When constructing RAM chips
from smaller RAM chips, we recommend using built-in versions of the latter.
Otherwise, the simulator may run very slowly or even out of (real) memory space,
since large RAM chips contain tens of thousands of lower level chips, and all
these chips are kept in memory (as software objects) by the simulator. For this
reason, we have placed
the RAM512.hdl, RAM4K.hdl, and RAM16K.hdl programs in a separate directory.
Steps: We recommend proceeding
in the following order:
0.
The hardware simulator needed for this project is available in the
tools directory of the book’s software suite;
1. Read Appendix A (Hardware
Description Language), focusing on sections 6 and 7;
2. Go through the Hardware Simulator Tutorial , focusing on parts IV and V;
3. Create a directory named projects/03 on your computer and extract project 03.zip to it (while preserving the directory structure embedded in the zip file). Build and simulate all the specified chips.