2021年3月26日 星期五

DE2-115 開發 以 74138解碼器 為例(Verilog data flow modeling )

 DE2-115 開發 以 74138解碼器 為例(Verilog  data flow modeling )  

參考來源https://www.programmersought.com/article/34964783614/





// 74138 decoder

module Decoder_3x8_74138(SW,LEDR );

input [17:0] SW;

output [17:0] LEDR;

x74138(SW[15:13],SW[2:0],LEDR[7:0]);

endmodule

module x74138(En, I, O);

    input wire[2:0] En;   //active enable=[100]

    input wire[2:0] I;

    output wire[7:0] O;

                  

    assign O = (En==3'b100) ? ~(8'b0000_0001 << I) : 8'b0000_0000;

 endmodule 

沒有留言:

張貼留言

RFID TI 培訓影片系列

RFID TI 培訓影片系列  https://www.ti.com/zh-tw/video/series/rfid.html 培訓影片系列 RFID 隨著創新技術日益發展,RFID 和 RF 術語越來越容易讓人混淆。本訓練系列詳細介紹了使用案例、權衡技術優缺點,讓您清楚知道該選...