Initial commit

This commit is contained in:
2025-11-06 10:08:01 +08:00
commit 0bded5b86e
1033 changed files with 55966 additions and 0 deletions

View File

@@ -0,0 +1,38 @@
`timescale 1ns / 1ps
//////////////////////////////////////////////////////////////////////////////////
// Company:
// Engineer:
//
// Create Date: 2024/09/25 20:35:36
// Design Name:
// Module Name: sim4mux41
// Project Name:
// Target Devices:
// Tool Versions:
// Description:
//
// Dependencies:
//
// Revision:
// Revision 0.01 - File Created
// Additional Comments:
//
//////////////////////////////////////////////////////////////////////////////////
module sim4mux41();
reg [3:0] I;
reg [1:0] S;
wire Y;
integer i, s;
mux41 uut (.I(I), .S(S), .Y(Y));
initial begin
for (i = 0; i < 16; i = i + 1) begin
for (s = 0; s < 4; s = s + 1) begin
I = i;
S = s;
#10;
end
end
end
endmodule

View File

@@ -0,0 +1,35 @@
`timescale 1ns / 1ps
//////////////////////////////////////////////////////////////////////////////////
// Company:
// Engineer:
//
// Create Date: 2024/09/26 11:52:05
// Design Name:
// Module Name: sim4mux41_alt
// Project Name:
// Target Devices:
// Tool Versions:
// Description:
//
// Dependencies:
//
// Revision:
// Revision 0.01 - File Created
// Additional Comments:
//
//////////////////////////////////////////////////////////////////////////////////
module sim4mux41_alt();
reg [3:0] I;
reg [1:0] S;
wire Y;
mux41_alt test_alt (.I(I), .S(S), .Y(Y));
initial begin
I = 4'b0000; S=2'b00; //initialize
I = 4'b0001; S=2'b00; #100; // A
I = 4'b0010; S=2'b01; #100; // B
I = 4'b0100; S=2'b10; #100; // C
I = 4'b1000; S=2'b11; #100; // D
end
endmodule