用quartus的MegaWizard工具生成一个乘法器multiplier,会在工程目录下产生

multiplier.qip    (可选)

multiplier_bb.v  (可选)

multiplier.v

文件。

Multiplier.v 文件的内容

// megafunction wizard: %LPM_MULT%

// GENERATION: STANDARD

// VERSION: WM1.0

// MODULE: lpm_mult

// ============================================================

// File Name: multiplier.v

// Megafunction Name(s):

//                       lpm_mult

//

// Simulation Library Files(s):

//                       lpm

// ============================================================

// ************************************************************

// THIS IS A WIZARD-GENERATED FILE. DO NOT EDIT THIS FILE!

//

// 10.0 Build 262 08/18/2010 SP 1 SJ Full Version

// ************************************************************

//Copyright (C) 1991-2010 Altera Corporation

//Your use of Altera Corporation's design tools, logic functions

//and other software and tools, and its AMPP partner logic

//functions, and any output files from any of the foregoing

//(including device programming or simulation files), and any

//associated documentation or information are expressly subject

//to the terms and conditions of the Altera Program License

//Subscription Agreement, Altera MegaCore Function License

//Agreement, or other applicable license agreement, including,

//without limitation, that your use is for the sole purpose of

//programming logic devices manufactured by Altera and sold by

//Altera or its authorized distributors.  Please refer to the

//applicable agreement for further details.

// synopsys translate_off

`timescale 1 ps / 1 ps

// synopsys translate_on

module multiplier (

clock,

dataa,

datab,

result);

input           clock;

input         [7:0]  dataa;

input         [7:0]  datab;

output      [15:0]  result;

wire [15:0] sub_wire0;

wire [15:0] result = sub_wire0[15:0];

lpm_mult lpm_mult_component (

.clock (clock),

.dataa (dataa),

.datab (datab),

.result (sub_wire0),

.aclr (1'b0),

.clken (1'b1),

.sum (1'b0));

defparam

lpm_mult_component.lpm_hint = "MAXIMIZE_SPEED=5",

lpm_mult_component.lpm_pipeline = 2,

lpm_mult_component.lpm_representation = "UNSIGNED",

lpm_mult_component.lpm_type = "LPM_MULT",

lpm_mult_component.lpm_widtha = 8,

lpm_mult_component.lpm_widthb = 8,

lpm_mult_component.lpm_widthp = 16;

endmodule

生成的模块multiplier 只是在实例化lpm_mult模块的基础上,根据MegaWizard的配置结果,用defparam对该模块内部的对应的参数进行了更改。因此,如果对要使用的模块比较熟练的话,更方便一点的做法是不用MegaWizard进行配置,而是直接按照这种方法用hdl语言来对乘法模块进行调用。

最新文章

  1. 开源WinForms界面开发框架Management Studio 选项卡文档 插件 Office 2007蓝色风格 后台线程
  2. LESS 学习记录(简单入门)
  3. xcrun: error: active developer path ("/Volumes/Xcode/Xcode-beta.app/Contents/Developer") does not exist, use `xcode-select --swi
  4. ASP.NET Session的七点认识
  5. 三,对于printf函数和C语言编程的初步拓展
  6. jQuery 定位锚点
  7. bzoj1812 [Ioi2005]riv
  8. selenium基本操作
  9. MySQL Block Nested Loop and Batched Key Access Joins(块嵌套循环和批量Key访问连接)
  10. typedef和#define的简单比较
  11. JavaOOP-集合框架
  12. centos7搭建gitlab服务器、汉化
  13. shell编程学习笔记(八):Shell中的if条件判断
  14. 解决org.apache.ibatis.binding.BindingException: Invalid bound statement (not found)错误
  15. Python3学习之路~5.12 hashlib & hmac & md5 & sha模块
  16. 如何发布自己的node模块
  17. 源码管理工具Git-客户端GitBash常用命令
  18. ubuntu compile openjdk87
  19. 用COS实现文件上传
  20. Docker数据管理(四)

热门文章

  1. PHP 多参数方法的重构
  2. anaconda+jupyter notebook 安装配置
  3. python——PIL(图像处理库)
  4. INSERT⋯ACCEPTING_DUPLICATE_KEYS
  5. 9.3centos7安装python3 以及tab补全功能
  6. Androd安全——混淆技术完全解析
  7. 5-1 练习css 总结
  8. CSS3 loading效果全
  9. virtualenv简介以及一个比较折腾的scrapy安装方法
  10. b树的实现