Diferență între revizuiri ale paginii „Advanced Digital Systems”

De la WikiLabs
Jump to navigationJump to search
 
Linia 2: Linia 2:
 
* [https://users.dcae.pub.ro/~zhascsi/courses/add/add3.pdf Carry Lookahead Adder - iterative design]
 
* [https://users.dcae.pub.ro/~zhascsi/courses/add/add3.pdf Carry Lookahead Adder - iterative design]
 
* [https://users.dcae.pub.ro/~zhascsi/courses/add/add4.pdf Carry Lookahead Adder - recursive design]
 
* [https://users.dcae.pub.ro/~zhascsi/courses/add/add4.pdf Carry Lookahead Adder - recursive design]
 +
 +
== Test code for adder ==
 +
<syntaxhighlight lang="SystemVerilog">
 +
module test;
 +
 +
logic [31:0] a;
 +
logic [31:0] b;
 +
logic [32:0] s;
 +
 +
cla  #(32) dut (.a(a), .b(b), .s(s));
 +
 +
initial begin
 +
    repeat(100) begin
 +
        #1
 +
        a  = $random;
 +
        b  = $random;
 +
        #1
 +
        if(s !== a + b)
 +
            $display("ERROR\n");
 +
        else
 +
            $display("OK\n");
 +
    end
 +
end
 +
 +
endmodule
 +
</syntaxhighlight>
  
 
== Projects ==
 
== Projects ==

Versiunea curentă din 28 mai 2025 15:13

Test code for adder

module test;

logic [31:0] a;
logic [31:0] b;
logic [32:0] s;

cla   #(32) dut (.a(a), .b(b), .s(s));

initial begin
    repeat(100) begin
        #1
        a  = $random;
        b  = $random;
        #1
        if(s !== a + b)
            $display("ERROR\n");
        else
            $display("OK\n");
    end
end

endmodule

Projects

  1. MD5 Hash
  2. SHA-1 Hash
  3. SHA-256 Hash
  4. SHA-512 Hash
  5. AES Encryption
  6. DES Encryption
  7. RSA Encryption
  8. RC4 Stream Cypher
  9. Sorting Network
  10. Sum of Absolute Differences
  11. Sum of Squared Differences
  12. Artificial Neural Network
  13. Gaussian 2D Filter