[ch7]VerilogHDL行为语句

上传人:宝路 文档编号:47978112 上传时间:2018-07-07 格式:PPT 页数:57 大小:1.57MB
返回 下载 相关 举报
[ch7]VerilogHDL行为语句_第1页
第1页 / 共57页
[ch7]VerilogHDL行为语句_第2页
第2页 / 共57页
[ch7]VerilogHDL行为语句_第3页
第3页 / 共57页
[ch7]VerilogHDL行为语句_第4页
第4页 / 共57页
[ch7]VerilogHDL行为语句_第5页
第5页 / 共57页
点击查看更多>>
资源描述

《[ch7]VerilogHDL行为语句》由会员分享,可在线阅读,更多相关《[ch7]VerilogHDL行为语句(57页珍藏版)》请在金锄头文库上搜索。

1、Verilog HDL 行为语句电 子 信 息 通 信 学 科27 Verilog HDL 行为为 语语 句类别语句可综合性过程语句InitialalwaysOK块语句串行块 begin-endOK并行块fork-join赋值语句持续赋值 assignOK过程赋值 =,b) f b) f c) f b) f ; / 无端口列表端口及数据类类型声明语语句;其他语语句; endtask例: module test (a,b,code,c)input 3:0 a,b; input 1:0 code;output reg 4:0 c;task add;input 3:0 a,b;output 4:0

2、out;integer i;beginfor (i=3; i=0;i=i-1)out i = aiend endtaskalways (a or b or code) . endmodule577.7 任务与务与 函数数 (函数数)function使用格式: function 函数名;端口声明;局部变变量定义义;其他语语句; endfunction例: module test (in1,in2,out);input in1, in2;output out;assign out = EXOR_FUNC (in1,in2);function EXOR_FUNC;input in1, in2;if (in1in2) EXOR_FUNC = 1;else EXOR_FUNC = 0; endfunctionendmodule

展开阅读全文
相关资源
正为您匹配相似的精品文档
相关搜索

最新文档


当前位置:首页 > 中学教育 > 教学课件

电脑版 |金锄头文库版权所有
经营许可证:蜀ICP备13022795号 | 川公网安备 51140202000112号