This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Timer calculation in LPC2378

Hi everyone...
i am using LPC2378 controller with the external clock of 12Mhz..Currently testing timer application...what is the formula to calculate the timer value to be load in the register???

If i need 50ms delay then what value should i load in the T0MR0???

Is there any formula???

Thanks in advance...

  • Look in the user manual at the chapter about TIM peripheral. They tell you exactly how to configure the clock. There are no special equations - the value you want depends on the input clock frequency and timer prescalar.

  • Just a note. A question ends with a single question mark (?) and not with three. Three question marks is a special case applicable when you want to inform that you are _extremely_ confused about something. Using "???" after every sentence only informs us that you don't think about your questions. Especially since your only used punctuation are either "..." or "???" with the single exception of a ".." which we must assume is an accident on your side.

    A further example of that is your question "Is there any formula???"

    Do you _really_ think that there may _not_ be a formula for how to compute the timer value? So you really shouldn't be confused (remember the three question marks?) about that, but should instead be thinking about _where_ such information might be. And the only strange thing with the NXP LPC23xx chips is that the information is in the User Manual for the chip, while NXP only have electrical, mechanical and timing information in the Datasheet.

    So the question here is: Have you spent any time looking through the documentation available from NXP?

    It would be meaningful for you to ask specific questions relating to the text in the chip user manual. But only _after_ you have tried to read that text yourself at least twice!

  • hi..
    i read the manual but i didn't understand..that's why i am asking the sequence to configure the timer0????

    thanks..

  • What specific paragraph of the manual did you not understand?

  • In addition to the Datasheet and User Manual, that includes examples, application notes, etc, etc,...

    Keil also have a load of examples...