That gives me a spike twice every time my engine rotates.
RandomTroll wrote:I eventually figured it out by excerpting a single second and raising 'Size' in 'Spectrum Analysis' to 4096. This revealed 43 Hz as the most-common frequency ...
20170211_Second_420.wav (187.78 KiB)
Trebor wrote:On that recording the fundamental frequency is ~37Hz ...
(setf threshold 0.8) ;count click each time we cross this level
(setf step 180) ;follow waveform in steps of this number of samples
;; Use only the left channel of stereo tracks
(if (arrayp *track*)
(setf *track* (aref *track* 0)))
(let ((sig (snd-avg *track* step step op-peak))
(dur (get-duration 1))
(do ((val (snd-fetch sig)(snd-fetch sig))
((not val) (/ count dur))
((and low (> val threshold))
(setf low nil)
(setf count (1+ count)))
((< val threshold)
(setf low t)))))
steve wrote:Counting the peaks with Nyquist gives the same answer:
Users browsing this forum: No registered users and 3 guests