Welcome to Scribd!
Academic Documents
Professional Documents
Culture Documents
Hobbies & Crafts Documents
Personal Growth Documents
CNT
AI-enhanced title
module counter(clk,m,rst,count);input clk,m,rst;output reg[7:0] count;always@(posedge clk or negedge rst)beginif(!rst)count=0;else if(m)count=count+1;elsecount=count-1;endendmodule