On Tue, 2006-05-23 at 21:43 +0100, Taiyo Rawle wrote: > > > > What kernel version? > > > > > > > > Bad things will happen if you disconnect a USB > > audio device during > > > > playback. > > > > > > > > > > USB was supposed to be hot-pluggable. > > > > > > Bug in the audio HW, kernel or ALSA ? > > > > > > No bad things (except for data corruption) should > > ever happen > > > if a hot-pluggable device is disconnected. > > > > > > For example, my external hard drive sometimes > > incidentally powered > > > of because of loose connector on the box, thus > > disconnected. > > > > I don't know. XMMS is not ideal for testing. > > My mistake, XMMS works if I select the emu10k1 device. > aplay tells me "aplay: set_params:882: Sample format > non available" on the USB card if I specify it with > the -D option, but it works automagically if I don't > specify any device. >
I am guessing you used -D hw:X - this instructs ALSA not to do any software format conversion, so will fail unless the .wav exactly matches the format supported by the device. -D plughw:x (or omitting the -D argument) enables software format conversion. > > What happens if you disconnect the device while > > "aplay" is playing a > > file, then replug it and "aplay" the same file > > again? > > > > Lee > > If I unplug it while aplay is playing then aplay says > "underrun!!! (at least 0.053 ms long)". I need to kill > all programs that use alsa (like kmix) before the USB > card can be used again, aplay works properly after > this. What error does aplay give you if you re-plug the device without killing all ALSA using apps? Lee ------------------------------------------------------- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnk&kid=107521&bid=248729&dat=121642 _______________________________________________ Alsa-user mailing list Alsa-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/alsa-user