xref: /txgon/kernel/msm-4.9/Documentation/sound/alsa/soc/DPCM.txt Dynamic PCM 2 =========== 3 4 1. Description 5 ============== 6 7 Dynamic PCM allows an ALSA PCM device to digitally route its PCM audio to 8 various digital endpoints during the PCM stream runtime. e.g. PCM0 can route 9 digital audio to I2S DAI0, I2S DAI1 or PDM DAI2. This is useful for on SoC DSP 10 drivers that expose several ALSA PCMs and can route to multiple DAIs. 11 12 The DPCM runtime routing is determined by the ALSA mixer settings in the same 13 way as the analog signal is routed in an ASoC codec driver. DPCM uses a DAPM 14 graph representing the DSP internal audio paths and uses the mixer settings to 15 determine the patch used by each ALSA PCM. 16 17 DPCM re-uses all the existing component codec, platform and DAI drivers without 18 any modifications. 19 20 21 Phone Audio System with SoC based DSP 22 ------------------------------------- 23 24 Consider the following phone audio subsystem. This will be used in this 25 document for all examples :- 26 27 | Front End PCMs | SoC DSP | Back End DAIs | Audio devices | 28 29 ************* 30 PCM0 <------------> * * <----DAI0-----> Codec Headset 31 * * 32 PCM1 <------------> * * <----DAI1-----> Codec Speakers 33 * DSP * 34 PCM2 <------------> * * <----DAI2-----> MODEM 35 * * 36 PCM3 <------------> * * <----DAI3-----> BT 37 * * 38 * * <----DAI4-----> DMIC 39 * * 40 * * <----DAI5-----> FM 41 ************* 42 43 This diagram shows a simple smart phone audio subsystem. It supports Bluetooth, 44 FM digital radio, Speakers, Headset Jack, digital microphones and cellular 45 modem. This sound card exposes 4 DSP front end (FE) ALSA PCM devices and 46 supports 6 back end (BE) DAIs. Each FE PCM can digitally route audio data to any 47 of the BE DAIs. The FE PCM devices can also route audio to more than 1 BE DAI. 48 49 50 51 Example - DPCM Switching playback from DAI0 to DAI1 52 --------------------------------------------------- 53 54 Audio is being played to the Headset. After a while the user removes the headset 55 and audio continues playing on the speakers. 56 57 Playback on PCM0 to Headset would look like :- 58 59 ************* 60 PCM0 <============> * * <====DAI0=====> Codec Headset 61 * * 62 PCM1 <------------> * * <----DAI1-----> Codec Speakers 63 * DSP * 64 PCM2 <------------> * * <----DAI2-----> MODEM 65 * * 66 PCM3 <------------> * * <----DAI3-----> BT 67 * * 68 * * <----DAI4-----> DMIC 69 * * 70 * * <----DAI5-----> FM 71 ************* 72 73
DPCM.txt
最新推荐文章于 2022-08-09 15:01:44 发布