GUI模式
$ /opt/td/bin/td -gui
New Project
EG4 EG4S20B256
New Source
main.v
module main(clk, led); input clk; output reg led; reg [25:0] clk_cnt; initial begin led = 0; clk_cnt = 0; end always @(posedge clk) begin clk_cnt = clk_cnt + 1; if (clk_cnt > 24000000) begin clk_cnt = 0; led = ~led; end end endmodule
存檔
New
main.adc
set_pin_assignment { clk } { location = k14; } set_pin_assignment { led } { location = r3; }
存檔
添加ADC
main.adc
Run
Download
燒錄頁面
接著滑鼠點一下main.bit,讓Run按鈕可以顯示
按下Run下載
P.S. 如果要燒錄到Flash記憶體,Mode要改成PROGRAM FLASH
完成