Forum Discussion
Altera_Forum
Honored Contributor
13 years ago --- Quote Start --- a simple rule is to invert MHz to get period in microsec then count how many periods in .1 sec: 1/50 = .02 microsec (clock period) .1 sec = .1 * 1000000 microsec hence you need .1*1000000/.02 = 5000000 periods --- Quote End --- I understand the first 1/50M = .02 usec since this is the simple Time period formula T = 1/f. However i dont understand the second line, why is .1 multiplied with 1M? thanks --- Quote Start --- One could also say: to count 1 second you have a count equal to the clock frequency in Hz, so to count 0.1 second the count will be the clock frequency in Hz times 0.1 or 50 MHz * 0.1sec = 5M clocks --- Quote End --- thats pretty simple.. so all I have to do is multiply the clock with the amount of time I need? for example for a 2 sec tick its supposed to be 50MHz * 2 sec? Thanks