初学Verilog , 辛苦仿真了好久的代码, 等到准备烧写时,发现无法给input 定义的导线分配引脚.
自己折腾了1天,最后终于找到了原因 .
代码一定要像下面这样写.
/* synthesis syn_force_pads = 1 */
在引脚变量的上面加个定义. 告诉综合工具 , 不要把这个变量给优化掉了.
如果还是不行, 试试新建工程. 把代码复制过去.
下面是官网搜到的一点相关内容,
How to set the behavior of unused pins in an FPGA design? These are some of the workarounds:-**
- In RTL code, assign the following attributes to the unused input:
/* synthesis syn_force_pads=1 syn_noprune = 1 */
The ‘syn_noprune’ will not allow Synplify Pro to optimize unconnected I/O buffers and will increase resource utilization. So, as per your design requirement, it may or may not be used.
- Under Strategy1 make the following setting:
MAP Design–> Command line options = -u
This ensures that the Mapper does not remove the unused I/Os. - In spreadsheet view, make pull mode =NONE