Advertisement
fellpz

12jun

Jun 12th, 2017
126
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. module counter(LEDR,SW);
  2.  
  3. // I/O ports
  4. output [3:0] LEDR;
  5. input [1:0] SW;
  6.  
  7. // Instantiate the T flipflops
  8. T_FF tff0(LEDR[0], SW[1]  , SW[0]);
  9. T_FF tff1(LEDR[1], LEDR[0], SW[0]);
  10. T_FF tff2(LEDR[2], LEDR[1], SW[0]);
  11. T_FF tff3(LEDR[3], LEDR[1], SW[0]);
  12. endmodule
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement