數位系統實驗 Experiment on Digital System Lab05: IC design flow and FPGA Introduction to Verilog HDL 負責助教:葉俊顯 stanley.

Slides:



Advertisements
Similar presentations
Verilog Intro: Part 1.
Advertisements

2010/12/12
FCU, Department of ECE, IC Design Research Lab. TEL: # 4945 Pre-SIm , Post-Sim.
布林代數的應用--- 全及項(最小項)和全或項(最大項)展開式
Introduction to Java Programming Lecture 13 Classes I OO Programming.
如何將數字變成可用之資訊 現代化資料處理與應用概念. 如何將數字變成可用之資訊 人最容易接受的訊息是圖像化資訊。 在一堆數字中,要進行比較分析,一般會使用表格形 式計算與分析。 所以一般我們會將數字依關聯性, 轉換成表格計算與分析。 此表格一般稱試算表或稱表格。 再將結果轉換為圖表,進行比較與分析。
小綠人行人用交通號誌燈 指導教授:黃朝章 學生:951408陳宜歆 徐祐祥.
SIP Mobiity TA: 洪敏書
1 Web of Science 利用指引 單元二 瀏覽與處理查詢結果. 2 瀏覽檢索結果 查出的結果,預設以時間排列, 使用者可改變結果的排列方式: 還可以依被引用次數、相關度、 第一作者、刊名、出版年等排序 回到前先查的結果畫面 點選想看資料的完整書目 本館訂購範圍的期刊 全文,便可直接連結.
五小專案 黃詩晴 章乃云. 目錄 計算機 智慧盤 拼圖 記憶大挑戰 數學題庫 心得 參考文獻.
邏輯設計 題目:3_8解碼器 姓名:李國豪 學號:B09322001.
1 Chapter 4 如何建立自己的元件庫 由現有的電路圖建一符號元件 如何將建立的符號元件在別的專案中使 用 先建立符號元件再設計內部電路 壹位元全加法器之設計 二位元全加法器之設計.
1 實驗二 : SIP User Mobility 實驗目的 藉由 Registra 和 Redirect Server 的設計,深入瞭解 SIP 的運 作及訊息格式。 實作部分 ( 1 )實作一個 Registrar 來接收 SIP REGISTER ,而且 要將 REGISTER 中 Contact.
國立聯合大學 資訊管理學系 陳士杰老師 MySQL5 視覺化資料庫管理工具 - MySQL Adminstrator.
各種線上電子資源的特異功能 STICnet 的 SDI 專題訂閱服務 2003/4/28 修改. 無論校內外皆可使用。連線至
MS-DOS 作業系統 張基昇 (Microsoft-Disk Operating System).
Department of Air-conditioning and Refrigeration Engineering/ National Taipei University of Technology 模糊控制設計使用 MATLAB 李達生.
VHDL 邏輯設計 題目:一對十六解多工器 題目:一對十六解多工器 姓名:李國豪 姓名:李國豪 學號:B09322001 學號:B09322001.
管理科學導論 解決問題與制定決策 計量分析與制定決策 計量分析 計量分析模型 MS/OR方法與應用範圍 1-1.
奶酪專賣店系統 組員: B 林家榕 B 莊舜婷.
JAVA 程式設計與資料結構 第十章 GUI Introdution III. File Chooser  File Chooser 是一個選擇檔案的圖形介面, 無論我們是要存檔還是要開啟檔案,使 用這個物件都會讓我們覺得容易且舒適。
國立中山大學財產管理系統 線上報廢、盤點系統 總務處保管組 策劃 計算機與網路中心 分析設計 2008/03.
長訊科技 EVRCOM Voice Mail System 使用者操作說明及流程. 自動總機 -- 來電語音轉接服務流程 ( 範例流程 )
Failure Candidate Identification for Silicon Debug 指導教授:林榮彬 教授 李婉如 許智涵.
Introduction to Java Programming Lecture 17 Abstract Classes & Interfaces.
: The largest Clique ★★★★☆ 題組: Contest Archive with Online Judge 題號: 11324: The largest Clique 解題者:李重儀 解題日期: 2008 年 11 月 24 日 題意: 簡單來說,給你一個 directed.
最新計算機概論 第 5 章 系統程式. 5-1 系統程式的類型 作業系統 (OS) : 介於電腦硬體與 應用軟體之間的 程式,除了提供 執行應用軟體的 環境,還負責分 配系統資源。
: Fast and Easy Data Compressor ★★☆☆☆ 題組: Problem Set Archive with Online Judge 題號: 10043: Fast and Easy Data Compressor 解題者:葉貫中 解題日期: 2007 年 3.
各種線上電子資源的特異功能 SwetsWise 的 alert, TOC alert 與 Favorites 2003/4/28 修改.
行政院國家科學委員會工程技術發展處自動化學門 * 試以國立成功大學製造工程研究所 鄭芳田教授 產學合作計畫 : 智慧預測保養系統之設計與實作 成果報告盤點為範例 國科會工程處專題計畫成果典藏 自動化學門成果報告盤點範例.
生產系統導論 生產系統簡介 績效衡量 現代工廠之特徵 管理機能.
從此處輸入帳號密碼登入到管理頁面. 點選進到檔案管理 點選「上傳檔案」上傳資料 點選瀏覽選擇電腦裡的檔案 可選擇公開或不公開 為平台上的資料夾 此處為檔案分類,可顯示在展示頁面上,若要參加 MY EG 競賽,做品一律上傳到 “ 98 MY EG Contest ” 點選此處確定上傳檔案.
資料結構實習-一 參數傳遞.
6-2 認識元件庫與內建元件庫 Flash 的元件庫分兩種, 一種是每個動畫專 屬的元件庫 (Library) ;另一種則是內建元 件庫 (Common Libraries), 兩者皆可透過 『視窗』功能表來開啟, 以下即為您說明。
法律系 系所科助之血淚辛酸史 劉蕙綺. 系上推行困難處 ( 學期初 ) 傳統習慣:法律系以教科書為主 很多老師沒有電子檔案 專、兼任老師使用平台的意願 因老師多為資深老師,因此在使用電腦部 份可能比較需要幫助 通常學生知道訊息的來源是藉由 BBS 或者 是系上的系板,使用意願會降低.
1 Introduction to Java Programming Lecture 2: Basics of Java Programming Spring 2008.
Management Abstracts Retrieval System; MARS 檢索操作.
: A-Sequence ★★★☆☆ 題組: Problem Set Archive with Online Judge 題號: 10930: A-Sequence 解題者:陳盈村 解題日期: 2008 年 5 月 30 日 題意: A-Sequence 需符合以下的條件, 1 ≤ a.
Image Interpolation Use SSE 指導教授 : 楊士萱 學 生 : 楊宗峰 日 期 :
2010 MCML introduction 製作日期: 2010/9/10 製作人 : 胡名霞.
845: Gas Station Numbers ★★★ 題組: Problem Set Archive with Online Judge 題號: 845: Gas Station Numbers. 解題者:張維珊 解題日期: 2006 年 2 月 題意: 將輸入的數字,經過重新排列組合或旋轉數字,得到比原先的數字大,
Linguistics phonetic symbols. 先下載 IPA 字型檔案,執行安裝。 由於這個程式的字型目錄設定錯誤, 所以等重新開機時就會發現字型消失。 所以必須根據以下步驟來讓 Windows 加入 IPA 字型。
第七章 採購支出循環企業程序與資訊需求 7.1 採購支出循環企業程序 7.2 採購支出循環固有風險與內部控制 7.3 採購支出循環資訊需求
概念性產品企劃書 呂學儒 李政翰.
Probability Distribution 機率分配 汪群超 12/12. 目的:產生具均等分配的數值 (Data) ,並以 『直方圖』的功能計算出數值在不同範圍內出現 的頻率,及繪製數值的分配圖,以反應出該 機率分配的特性。
無線通訊網路 Mac 層 TDM 通訊模式的操作與效能研究 專題生 : 林書弘、蔡逸祥、毛建翔、王政 華 指導教授 : 黃依賢.
組合語言與系統程式 軟體使用教學. 軟體下載及安裝 下載 到課程網頁下載 tw/~jiun/ 安裝 解壓縮後將 System Software 資料夾放在 D 槽 (C 槽版本放在 C 之下 )
1 Introduction to Java Programming Lecture 2: Basics of Java Programming Spring 2009.
計算機概論 第6章 數位邏輯設計.
Use Quartus II Design Procedure 建立項目文件 建立設計文件 軟體模擬 編譯除錯 修改錯誤 源始碼輸入原理圖輸入 選擇晶片,指定接腳 驗證成功 編譯後下載 有錯 無錯 有錯.
ArcINFO &Geodatabase 由 ESRI 產生 1970 ArcINFO 一開始被設計在迷你電 腦上, 後來逐漸發展, 在 UNIX 系統上也能 執行, 直到今天, 已經可以在不同的平台上 運作.
Teacher : Ing-Jer Huang TA : Chien-Hung Chen 2015/6/30 Course Embedded Systems : Principles and Implementations Weekly Preview Question CH7.1~CH /12/26.
著作權所有 © 旗標出版股份有限公司 第 3 章 資料庫物件的關係. 本章提要 Access 資料庫物件的關係 Access 資料庫物件的關係 簡介 Access 的七大物件 簡介 Access 的七大物件 Access 的群組 Access 的群組.
數位實驗  麵包板實驗 電路板之前 配合各種量測儀器  示波器 (oscillator)  波形產生器 (wave generator)  電源產生器 (power supply)  數位電表 (digital meter)  EDA(Electronic Design Automation)
McGraw-Hill/Irwin © 2003 The McGraw-Hill Companies, Inc.,All Rights Reserved. 壹 企業研究導論.
1 Introduction to Java Programming Lecture 2: Basics of Java Programming Spring 2010.
多媒體技術與應用 實習作業 Part II. 實習作業 利用 Corel Paint Shop Pro X2 完成作業。 作業一:利用影像處理的技巧,讓這張影像變 的更清晰。
數位系統實驗 --課程介紹 教師:潘欣泰.
數位系統實驗 -- 課程介紹 教師:潘欣泰. 課程目標  數位系統導論課程之實習課程  接續數位電路學課程  養成學生動手做的習慣  使學生對數位電路設計有實際的體驗.
著作權所有 © 旗標出版股份有限公司 第 14 章 製作信封、標籤. 本章提要 製作單一信封 製作單一郵寄標籤.
CH 14-可靠度工程之數學基礎 探討重點 失效時間之機率分配 指數模式之可靠度工程.
1 Lab7 Design and Implementation. 2 Design Example.
Digital Integrated Circuit Design Laboratory Department of Computer Science and Information EngineeringNational Cheng Kung University Experiment on Digital.
Registers(暫存器)與Counters(計數器):
SOPC/NIOSII 設計與實作課程 © 2007 Terasic Corporation 1 Hello World 軟 / 硬體實作 硬體實作 軟體實作.
數位系統實驗 Experiment on Digital System Lab06: Verilog HDL and FPGA (2) 負責助教:葉俊顯 stanley.
6-1 基本加法器 6-2 平行二進位加法器 6-3 比較器 6-4 解碼器 6-5 編碼器 6-6 數碼轉換器 6-7 多工器 ( 資料選擇器 ) 6-8 解多工器 6-9 同位元產生器 / 檢 查器.
Chapter1: Introduction Digital System Designs and Practices Using Verilog HDL and 2008~2010, John Wiley 1-1 Chapter 1: Introduction Prof. Ming-Bo.
Verilog Intro: Part 1. Hardware Description Languages A Hardware Description Language (HDL) is a language used to describe a digital system, for example,
1 Lab 2 Module-Based Digital Circuit Design and Verification.
Presentation transcript:

數位系統實驗 Experiment on Digital System Lab05: IC design flow and FPGA Introduction to Verilog HDL 負責助教:葉俊顯 stanley

2015/10/152 Outline IC Design Flow and FPGA Introduction to HDL Write Verilog code using Quartus II Lab

2015/10/153 Outline IC Design Flow and FPGA Introduction to HDL Write Verilog code using Quartus II Lab

2015/10/154 Digital system  數位系統 (digital system) 通常被設計用來實現或完成 某一些特殊的功能需求 MP3 player Mobile phone … 一個數位系統可能包含數個不同功能特質的數位電路, 而數位電路一般是使用所謂的半導體技術實作於積體電路 (Integrated circuit, IC) 上

2015/10/155 IC design flow

2015/10/156 ASIC and FPGA 當設計者完成 RTL(Register Transfer Level) 電路後,若使用製作 功能應用導向晶片 (Application Specific Integrated Circuit , ASIC) 的 EDA tools 來進行合成、模擬、驗證,最後,會產生一個 GDS- II 檔案。最後,可將此檔案委請晶圓廠製成一顆 ASIC 晶片 FPGA/CPLD 是一種可依需要做程式規劃的晶片,其中包含許多 可被使用的 cells ,透過 FPGA 廠商提供的 FPGA-EDA tool 進行合 成、模擬與驗證,最後將所設計的電路燒錄到 FPGA 上面  FPGA (Field Programmable Gate Array) – 本課程所使用  CPLD (Complex Programmable Logic Device)

2015/10/157 FPGA design flow

2015/10/158 Outline IC Design Flow and FPGA Introduction to HDL Write Verilog code using Quartus II Lab

2015/10/159 Introduction to HDL HDL  Hardware description language  Similar to general-purpose languages like C  Modeling and simulation of the functionality of combinational and sequential circuits  Parallel vs. sequential behaviors Two competitive forces  Verilog: C-like language – 本課程所使用  VHDL: ADA-like language

2015/10/1510 Introduction to Verilog HDL C-like syntax/semantics Basic building block  Module Four kinds of model for circuits  Switch Level Model or Transistor Model (npn & pnp …)  Gate Level Model (or & and …)  Data Flow Model (assign)  Behavioral Model (RTL description) begin … end)

2015/10/1511 Design hierarchy

2015/10/1512 Identifier Names of modules, ports, wires and instances are all identifiers First character must be a letter, and other characters can be letters, numbers or underscore ( _ ) Upper case and lower case letters are different

2015/10/1513 Keyword All keywords are defined in lower case

2015/10/1514 Keyword All keywords are defined in lower case

2015/10/1515 Data type net reg parameter

2015/10/1516 Data type - net (wire)

2015/10/1517 Data type - reg A reg data type represents a variable in Verilog Type ”reg” variable stores values, but not necessarily a FF (register) Are only assigned in an ”always” block task or function If a reg data type is assigned a value in an always block that has a clock edge expression, a flip-flop is inferred

2015/10/1518 Data type - reg By default, net and register are one-bit wide

2015/10/1519 Data type - parameter Represents constants Declared by: parameter data_size = 5; Cannot be changed at run time

2015/10/1520 Value Set Verilog has four value levels

2015/10/1521 Operator Priority

2015/10/1522 Module

2015/10/1523 Module - example module half_adder ( x, y, c, s ); // port declaration input x; // width: 1 bit input y; output c, s; // I/O type and data type wire c; wire s; // functionality or structure xor (s, x, y); // (out, in, ……) and (c, x, y); endmodule module name port name Verilog primitive

2015/10/1524 Circuit design using - Four kinds of model Switch Level Model Gate Level Model Data Flow Model Behavioral Model

Example: Half adder 25 module half_adder ( //input x, y, //output c, s ); // port declaration input x; // width: 1 bit input y; output c, s; // I/O type and data type wire c; wire s; // functionality or structure xor (s, x, y); and (c, x, y); endmodule assign s=x^y; assign c=x&y; reg s,c; or y) begin s=x^y; c=x&y; end Data Flow Model Behavioral Model Gate Level Model

Example: Full adder (Gate Level Model) 26 module full_adder (x, y, z, S, C); input x, y, z; output S, C; // internal nets/registers wire wire01; wire wire02; wire wire03; // functionality or structure xor xor01(wire01, x, y); and and01(wire02, x, y); xor xor02(S, wire01, z); and and02(wire03, wire01, z); or (C, wire02, wire03); endmodule

Example: Full adder (2HA+1OR) 27 module full_adder (x, y, z, S, C); input x, y, z; output S, C; wire wire1, wire2, wire3 ; // functionality or structure // module instantiations half_adder ha1( //input.x (x),.y (y), //output.c (wire2),.s (wire1) ); half_adder ha2( //input.x (wire1),.y (z), //output.c (wire3),.s (S) ); or (C, wire2, wire3); endmodule

Instantiation and port mapping 28 In order By name // in half_adder.v half_adder (x, y, c, s); // in full_adder.v half_adder ha1(x, y, wire2, wire1); half_adder ha2(wire1, z, wire3, s); // in half_adder.v half_adder (x, y, c, s); // in full_adder.v half_adder ha1(.x(x),.y(y),.c(wire2),.s(wire1)); half_adder ha2(.x(wire1),.y(z),.s(s),.c(wire3));

2015/10/1529 Outline IC Design Flow and FPGA Introduction to HDL Write Verilog code using Quartus II Lab

Step by Step Getting Started –  Start the Quartus II software 30

31 Create a New Project –  Open New Project Wizard (File → New Project Wizard…) Step by Step

32 Specify the working directory and the name of the project 可先新增資料夾 請記住 ! Step by Step

33 Select design files. Or click “Next” to skip this step Specify device settings - (Here we use the VerLite Device family) EP1C6Q240C8 Step by Step

34 Edit a Schematic File Open a new Verilog HDL file  (File → New → Verilog HDL File → OK) Step by Step

35 Write Verilog code Top module name 一定要跟 Project name 相同 !! Step by Step 輸入 (input) 輸出 (output) 被加數 (a) 加數 (b) 和 (sum) 進位 (carry) : //File Name : Half_Adder.v 2: moduleHalf_Adder(a, b, sum, carry); 3: inputa, b; 4: outputsum, carry; 5: 6: assign sum = a ^ b; 7: assign carry = a & b; 8: 9: endmodule

36 Compiling the Designed Circuit  (Processing → Start Compilation) Step by Step

37 Successful compilation Step by Step

Simulating the Designed Circuit  Using the Waveform Editor (File → New → Vector Waveform File) 38 Step by Step

Simulating the Designed Circuit  Use node finder to find all the pins (Edit → Insert → Insert Node or Bus…) 39 Step by Step

Simulating the Designed Circuit  Selecting nodes to insert into the Waveform Editor Step by Step 40 沒跑出 pin 腳,表示你剛剛忘記 compile

Simulating the Designed Circuit  Selecting nodes to insert into the Waveform Editor Step by Step 41

Simulating the Designed Circuit  Select and edit waveform Step by Step 42

Simulating the Designed Circuit  Setting of test values Step by Step 43

Performing the Simulation  Modify default settings (Assignments → Settings… → Simulator Settings → Functional → OK) Step by Step 44

Generate functional simulation netlist before simulation (Processing → Generate Functional Simulation Netlist) Step by Step 45

Start simulation (Processing → Start Simulation ) Step by Step 46

The result of functional simulation Step by Step 47 輸入 (input) 輸出 (output) 被加數 (a) 加數 (b) 和 (sum) 進位 (carry)

2015/10/1548 Outline IC Design Flow and FPGA Introduction to HDL Write Verilog code using Quartus II Lab

Lab I Using Verilog to implement a 1-bit Full Adder Simulation Result zyxSC

Lab I - Hint Hint (Gate Level Model) 50

Lab II Using Verilog to implement a 2-bit Full Adder Simulation Result z1y1x1C1y2x2S1S2C

Lab II - Hint x1 y1 z1 S1 C1 x2 y2 S2 C2 wire01 wire02 wire03 wire04 wire05 wire06 or01 or02 xor03 xor04 and03 and04 X C1 52 Ref. Instantiation and port mapping

Notice 請勿在桌面建立 Project 及請勿命名中文資料夾 Device family 請確認與 FPGA Chip 符合 (EP1C6Q240C8) Top module name & Project name 需要一致 確認 module … endmodule 為 keyword 變成藍色字體 53