ISE——demo
2021-05-20 本文已影响0人
静一下1
新建项目
型号与器件对应

新建Source 选择Verilog Module

写一个led的demo
按下复位键灯亮

module led(
input clk,
input rst_n,
output reg led_out
);
always@(posedge clk or negedge rst_n)
if(!rst_n)
led_out<=1;
else
led_out<=0;
endmodule
新建约束:

net clk LOC=R8;
net rst_n LOC=B8;
net led_out LOC=A8;

clk 对应的管脚为R8
rst_n对应的管脚为B8


遇到了错误




仿真


仿真结果
led_out 和 rst_n相反
