On 12/02/11 19:26, Philip Pemberton wrote:
There's also a new feature in Mcode 001F -- index
speed measurement.
This is essentially a frequency counter tied to the INDEX pin. With
this, you can measure the rotational speed of the disc -- which could be
useful for testing disc drives, and adjusting the rotational speed of
the spindle motor (on drives which have such adjustments).
Well, it seems 250us isn't enough resolution to get a good speed
reading. I've changed the clock divider, and the index frequency
measurement now runs at a timing resolution of 10us. The code to do this
is in Microcode 0020 and the Python API, but isn't in the C API yet.
There are even two neat little functions to get the speed in RPM, and
the index-to-index time in seconds.
Enjoy! (again!)
--
Phil.
classiccmp at philpem.me.uk
http://www.philpem.me.uk/