its not clear whether you are trying to measure timer clock pulse width or system clock pulse width or any external clock pulse. if external clock you can use external interrupts with edge trigger selection and a timercounter.
the clock i measure is external clock. i know how to set the interrupt,but i dont know about the timer,what timer is suitable for that??
can you give a brief explanation?
and where can I read about the input capture peripheral? Thank you…
The input capture device is described in the Microprocessor User’s Manual for your processor(by the way, it would help if, when asking a question like this, you would indicate what processor or core module you’re using). Go here: http://www.rabbit.com/docs/
and find the manual for the processor you’re using.