alsa-devel.alsa-project.org archive mirror
 help / color / mirror / Atom feed
* Re: [alsa-devel] Welcome to the "Alsa-devel" mailing list
       [not found] <mailman.0.1581571721.17635.alsa-devel@alsa-project.org>
@ 2020-02-13  5:57 ` Srinivas Pulukuru
  0 siblings, 0 replies; only message in thread
From: Srinivas Pulukuru @ 2020-02-13  5:57 UTC (permalink / raw)
  To: alsa-devel


[-- Attachment #1.1: Type: text/plain, Size: 4414 bytes --]

This is my first post to this mailing list, so apologize for any inconvenience if this is a wrong place to post such issues. If this is a wrong place please forward it to the right mailing list or let me know and I'll repost it there.

******************************

I are trying to create a 16 channel shared TDM frame that is shared between 8 different playback sources, to be sent out to the default hw:0 card.

I used dshare plugin for this purpose, please see the attached asound.conf. I tried using the share plugin but the performance is really bad and is not practical for our use given the number of channels that we are using.

when starting the playback the poll function called from snd_pcm_wait_nocheck in pcm.c hangs trying to access the /dev/snd/timer and never returns. It is able to access the first couple of times then hangs after that.
==> snd_pcm_write_areas ==> snd_pcm_wait_nocheck ==> poll()

I see that the snd_pcm_direct_t->spcm->hw.ptr that tracks the frames in time is stuck and is  not getting incremented in this case.
I have seen several old posts regarding this issue and not sure which version has this been fixed or it still an issue. I have tried using dmix plugin too with the same result.

My system doesn't have a sound card at the back end of the processor(IMX8M). I just need a shared buffer passed to the SAI interface that gets sent out of the SAI datalines (I2S) as a TDM frame. The codec drivers have been replaced with null terminated codecs as there at no DAC's connected to the processor.

The SAI I2S datalines are connected to a FPGA that demultiplexes and processes the TDM frame to be sent out to multiple audio outputs.
I am using alsa 1.1.2 and kernel imx8m 4.14.98 . I have tried to move to later version of alsa that I was able to build. I went till 1.1.7 but I still get the same issue.

I have posted more details in the following link in case you need more details including the asound.conf and the batch file that runs 8 different pcm files to 8 different virtual sources connected to the same HW card.


https://unix.stackexchange.com/questions/567295/alsa-16-channel-audio-playback-using-dshare-plugin-is-getting-stuck-at-poll-func

********************************


Thanks,
Srinivas


Srinivas Pulukuru | Sr. Firmware Engineer
Phone: 800-237-2041
Email: spulukuru@crestron.com
Crestron Plano
7250 Dallas Parkway, Suite 600, Plano, Texas 75024
-----Original Message-----
From: Alsa-devel <alsa-devel-bounces@alsa-project.org> On Behalf Of alsa-devel-request@alsa-project.org
Sent: Wednesday, February 12, 2020 11:29 PM
To: Srinivas Pulukuru <spulukuru@crestron.com>
Subject: Welcome to the "Alsa-devel" mailing list

Welcome to the Alsa-devel@alsa-project.org mailing list!

To post to this list, send your message to:

  alsa-devel@alsa-project.org

General information about the mailing list is at:

  https://urldefense.proofpoint.com/v2/url?u=https-3A__mailman.alsa-2Dproject.org_mailman_listinfo_alsa-2Ddevel&d=DwICAg&c=BevoquqpKcc6oV2fwHriBQ&r=y474ZfoKVIiNc_OxUV2Ln4wICu6ToyX-jLO9EZPQIYc&m=Vx0KxM09TxM2gCMCtqxgOIzQgE-mUpjDjcQ88-UJuuw&s=GT-Iz8-BDOiY2gcNqpk7pBIxwCplNg-knesW0kRyLes&e=

If you ever want to unsubscribe or change your options (eg, switch to or from digest mode, change your password, etc.), visit your subscription page at:

  https://urldefense.proofpoint.com/v2/url?u=https-3A__mailman.alsa-2Dproject.org_mailman_options_alsa-2Ddevel_spulukuru-2540crestron.com&d=DwICAg&c=BevoquqpKcc6oV2fwHriBQ&r=y474ZfoKVIiNc_OxUV2Ln4wICu6ToyX-jLO9EZPQIYc&m=Vx0KxM09TxM2gCMCtqxgOIzQgE-mUpjDjcQ88-UJuuw&s=zi-AR-TccCkIrTRU-67MHrlBJBAPgXTEwHT8loM053Q&e=


You can also make such adjustments via email by sending a message to:

  Alsa-devel-request@alsa-project.org

with the word `help' in the subject or body (don't include the quotes), and you will get back a message with instructions.

You must know your password to change your options (including changing the password, itself) or to unsubscribe without confirmation.  It is:

  psr9611p

Normally, Mailman will remind you of your alsa-project.org mailing list passwords once every month, although you can disable this if you prefer.  This reminder will also include instructions on how to unsubscribe or change your account options.  There is also a button on your options page that will email your current password to you.

[-- Attachment #1.2: image914033.jpg --]
[-- Type: image/jpeg, Size: 16814 bytes --]

[-- Attachment #2: asound.conf --]
[-- Type: application/octet-stream, Size: 3980 bytes --]

# Crestron DNA_AUDIO x specific configurations
# NOTE: this is for sharing multiple channels on a single (TDM) audio device with multple ALSA clients

# shared buffer for playback
pcm_slave.tdmshare {
    pcm "hw:0"
    channels 16
    rate 48000          # fixed, because all dshare devices must use the same samplerate.
    format S24_LE
    period_size 1024
    buffer_size 8192
}

# src1 shared pcm device and corresponding virtual playback device
pcm.src1_dshare {
    type dshare
    ipc_key 43544553
    slave tdmshare
    bindings.0 0
    bindings.1 4
}
pcm.src1 {
    type plug
    slave.pcm "src1_dshare"
 hint {
                show {
                        @func refer
                        name defaults.namehint.basic
                }
                description "TDM 0 channel 0/1 for audio playback"
        }
}

# src2 shared pcm device and corresponding virtual playback device
pcm.src2_dshare {
    type dshare
    ipc_key 43544553
    slave tdmshare
    bindings.0 8
    bindings.1 12
}
pcm.src2 {
    type plug
    slave.pcm "src2_dshare"
 hint {
                show {
                        @func refer
                        name defaults.namehint.basic
                }
                description "TDM 1 channel 2/3 for audio playback"
        }
}

# src3 shared pcm device and corresponding virtual playback device
pcm.src3_dshare {
    type dshare
    ipc_key 43544553
    slave tdmshare
    bindings.0 1
    bindings.1 5
}
pcm.src3 {
    type plug
    slave.pcm "src3_dshare"
 hint {
                show {
                        @func refer
                        name defaults.namehint.basic
                }
                description "TDM 2 channel 4/5 for audio playback"
        }
}

# src4 shared pcm device and corresponding virtual playback device
pcm.src4_dshare {
    type dshare
    ipc_key 43544553
    slave tdmshare
    bindings.0 9
    bindings.1 13
}
pcm.src4 {
    type plug
    slave.pcm "src4_dshare"
 hint {
                show {
                        @func refer
                        name defaults.namehint.basic
                }
                description "TDM 3 channel 6/7 for audio playback"
        }
}

# src5 shared pcm device and corresponding virtual playback device
pcm.src5_dshare {
    type dshare
    ipc_key 43544553
    slave tdmshare
    bindings.0 2
    bindings.1 6
}
pcm.src5 {
    type plug
    slave.pcm "src5_dshare"
 hint {
                show {
                        @func refer
                        name defaults.namehint.basic
                }
                description "TDM 4 channel 8/9 for audio playback"
        }
}

# src6 shared pcm device and corresponding virtual playback device
pcm.src6_dshare {
    type dshare
    ipc_key 43544553
    slave tdmshare
    bindings.0 10
    bindings.1 14
}
pcm.src6 {
    type plug
    slave.pcm "src6_dshare"
 hint {
                show {
                        @func refer
                        name defaults.namehint.basic
                }
                description "TDM 5channel 10/11 for audio playback"
        }
}

# src7 shared pcm device and corresponding virtual playback device
pcm.src7_dshare {
    type dshare
    ipc_key 43544553
    slave tdmshare
    bindings.0 3
    bindings.1 7
}
pcm.src7 {
    type plug
    slave.pcm "src7_dshare"
 hint {
                show {
                        @func refer
                        name defaults.namehint.basic
                }
                description "TDM 6 channel 12/13 for audio playback"
        }
}

# src8 shared pcm device and corresponding virtual playback device
pcm.src8_dshare {
    type dshare
    ipc_key 43544553
    slave tdmshare
    bindings.0 11
    bindings.1 15
}
pcm.src8 {
    type plug
    slave.pcm "src8_dshare"
 hint {
                show {
                        @func refer
                        name defaults.namehint.basic
                }
                description "TDM 7 channel 14/15 for audio playback"
        }
}


[-- Attachment #3: Type: text/plain, Size: 161 bytes --]

_______________________________________________
Alsa-devel mailing list
Alsa-devel@alsa-project.org
https://mailman.alsa-project.org/mailman/listinfo/alsa-devel

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2020-02-13  5:58 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <mailman.0.1581571721.17635.alsa-devel@alsa-project.org>
2020-02-13  5:57 ` [alsa-devel] Welcome to the "Alsa-devel" mailing list Srinivas Pulukuru

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).