Re: Re: HD driver
[email protected] Thu, 22 Apr 2004 10:03:24 +0200
| Newsgroups | gmane.lisp.movitz.devel |
|---|---|
| Message-ID | <[email protected]> |
Citeren Frode Vatvedt Fjeld <[email protected]>: > Peter Minten <[email protected]> writes: > > > The only thing is to insert a delay of about 500 nanoseconds. I > > tried using sleep for it but according to grep it wasn't implemented > > yet, so for the moment I'm using (loop for x from 1 to 1000 > > collecting x). > > Ok. First of all I'd suggest not to use consing as a delay > mechanism. Secondly, if I'm not much mistaken, 500 nanoseconds is 500 > cycles on a 1 GHz machine, so that loop expression is probably off by > a factor of about 100 to 1000. > > Hm.. are you sure it's nanoseconds? I mean, 500 nanseconds is so > little it's getting complicated to measure with any accuracy, not the > least on older CPUs, or across the PCI bus. This is what the spec says: Upon receipt of a Class 1 command, the drive sets BSY within 400 nsec. But if it's only 400 cycles then it's likely enough that BSY is not read before it gets set (and possibly reset) in all cases (at least for testing). So I'll remove the loop. Greetings, Peter