[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Kernel time and Milan



On Wed, Oct 28, 1998 at 01:48:20AM +0100, Guido Flohr wrote:
> Somebody told me that there were problems with my kernel time code
> and the Milan.

Wasn't that already fixed by Frank?

> I think the weak point in my code is the interpolation between 
> system clock ticks (I assume that the Milan folks haven't changed
> the click frequency of 200/s).  
> 
> In my code I made the following assumption (that is correct on my
> TT and obviously on the Falcon or ST, too).  The 200-Hz-Interrupt
> is actually triggered by Timer C.  The ratio for timer C is set
> to 1/64 (bits 4 and 6 set, bit 5 not set in the timer-C/D control
> register a 0xfffa1d), the timer-C data register (0xfffa23) is 
> always loaded with 192 at each time zero is passed.  Since the 
> MFP timers in the machines I know all work with a frequency of
> 2.4576 MHz this results in an interrupt frequency of 200 Hz 
> or a 5 ms delay (64 * 192 / 2457600 = 0.005).

None of that has changed in the Milan.

However, the MFP is located at $FFFFC103 + 4 * reg_no. Accesses to the old
locations are emulated, but are quite slow ad thus are unsuitable for
high-resolution timers, so I guess that this caused the problems - Frank?

> about these machines.  Maybe somebody could post this mail to
> one of the Milan or Hades developpers and we can try to find out
> a different solution for these machines if my code doesn't
> work there.  The interpolation is not really necessary.  Without

It should when using the correct addresses. If someone sends me a test
program, I can easily check if it really works on Milan.

cu
Michael
-- 
Michael Schwingen, Ahornstrasse 36, 52074 Aachen