RFC: Is BSP allowed to modify configuration values?

Thomas Doerfler Thomas.Doerfler at imd-systems.de
Tue Oct 19 18:05:58 UTC 2004


Hello,

this is a general question, quite related to Leon's "PIT 
initialization" question:

On some of my MBX8xx boards, the manufacturer has implemented a 
rather inflexible timer clock hardware. This hardware uses a low 
frequency crystal to feed the system timer, and therefore it is 
impossible to create "nice" timer tick intervals like "10ms" or 
so. You might end up at real timer tick values like 
"9.765625ms". I am not yet sure how to handle this on BSP level. 
I see various solutions:

A) At runtime, adjust the "usec_per_tick" value in the 
configuration table from the user selected value to the closest 
one supported

or 

B) At runtime, accumulate the timing error generated and drop 
timer interrupt handling from time to time to get, in average, a 
correct advancement in time. The disadvantage here is, that the 
RTEMS tick no longer will advance at evenly spaced intervals

C) Use a different timer (which would be suitable at this 
particular hardware, but I think this problem might arise with 
other hardware aswell).

Any comments welcome...

Thomas.
--------------------------------------------
IMD Ingenieurbuero fuer Microcomputertechnik
Thomas Doerfler           Herbststrasse 8
D-82178 Puchheim          Germany
email:    Thomas.Doerfler at imd-systems.de
PGP public key available at: http://www.imd-
systems.de/pgp_keys.htm




More information about the users mailing list