Changeset 75bf564 in rtems


Ignore:
Timestamp:
03/07/06 21:05:28 (18 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 4.8, 4.9, 5, master
Children:
ab8394f6
Parents:
d3490f27
Message:

2006-03-07 Lars Munch <lars@…>

  • at91rm9200/clock/clock.c: The clock tick is not very precise on at91rm9200. The attached patch improves the situation by: (1) Not reloading the "period interval timer" register in the

interrupt handler since this is done automatically.

(2) Use integer rounding in the calculation of the "period interval

timer" register value to get as close as posible to the
CONFIGURE_MICROSECONDS_PER_TICK value.

Location:
c/src/lib/libcpu/arm
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libcpu/arm/ChangeLog

    rd3490f27 r75bf564  
     12006-03-07      Lars Munch <lars@segv.dk>
     2
     3        * at91rm9200/clock/clock.c: The clock tick is not very precise on
     4        at91rm9200. The attached patch improves the situation by:
     5          (1) Not reloading the "period interval timer" register in the
     6              interrupt handler since this is done automatically.
     7          (2) Use integer rounding in the calculation of the "period interval
     8              timer" register value to get as close as posible to the
     9              CONFIGURE_MICROSECONDS_PER_TICK value.
     10
    1112005-11-04      Ralf Corsepius <ralf.corsepius@rtems.org>
    212
  • c/src/lib/libcpu/arm/at91rm9200/clock/clock.c

    rd3490f27 r75bf564  
    5555    st_str = ST_REG(ST_SR);
    5656
    57     /* reload the timer value */
    58     ST_REG(ST_PIMR) = st_pimr_reload;
    59 
    6057    rtems_clock_tick();
    6158}
     
    7269    /* the system timer is driven from SLCK */
    7370    slck = at91rm9200_get_slck();
    74     st_pimr_reload = ((BSP_Configuration.microseconds_per_tick * slck) /
     71    st_pimr_reload = (((BSP_Configuration.microseconds_per_tick * slck) + (1000000/2))/
    7572                      1000000);
    7673
Note: See TracChangeset for help on using the changeset viewer.