在线咨询
eetop公众号 创芯大讲堂 创芯人才网
切换到宽版

EETOP 创芯网论坛 (原名:电子顶级开发网)

手机号码,快捷登录

手机号码,快捷登录

找回密码

  登录   注册  

快捷导航
搜帖子
查看: 1308|回复: 0

[求助] 关于verilog

[复制链接]
发表于 2013-6-4 20:19:29 | 显示全部楼层 |阅读模式
30资产
`timescale 1 ns/1 ns
module t(clk,gate_clk,load,count_clr);
input clk,gate_clk;
output load,count_clr;
reg load,count_clr;
reg[5:0] ll;
/*specify
$setup(gate_clk,load,10);
$hold(gate_clk,load,10);
$setup(gate_clk,count_clr,15);
$hold(gate_clk,count_clr,5);
endspecify*/
/*initial
fork
count_clr=0;
load=0;
join*/

always@(posedge clk )
if(gate_clk)
  begin
  ll=0;
  //load=0;
  //count_clr=0;
  end
  else
    begin
    ll=ll+1;
      case(ll)
    6'b000010: load=1; count_clr=0;
     6'b000100: load=0; count_clr=1;
      6'b000110: load=0; count_clr=0;
      default: load=0; count_clr=0;
    endcase
    end
endmodule
大家看下这段代码,由于是初学者对上面的问题不是很懂,大家看看错误在哪里啊,编译老是报错!!!

您需要登录后才可以回帖 登录 | 注册

本版积分规则

关闭

站长推荐 上一条 /2 下一条

小黑屋| 关于我们| 联系我们| 在线咨询| 隐私声明| EETOP 创芯网
( 京ICP备:10050787号 京公网安备:11010502037710 )

GMT+8, 2024-5-24 17:28 , Processed in 0.016734 second(s), 8 queries , Gzip On, Redis On.

eetop公众号 创芯大讲堂 创芯人才网
快速回复 返回顶部 返回列表