FPGA常见错误汇总

quartus错误:
1:Error (10170): Verilog HDL syntax error at add_and_counter.v(1) near text “_counter”; expecting “;”
解决方法:要保持工程名和文件名一致。
2.Error (10028): Can’t resolve multiple constant drivers for net “ca_out_flag” at CA_code_gen.v(65)
问题:不能在两个以上always内对同一变量赋值
解决方法:将另外一个always语句里的变量移到另一个always中去,使用同一个always。
相关链接:http://blog.csdn.net/jiaou1/article/details/46127865
3.Error (10158): Verilog HDL Module Declaration error at clkseg.v(1): port “XXXX” is not declared as port
问题:没有定义端口,没有input 端口
解决方法:在程序前面定义端口
4.Error (10278): Verilog HDL Port Declaration error at add_and_counter.v(12): input port “b” cannot be declared with type “<a variable data type, e.g. reg>”
问题:如图一在输入端,定义了input b,但是又定义了reg b,输入不能是reg型的,所以不能采用这种方式定义输入的位宽,应该用图二。
在这里插入图片描述在这里插入图片描述
图一 图二

解决方法:重新将仿真文件添加到quartus中去,重新编译,重新仿真,注意文件名没有.v
6. Error (10149): Verilog HDL Declaration error at B1C.v(9): identifier “address_a” is already declared in the present scope
问题: address_a重复定义了
解决方法:删掉一个定义就可以了
7. (1) Error (10170): Verilog HDL syntax error at LED_test.v(3) near text “input”; expecting “;”
解决方法:module LED_test()后面要加分号,即module LED_test();
(2) Error (10170): Verilog HDL syntax error at dpram_test.v(17) near text “else”; expecting “end”
解决方法:在对应模块找“;”,多一个;或者少一个;。
8. 问题
在这里插入图片描述
解决方法如下:重新在quartus中添加modelism的安装路径
在这里插入图片描述
9.Error (10200): ****Verilog HDL Conditional Statement error at key_led.v(64): cannot match operand(s) in the condition to the corresponding edges in the enclosing event control of the always construct
解决方法:
在使用多个if并列语句时,应该采用begin…end来区分,如下图的例子,图一就是导致这种错误的原因,而图二是解决办法。
在这里插入图片描述 在这里插入图片描述
图一 图二
10. Error (10149): Verilog HDL Declaration error at fsm.v(14): identifier “check_X” is already declared in the present scope
问题:在使用parameter定义多个参数时,没有用,将各个参数分开,而是用;分开,所以出错。
解决方法:将分号改为逗号,但最后一个参数要用分号。
11.问题:modelism仿真中,没有错误也没有波形,连stop都没有。
解决方法:查看下是否在setting中加载了.vt文件。一般都是因为没有加载.vt文件导致的,如果有,重新加载下或者重新生成个.vt文件,重新加载。
12. Error (10231): Verilog HDL error at RS232.v(44): value cannot be assigned to input “baud_set”。
问题:对输入进行赋值,将输入当成了reg型
解决方法:不能对输入进行赋值,可以在输入后面加一个寄存器,改变寄存器的赋值。
13. Error (12153): Can’t elaborate top-level user hierarchy
问题:将输出端口定义为reg型,但是并没有将其初始化,而是直接输出。
eg:output reg uart_state;
在这里插入图片描述在这里插入图片描述
图一就是出错的原因,图二是解决办法。
14.复位时,只能有一个条件完成,不能同时多个条件复位,多余的条件只能采用else if完成。相关链接:
https://www.altera.com.cn/support/support-resources/knowledge-base/solutions/rd06242003_6128.html
eg:图一是错误的设计方式,图二是正确的
在这里插入图片描述在这里插入图片描述
图一 图二
15. Error (12007): Top-level design entity “acq_test” is undefined
问题:顶层模块的module名没有和工程名同名
解决方法:把顶层模块 module名改成和工程名同名
16. Error (10663): Verilog HDL Port Connection error at dpram_test.v(30): output or inout port “q” must be connected to a structural net expression.
问题:在调用IP核时,没有将连接输出端q的值定义wire型
解决方法:把q对应的连接值定义为wire型
17:QuartusII安装后没有代码的自动补全功能
在这里插入图片描述
18. Error (10228): Verilog HDL error at rom_top.v(1): module “rom_top” cannot be declared more than once
问题:在文件夹里多了这个文件,所以系统不知道编译哪个
解决方法:删掉多余的文件即可
19.Warning: Some pins have incomplete I/O assignments. Refer to the I/O Assignment Warnings report for details
解决方法:top层有些管脚没有绑定到FPGA管脚上,打开绑管脚界面,仔细看看
或者解决查看问题的步骤如下图:

链接如下:http://www.xuebuyuan.com/408804.html
还有一些常见的警告:http://bbs.elecfans.com/jishu_218429_1_1.html
20. Error (10149): Verilog HDL Declaration error at key_led_top.v(16): identifier “send” is already declared in the present scope
问题:send重复定义,是由于图一中的例化模块中的名称与我定义的连线重复了,改成图二即可。若将输出的结果同时作为其他几个相同模块的输入,直接连线。
在这里插入图片描述在这里插入图片描述
图一 图二
21.Error(15065):Clock input port inclk[0] of PLL “ip_pll:ip_pll_inst|altpll:altpll_component|ip_pll_altpll:auto_generated|pll1” must be driven by a non-inverted input pin or another PLL, optionally through a Clock Control block
Info (15024): Input port INCLK[0] of node “ip_pll:ip_pll_inst|altpll:altpll_component|ip_pll_altpll:auto_generated|pll1” is not connected
问题:使用pll时,输入端clk和module的clk不匹配
22. Quartus版本不同引起ip核出错的错误
在这里插入图片描述
解决方法:将对应的ip核的.qip文件删掉,然后再重新编译生成一个新的.qip文件即可。
具体见网址:https://blog.csdn.net/qq_39696716/article/details/88765383
23. Error (176310): Can’t place multiple pins assigned to pin location Pin_F16 (IOPAD_X53_Y21_N14)
解决方法:assignments->device->device and pin options->dual-purpose pins里面把nCEO设置成use as regular i/o就可以了
具体见网址:https://blog.csdn.net/qq_39696716/article/details/89107663
24. Error (12006): Node instance “uart_speed_tx” instantiates undefined entity “uart_speed_select”
问题:没有把文件添加到工程里,导致调用不到,双击工程里的file可以添加文件
25. Error (10170): Verilog HDL syntax error at rd_fifo_inst.v(1) near text “(”; expecting “;”
问题:将例化文件添加到file里了,删掉就可以了
26. 在这里插入图片描述
27. Error (13076): The pin “pre_syn.bp.gpmc_inst_mcu_rdata_0_” has multiple drivers due to the non-tri-state driver “channel:channel_generate[4].channel_1|mcu_rdata[0]”
问题:同一根线被多根线驱动,所以换成其他线就可以了
modelism仿真错误:

  1. Error: F:/xiaomeige/pause_key/rtl/key_test.v(24): (vlog-2730) Undefined variable: ‘count_flag’.
    问题:寄存器没有定义
    解决:在quartus中可以先使用寄存器,然后再定义,但是在modelism中,必须先定义再使用。所以为了避免这种错误,一定要定义寄存器在使用的前面。
    2.调用模块时,在写例化文件,一定要注意每个端口位数是不是保持一致。否则会出现下面的问题:

从例化文件可以看出:a_t是和a连接的,但是仿真结果中可以看出,由于a_t是8位,而a是一位,所以从a_t传数据到a会出错。
3. Error: C:/Users/DELL/Desktop/ask/prj/ask.v(26): (vopt-2912) Port ‘clk’ not found in module ‘signal_gen’ (1st connection).
问题:
解决方法:input端的clk和模块里用到的时钟名称不一样,改成一致就可以了。
4. Error: C:/Users/DELL/Desktop/new_test/uart_bte_rx_tb.v(46): Module ‘uart_tx’ is not defined.
问题:modelism没有加载到例化的模块“uart_tx”
解决方法:关闭modelism,重新打开即可。
5.modelism仿真中,出现下面的情况:#Error loading design上面的错误是没有找到激励文件
在这里插入图片描述

  • 38
    点赞
  • 179
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值