From mboxrd@z Thu Jan 1 00:00:00 1970 From: Guido Trentalancia Subject: Re: Hercules P32 DJ: severe sound distortion during MIDI transfers Date: Fri, 22 Mar 2019 14:44:48 +0100 Message-ID: <1553262288.26146.4.camel@trentalancia.com> References: <1553114844.12865.6.camel@trentalancia.com> <1335514032.30698.1553207267014@pim.register.it> <53EC51B6-618E-47B4-95E8-B24BECEEBC98@trentalancia.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from authsmtp.register.it (authsmtp04.register.it [81.88.48.54]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 6D75DF8078F for ; Fri, 22 Mar 2019 14:44:52 +0100 (CET) In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" To: Takashi Iwai Cc: alsa-devel@alsa-project.org, clemens@ladisch.de List-Id: alsa-devel@alsa-project.org Hello Takashi. I have carried out the test that you proposed... My reply follows your quoted text. On Fri, 22/03/2019 at 11.12 +0100, Takashi Iwai wrote: > On Fri, 22 Mar 2019 11:04:01 +0100, > Guido Trentalancia wrote: > > > > Hello Takashi, > > > > I am using the latest version of everything, including kernel and > > ALSA > > userspace library / tools. > > > > The other user has exactly the same hardware and has tested same > > firmware > > (both 1.36 and latest 1.46), but with Fedora 29 and it is working. > > > > Perhaps Fedora 29 has a different version of the ALSA library, I > > will find > > out, try to downgrade, test again and report back. > > Yes, that'd be really helpful. If aligning the software doesn't fix > the issue, it's either because of the hardware or the difference of > usage patterns. I have tested exactly the same ALSA userspace library and plugins distributed by Fedora 29 and it does NOT work ! As already explained, the usage pattern is exactly the same between me and the user which is not experiencing this severe problem. Also, the hardware is the same: Hercules P32 DJ (with exactly the same firmware version 1.46 which is the latest). So, the conclusion is that it must be a kernel bug ! I was expecting this, as already pointed out in previous messages. Can you please help me fix this bug since you wrote the driver and/or are maintaining it ? Thanks, Guido > thanks, > > Takashi > > > > > Guido > > > > Il 22 marzo 2019 10:53:11 CET, Takashi Iwai ha > > scritto: > > > > On Fri, 22 Mar 2019 10:17:17 +0100, > > Guido Trentalancia wrote: > > > > It cannot be a firmware bug, as you say, because: > > > > - it does NOT happen on Windows! > > > > It doesn't mean that the device behaves correctly as > > advertised. > > > > - it does NOT even always happen on Linux: other users > > (with different kernel > > / ALSA library) are not experiencing the same problem; > > - it happens with several firmware versions, including the > > latest one (1.36 > > and 1.46). > > > > So it is either a bug in ALSA kernel driver, USB sound > > driver (more likely) or > > ALSA library. > > > > Now, you are in charge of the USB sound driver, can you > > please double check?? > > > > If it doesn't happen for other users with the very same device, > > you'd > > need to identify what's the difference between your case and > > others. > > For example, if the difference of alsa-lib matters, you can try > > the > > very same condition. > > > > This kind of bug can't be easily debugged without the actual > > hardware, unfortunately. > > > > Takashi > > > > Regards, > > > > Guido > > > > Il 22 marzo 2019 09:55:52 CET, Takashi Iwai > > ha scritto: > > > > On Thu, 21 Mar 2019 23:27:46 +0100, > > Guido Trentalancia wrote: > > > > I wonder if this might be due to a bug in the > > "USB Audio Driver for Alsa"? > > > > https://git.kernel.org/pub/scm/linux/kernel/git/t > > orvalds/linux.git/tree/sound/usb > > > > https://git.kernel.org/pub/scm/linux/kernel/git/t > > iwai/sound.git/tree/sound/usb > > > > More likely a buggy firmware of your USB audio device > > :) > > > > From the driver implementation POV, both audio and > > MIDI devices are > > handled by individual endpoints, hence they shouldn't > > conflict. > > > > Or another possibility would be some USB host side > > issue like the > > bandwidth. But > > it's a MIDI stream that is very low data rate, so this > > sounds also unlikely... > > > > thanks, > > > > Takashi > > > > Guido > > > > On the 20th of March 2019 at 21.47 Guido > > Trentalancia > > > > > Hello. > > > > I am hitting a very serious bug (ALSA kernel > > driver or ALSA library) > > when using the Hercules P32 DJ audio > > interface. > > > > The sound is severely distorted during MIDI > > transfers. > > > > To reproduce: > > > > + start playing something in a first > > console: > > > > console1# AUDIODEV=hw:2,0 play audio.wav > > > > + the audio plays fine > > > > + now start "amidi" in a second console > > while the above track is still > > playing > > > > console2# > > amidi -p hw:2,0,0 -d > > > > + the sound is now severely distorted > > (basically noise, with some > > hard- > > to-distinguish features resembling the > > original track) until "amidi" > > is > > interrupted ! > > > >