集成电路技术分享

 找回密码
 我要注册

QQ登录

只需一步,快速开始

搜索
查看: 2276|回复: 1

求助!

[复制链接]
changcomeon 发表于 2010-10-5 19:31:27 | 显示全部楼层 |阅读模式
module TSL(a,b,cs,L);
   input a,b,cs;
        output L;
        reg L;
        if(cs)
   and and1(L1,a,b);
        not not1(L,L1);
        else
        L=1'bz;
        endmodule
这个代码哪里有问题啊?
ERROR:HDLCompilers:26 - "TSL.v" line 26 expecting 'endmodule', found 'if'
chenliang1116 发表于 2010-10-6 19:33:24 | 显示全部楼层
if语句后面超过1条语句以上需要加begin-end加以顺序执行!
您需要登录后才可以回帖 登录 | 我要注册

本版积分规则

关闭

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

QQ|小黑屋|手机版|Archiver|fpga论坛|fpga设计论坛 ( 京ICP备20003123号-1 )

GMT+8, 2025-4-20 07:18 , Processed in 0.068232 second(s), 21 queries .

Powered by Discuz! X3.4

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表