On Mon, Oct 13, 2008 at 04:04:38AM +0400, Igor B. Poretsky wrote:
Hello, all!
I am using Ecos for the AT91SAM7S target in several real
projects. When started I noticed that the
CYGNUM_HAL_ARM_AT91_CLOCK_SPEED gets the value twice greater than
expected. So I patched the sources to achieve proper time
calculation. It was some time ago and now I don't remember whether I
informed developers about the issue or not. Anyway, I apply my patches
below.
I've also been using the AT91SAM7S and AT91SAM7X in real projects and
have not had problems with the timer. Please could you explain what
you see wrong? Maybe you have a pointer to some documentation?
Looking at page 105 of doc6175.pdf, it shows that the PIT is driven by
MCK/16.
I moved house recently, so my AT91SAM7SEK development board is still
packed away in a box somewhere. Could you run the clocktruth test
program and see if that shows a problem. Without your patch you would
expect it to "tick" at twice the expected rate.
Thanks
Andrew