Guest
#4419575
Hello everyone! My task is to write an up counter, that counts how long is the input signal (in) in clock (clk) cycle units from 1 to 1023 (precision 1 clock cycle). When input signal (in) ends, there has to be signal on wire ready, which means that data are ready to read and the value from the counter is now avaliable on data output. This value stays there until the end of the next input signal. The whole project consists of 3 sequential processes: falling edge detector, counter and output register. It has to be module with synchronous clock and asynchronous reset. My problem here is that I don't reset the counter when input signal ends. As an attachment I am posting my code for module and test bench. X.