high resolution timer

Mike McCarty mike.mccarty at sbcglobal.net
Fri Jan 20 17:09:56 UTC 2006


Gu, John A. (US SSA) wrote:
> The ADC will do nothing until a trigger command written into its
> register. It then makes a sampling, and within a usec it puts the
> digital data in another latched register mapped into IO address for the
> program to read. This is called the single operation, in other words, no
> trigger no sampling. Though it is capable to have a maximum sample rate
> of 10K per second, but it all depends on how fast and accurate the
> program can do.

[snip]

Ok, this is fine. But how many samples/sec do you actually *need*?

If all you need is 100 samples/sec then there is no point in doing
anything special. All you need to do is run a task each 10ms and
trigger the chip, then hang and wait in the device driver for 100us.
No big deal. (Unless that blows other time constraints.)

If the chip has a ready/busy line, then that can probably be
connected back to the sample command line to cause continuous
operation.

Do you really, really, really need 10K samples/sec? If so,
then probably a little external hardware with a FIFO chip
connected should be put between the A/D and the CPU. Then
an ordinary task can come along and read out the FIFO on
some periodic basis.

Mike
-- 
p="p=%c%s%c;main(){printf(p,34,p,34);}";main(){printf(p,34,p,34);}
This message made from 100% recycled bits.
You have found the bank of Larn.
I can explain it for you, but I can't understand it for you.
I speak only for myself, and I am unanimous in that!




More information about the fedora-list mailing list