Intel Agilex® 7 エンベデッド・メモリー・ユーザーガイド

ID 683241
日付 4/10/2023
Public

このドキュメントの新しいバージョンが利用できます。お客様は次のことを行ってください。 こちらをクリック 最新バージョンに移行する。

ドキュメント目次

4.3.12. 手動インスタンス化のコーディング例

このセクションでは、DCFIFO のインスタンスを作成する Verilog HDL のコーディング例を示します。これはコンパイルに向けた完全なコーディングではなく、インスタンス化において必要な構造に関するガイドラインといくつかの説明です。同じ構造を使用して他の IP コアをインスタンス化することはできますが、インスタンス化している IP コアに適用可能なポートとパラメーターを使用する場合に限ります。

DCFIFO をインスタンス化する Verilog HDL コーディング例

//module declaration
module dcfifo8x32 (aclr, data, …… ,wfull);
//Module's port declarations
input aclr;
input [31:0] data;
.
.
output wrfull;
//Module’s data type declarations and assignments
wire rdempty_w;
.
.
wire wrfull = wrfull_w; wire [31:0] q = q_w;
/*Instantiates dcfifo megafunction. Must declare all the ports available from
the megafunction and
define the connection to the module's ports.
Refer to the ports specification from the user guide for more information about
the megafunction's
ports*/
//syntax: <megafunction's name> <given an instance name>
dcfifo inst1 (
//syntax: .<dcfifo's megafunction's port>(<module's port/wire>)
.wrclk (wrclk),
.rdclk (rdclk),
.
.
.wrusedw ()); //left the output open if it's not used
/*Start with the keyword “defparam”, defines the parameters and value
assignments. Refer to
parameters specifications from the user guide for more information about the
megafunction's
parameters*/
defparam
//syntax: <instance name>.<parameter> = <value>
inst1.intended_device_family = "Agilex",
inst1.lpm_numwords = 8,
.
.
inst1.wrsync_delaypipe = 4;
endmodule