Alsa-Devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
To: Mohan Prasath Ramamoorthy <mohan.prasath@vvdntech.in>,
	alsa-devel@alsa-project.org
Subject: Re: [alsa-devel] Playback issue while recording simultaneously
Date: Fri, 6 Dec 2019 09:27:39 -0600	[thread overview]
Message-ID: <d4f21304-d5b0-5acd-2595-4cb7aa684da3@linux.intel.com> (raw)
In-Reply-To: <CAMM7-fe=NAH_tEFsE+RV-eA1KLkhaim_3w4YK3wjqDYea_2TtA@mail.gmail.com>



On 12/5/19 11:22 PM, Mohan Prasath Ramamoorthy wrote:
> Dear All,
> 
> We are working on external modules of microphone and speaker and we
> are using the kernel version 3.10.96

wow, that is one ancient kernel EOL'ed in 2017...

> 
> We are recording with commands like arecord and aplay for recording
> and playback respectively.
> 
> While doing the below experiments we could able to observe an issue as below,
> 
> 1. With only recording and not playback we haven't faced any issues.
> 2. With only playback and not recording we haven't faced any issues.
> 
> 3. By starting an infinite recording in the background and by doing a
> playback of the audio file(30seconds, the sampling rate of 22050, the
> channel is stereo), after some iterations, we are facing a below error
> and we could not able to listen to the audio.
> 
> Error: aplay: pcm_write:1940: write error: Input/output error
> 
> Below are the respective commands for recording and playback,
> 
> 1. arecord -D hw:0,0 -c 2 -f s16_le -r 8000 /home/ubuntu/mic_testing.wav &
> 2. aplay -D hw:0,3 audio_22k_c2.wav
> 
> But when the issues come, we just stopped recording and restarted the
> recording in the background. After this, the playback is working fine.
> 
> Also, during the issue came, we have checked for the below properties,
> 
> 1. I2S has been enabled. Checked under the file:
> /sys/kernel/debug/clock/clock_tree
> 2. Driver callbacks have been called. (Checked with the kernel logs[dmesg])
> 
> We would like to know the reason behind this error.?

Sounds typical of an interference between the playback and record 
programming flows, e.g. when changing a shared register. Not all I2S 
tolerate dynamic changes from RX or TX only to full-duplex.
_______________________________________________
Alsa-devel mailing list
Alsa-devel@alsa-project.org
https://mailman.alsa-project.org/mailman/listinfo/alsa-devel

  reply	other threads:[~2019-12-06 15:52 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-06  5:22 [alsa-devel] Playback issue while recording simultaneously Mohan Prasath Ramamoorthy
2019-12-06 15:27 ` Pierre-Louis Bossart [this message]
2019-12-09  6:50   ` Mohan Prasath Ramamoorthy
2019-12-18  4:36     ` Mohan Prasath Ramamoorthy
2019-12-18 14:45       ` Pierre-Louis Bossart

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=d4f21304-d5b0-5acd-2595-4cb7aa684da3@linux.intel.com \
    --to=pierre-louis.bossart@linux.intel.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=mohan.prasath@vvdntech.in \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox