module cy4(I, Y);
input [3:0] I;
output reg[2:0]Y;
wire [3:0] I;
always @(I)
begin
case(I)
4'b0001: Y <= 2'b00;
4'b0010: Y <= 2'b01;
4'b0100: Y <= 2'b10;
4'b1000: Y <= 2'b11;
default:;
endcase
end
endmodule
4线-2线优先编码器
猜你喜欢
转载自blog.csdn.net/qq_41982581/article/details/82469168
今日推荐
周排行