1 / 10

Verilog HDL

Verilog HDL. 12 月 21 日 ( 月). Verilog HDL とは. シミュレーション言語として生まれる その後、論理合成にも使われるようになる 現在、多くの CAD ツールがサポートしている C 言語に似た簡単で表現力の高い記述言語. 簡単な例から覚えよう. 組合わせ回路( 8bit 加算回路)の記述例です。 Verilog-HDL では、まとまった一つの回路をモジュール( module )と呼びます。 module add8(a, b, s); input [7:0] a, b; output [8:0] s;

lew
Télécharger la présentation

Verilog HDL

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Verilog HDL 12月21日(月)

  2. VerilogHDLとは • シミュレーション言語として生まれる • その後、論理合成にも使われるようになる • 現在、多くのCADツールがサポートしている • C言語に似た簡単で表現力の高い記述言語

  3. 簡単な例から覚えよう • 組合わせ回路(8bit加算回路)の記述例です。 • Verilog-HDLでは、まとまった一つの回路をモジュール(module)と呼びます。 module add8(a, b, s); input [7:0] a, b; output [8:0] s; assign s = a + b; endmodule a add8 8 s 9 b 8

  4. モジュールの書き方 • module ではじまり endmodule で終わる • 回路の名前(モジュール名)を付ける • 入出力信号の名前(ポートリスト)を書く モジュール名 モジュール名 ポートリスト module add8(a, b, s); input [7:0] a, b; output [8:0] s; assign s = a + b; endmodule

  5. 入出力の書き方 • 入力は input • 出力は output • 複数ビット信号は [最上位ビット:最下位ビット] module add8(a, b, s); input [7:0] a, b; output [8:0] s; assign s = a + b; endmodule 入力信号 出力信号

  6. 回路記述本体 • assign は継続的代入文 • 簡単な組合わせ回路を記述するのに使用する module add8(a, b, s); input [7:0] a, b; output [7:0] s; assign s = a + b; endmodule 回路記述本体

  7. 演算子 • 使用できる演算子 + 加算 - 減算  * 掛算 論理合成に使用できない • / 割り算

  8. 回路規模を調べる クリック ダブルクリック Total logic cells used: の部分が使用セル数です。 Total logic cells used: 15/576 ( 2%) 15セルを使っていることがわかる

  9. 演習 • 次の回路をVerilogにより記述し、シミュレーションにより動作を確認せよ。また、回路規模を(使用セル数)比較せよ。 • 8ビット加算器    (8ビット入力 9ビット出力) • 8ビット減算器    (8ビット入力 9ビット出力) • 8ビット乗算器    (8ビット入力 16ビット出力)

  10. 今までの宿題 回路図設計 • フリップフロップ(Lach、D、JK,T)のシミュレーション • 同期式8進カウンタ or 同期式16進カウンタ • 同期式10進カウンタ 言語設計  回路規模も調べてください • 8進カウンタ or 16進カウンタ  • 10進カウンタ • 12進カウンタ • 8ビット加算器   (8ビット入力 9ビット出力) • 8ビット減算器   (8ビット入力 9ビット出力) • 8ビット乗算器   (8ビット入力 16ビット出力)

More Related