|
1 | 1 | .. _SVIF: |
2 | 2 |
|
3 | 3 | SVIF |
4 | | -====== |
| 4 | +==== |
5 | 5 |
|
6 | 6 | Description |
7 | 7 | ^^^^^^^^^^^ |
8 | 8 |
|
9 | | -The ``SVIF`` type specifically targets system Verilog designs.This type extends from ``Bundle``.When generating Verilog or VHDL, the behavior of this type is exactly the same as that of ``Bundle``.However, when generating System Verilog and enabling the ``svInterface`` option in SpinalConfig, this type will be generated as an Interface. |
| 9 | +The ``SVIF`` type specifically targets system Verilog designs. This type extends from ``Bundle``. When generating Verilog or VHDL, the behavior of this type is exactly the same as that of ``Bundle``. However, when generating System Verilog and enabling the ``svInterface`` option in SpinalConfig, this type will be generated as an ``Interface``. |
10 | 10 |
|
11 | | -This type is still an experimental feature |
| 11 | +This type is still an experimental feature. |
12 | 12 |
|
13 | 13 | Declaration |
14 | 14 | ^^^^^^^^^^^ |
@@ -76,9 +76,9 @@ Parameter |
76 | 76 | .. code-block:: scala |
77 | 77 |
|
78 | 78 | case class Color(channelWidth: Int) extends SVIF { |
79 | | - val width = addGeneric("WIDTH", channelWidth)// or addParameter |
| 79 | + val width = addGeneric("WIDTH", channelWidth) // or addParameter |
80 | 80 | val r, g, b = UInt(channelWidth bits) |
81 | | - tieGeneric(r, width)// or tieParameter |
| 81 | + tieGeneric(r, width) // or tieParameter |
82 | 82 | tieGeneric(g, width) |
83 | 83 | tieGeneric(b, width) |
84 | 84 |
|
@@ -110,7 +110,7 @@ Parameter |
110 | 110 | def slv = asSlave |
111 | 111 | } |
112 | 112 |
|
113 | | -this will generate system verilog code as below: |
| 113 | +This will generate system verilog code as below: |
114 | 114 |
|
115 | 115 | .. code-block:: scala |
116 | 116 |
|
@@ -163,9 +163,9 @@ this will generate system verilog code as below: |
163 | 163 | Definition Name |
164 | 164 | ~~~~~~~~~~~~~~~ |
165 | 165 |
|
166 | | -you can use ``setDefinitionName`` to set the definition name. But remember to use it before any clone of this interface |
| 166 | +You can use ``setDefinitionName`` to set the definition name. But remember to use it before any clone of this interface. |
167 | 167 |
|
168 | 168 | Not Interface |
169 | 169 | ~~~~~~~~~~~~~ |
170 | 170 |
|
171 | | -If you have used a certain interface in multiple places, and at one of those locations ``sigA``, you wish to flatten it instead of generating an interface, you can achieve this by calling ``sigA.notSVIF()`` to fully flatten the signal. If the signal has nested interfaces and you only want to expand the outermost layer, you can use ``sigA.notSVIFthisLevel()``. |
| 171 | +If you have used a certain interface in multiple places, and at one of those locations ``mySignal``, you wish to flatten it instead of generating an interface, you can achieve this by calling ``mySignal.notSVIF()`` to fully flatten the signal. If the signal has nested interfaces and you only want to expand the outermost layer, you can use ``mySignal.notSVIFthisLevel()``. |
0 commit comments