1 |
4 |
bbeaver |
// This directory contains files which are too small to be projects in themselves.
|
2 |
|
|
//
|
3 |
|
|
// Examples of such files might be:
|
4 |
|
|
// prototype copyright files
|
5 |
|
|
// parameterizable cell libraries
|
6 |
|
|
// files which implement some interesting low-level function
|
7 |
|
|
// files which are used as components in several projects
|
8 |
|
|
//
|
9 |
|
|
// Each file should be self-documenting so that a quick glance would serve
|
10 |
|
|
// to explain what it is and why it is here.
|
11 |
|
|
//
|
12 |
|
|
// As a courtesy, each file could also have a small entry here to make it
|
13 |
|
|
// easy to browse the directory looking for interesting stuff.
|
14 |
|
|
//
|
15 |
6 |
bbeaver |
// "opencores_copyright.v" is an example of a copyright file one might
|
16 |
|
|
// include to control the use and abuse of a file stored in this web site.
|
17 |
|
|
//
|
18 |
4 |
bbeaver |
// "synchronizer_flop.v" is a behaviorial description of a 1-bit flop.
|
19 |
|
|
// It should be manually instantiated in EACH AND EVERY MODULE which
|
20 |
|
|
// uses a flop to synchronize a signal from one clock domain to another.
|
21 |
|
|
// In real use, the user of this file will generate a simulation module
|
22 |
|
|
// which will behave like a normal flop when presented with 1, 0, X, or Z.
|
23 |
|
|
// This special-purpose module will NOT have setup and hold tests. It will
|
24 |
|
|
// NOT convert a valid value into an X due to setup timing being violated.
|
25 |
|
|
// This module makes it possible to simulate gate-level netlists with
|
26 |
|
|
// multiple clock domains without fear of making inappropriate X's.
|
27 |
|
|
//
|
28 |
6 |
bbeaver |
// "grey_to_binary.v" is an example of code which takes a binary number
|
29 |
|
|
// and converts it to grey code, and vice versa.
|
30 |
|
|
// This module has a parameter which describes how wide the operands
|
31 |
|
|
// are.
|
32 |
|
|
// This module does not use for-loops to generate the functions. Instead,
|
33 |
|
|
// it manually does the translation for widths up to 16 bits.
|
34 |
|
|
// If the user wants fewer bits, the synthesis tool removes the extra.
|
35 |
|
|
//
|
36 |
7 |
bbeaver |
// "plesiochronous_fifo.v" is an example of a FIFO which transfers packets
|
37 |
|
|
// between two clock domains.
|
38 |
|
|
// The clocks are REQUIRED to be close to one-another in frequency.
|
39 |
|
|
// The Writer is REQUIRED to skip writes every so often, to make sure that
|
40 |
|
|
// the FIFO doesn't overflow.
|
41 |
|
|
// This file instantiates the synchronizer_flop mentioned above.
|
42 |
|
|
//
|
43 |
8 |
bbeaver |
// "hamming_ecc_64.v" is an example of how to use 8 bits of redundant data to
|
44 |
|
|
// correct single-bit errors and detect double-bit errors in 64 bits of data.
|
45 |
|
|
// There are probably better ways to reorder the terms to reduce loads, and
|
46 |
|
|
// to change the formulas to detect a larger percentage of likely errors.
|
47 |
|
|
//
|
48 |
4 |
bbeaver |
|
49 |
7 |
bbeaver |
|