You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

41 lines
1.0 KiB

  1. `timescale 1ns / 1ps
  2. //////////////////////////////////////////////////////////////////////////////////
  3. // Company:
  4. // Engineer:
  5. //
  6. // Create Date: 04.03.2021 10:10:40
  7. // Design Name:
  8. // Module Name: mux6to1
  9. // Project Name:
  10. // Target Devices:
  11. // Tool Versions:
  12. // Description:
  13. //
  14. // Dependencies:
  15. //
  16. // Revision:
  17. // Revision 0.01 - File Created
  18. // Additional Comments:
  19. //
  20. //////////////////////////////////////////////////////////////////////////////////
  21. module mux6to1(indx_1,indx_2,indx_3,indx_4,indx_5,sel_indx,indx_out);
  22. input [9:0]indx_1,indx_2,indx_3,indx_4,indx_5;
  23. input [2:0]sel_indx;
  24. output reg [9:0]indx_out;
  25. always @(sel_indx or indx_1 or indx_2 or indx_3 or indx_4 or indx_5 )
  26. begin
  27. case (sel_indx)
  28. 3'b000 : indx_out = indx_1;
  29. 3'b001 : indx_out = indx_2;
  30. 3'b010 : indx_out = indx_3;
  31. 3'b011 : indx_out = indx_4;
  32. 3'b100 : indx_out = indx_5;
  33. //3'b101 : indx_out = indx_6;
  34. default : indx_out = indx_1;
  35. endcase
  36. end
  37. endmodule