//五位并转串
module paraller2serial(
input clk,
input rst_n,
input [4:0] data_in,
input en,
output data_out
);
reg [4:0] data;
always @ (posedge clk or negedge rst_n)
begin
if(!rst_n)
data <=5'd0;
else if (en)
data <= data_in;
else
data <= data << 1;
end
assign data_out = data[4];
endmodule
最后
以上就是醉熏巨人最近收集整理的关于并转串-Verilog的全部内容,更多相关并转串-Verilog内容请搜索靠谱客的其他文章。
本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
发表评论 取消回复