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

A question about timer configuration

Hi all,
I am relatively new to the ARM family and I didn't find an answer in the documentation, unfortunately...
I am trying to change the interrupt rate of my STR7's timer 0. I have an 16[Mhz] external oscillator. Could you explain to me why the following setting generates an interrupt every 130[ms]?

// Initialize the Timer
TIM_Init (TIM0);
// Configure Timer 0 Prescaler
TIM_PrescalerConfig (TIM0,0x0F);
// Enable Timer 0 Overflow Interrupt
TIM_ITConfig(TIM0,TIM_TO_IT,ENABLE);

Parents
  • Very nice. You have now informed the list about:
    - the physical location of the timer in the address space of the processor.
    - a typedef that describes which registers that may be configured for the timer.

    You have not sent a single piece of information about what values the code actually writes to all these registers - hence, it is absolutely impossible to answer anything about your question.

Reply
  • Very nice. You have now informed the list about:
    - the physical location of the timer in the address space of the processor.
    - a typedef that describes which registers that may be configured for the timer.

    You have not sent a single piece of information about what values the code actually writes to all these registers - hence, it is absolutely impossible to answer anything about your question.

Children
  • What documentation did you check? Generic ARM documentation, or specific STR7 documentation? My guess is the former, since STR7 peripherals would not be documented there. The info you need to understand how to configure the STR7's peripherals is in the STR7 datasheet. Do you have it? Do you know where you can get it?