This time, the driver does not consider the feedback frequencies invalid. What I did was: f = combine_quad((u8*)urb->transfer_buffer) & 0x0fffffff; printk("freqn=%u, freqmax=%u, f=%u, dataint=%u\n", subs->freqn, subs->freqmax, f, subs->datainterval); f >>= subs->datainterval; if (f >= subs->freqn - subs->freqn / 8 && f <= subs->freqmax) { spin_lock_irqsave(&subs->lock, flags); subs->freqm = f; printk("f=%u assigned!", f); spin_unlock_irqrestore(&subs->lock, flags);
And what I got: f=1572864 assigned!freqn=1572864, freqmax=1589248, f=6291456, dataint=2 f=1572864 assigned!freqn=1572864, freqmax=1589248, f=6291456, dataint=2 f=1572864 assigned!freqn=1572864, freqmax=1589248, f=6291456, dataint=2
However, the feedback value does not seem to ever change.
I wanted to mention that (from what I noticed until now), it is not possible to get correct playback on this device unless the sampling frequency it is set to (it defaults to 48k when powered on) matches the sampling frequency of the audio stream you send to it. So how is this supposed to work, if the device is set to 48k and my stream has 192k (and I cannot set the device to 192k)?
On Tue, Feb 26, 2008 at 10:49 AM, Clemens Ladisch clemens@ladisch.de wrote:
Adrian Stancu wrote:
OK, I tried playing the stereo file but still getting the same error: deathu@vader:~/Desktop$ aplay -D hw:1 testtone192.wav Playing WAVE 'testtone192.wav' : Signed 16 bit Little Endian, Rate 192000 Hz, Stereo aplay: set_params:918: Sample format non available
Oops, the device supports only 24-bit samples, and this isn't supported by .wav files, so using hw:1 won't ever work with aply.
Well, my test file contained a single constant frequency tone; it is still there while I play the 192k file through plughw:1,0, but burried under:
- periodic series of clicks
- other high frequency tones
Here is /proc/asound/card1/stream0 while playing through plughw:1,0: ...
Momentary freq = 192000 Hz (0x18.0000)
Does this value ever change? Could you again try inserting a printk to see whether the driver thinks it gets invalid frequency values?
Regards, Clemens