Timer operation in LPC 1768 In Example program he hasn't configured Clock selection register for Timer 0 directly he has used
TIM0->MR0=ms*(9000000/1000 -1);
from above code it is clear that when TC matches with MR0 it takes additional clock cycle to generate interrupt but value 9000000 can give only one conclusion irrespective of clock selection register i.e for timer 0
SC->PCLKSEL0|=(1<<2);//72MHZ
SC->PCLKSEL0|=(1<<3);//36MHZ
SC->PCLKSEL0|=(1<<2)|(1<<3);//9MHZ
SC->PCLKSEL0&=~((1<<2)|(1<<3));//18MHZ
default clock available for timer is only 9MHZ
is it true?
Who is "he" in your above text?
There is also a prescaler to consider. And the (crystal) oscillator frequency. And the configuration of the PLL.
But it is all very well documented.
Crystal -> PLL -> PCLK -> Prescaler -> TC (MR)