This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

davinci-pcm underrun(?)

Other Parts Discussed in Thread: TLV320AIC14K

I'm trying to get audio working on a custom AM180x board.  When I record audio and then play it back on a PC, the audio will skip back in time several times during a 10 second recording.  However, if I put in delays (in the form of debugging spits to the console) in the function davinci_pcm_pointer, then audio recording starts working.  So, it appears to be some sort of timing issue.  Where is the timing of data transfer between the McASP and the audio codec set?

Thanks,

David

  • So, I've enable XRUN DEBUG and set its value at 3.  Now, when I do a playback I get several XRUN dumps.  Here's the text from the syslog:

    root@am180x-evm:~# aplay --period-size=512 /usr/share/sounds/alsa/Front_Center.wav
    Playing WAVE '/usr/share/sounds/alsa/Front_Center.wav' : Signed 16 bit Little Endian, Rate 48000 Hz, Mono
    underrun!!! (at least 417.453 ms long)
    underrun!!! (at least 410.054 ms long)
    root@am180x-evm:~# dmesg
    ioctl+0x0/0x3c) from [<c00bdd4c>] (do_vfs_ioctl+0x570/0x5e0)
    [<c00bd7dc>] (do_vfs_ioctl+0x0/0x5e0) from [<c00bde14>] (sys_ioctl+0x58/0x7c)
    [<c00bddbc>] (sys_ioctl+0x0/0x7c) from [<c002efe0>] (ret_fast_syscall+0x0/0x2c)
     r8:c002f164 r7:00000036 r6:00000000 r5:0002e6b8 r4:0002e668
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a1400 period_size=400
    davinci-pcm: PCM trigger
    davinci-mcasp davinci-mcasp.0: Shutting down McASP
    XRUN: pcmC0D0p:0
    Backtrace:
    [<c0032698>] (dump_backtrace+0x0/0x10c) from [<c031bb74>] (dump_stack+0x18/0x1c)
     r7:c7072000 r6:c7851600 r5:c7a4bc58 r4:00000000
    [<c031bb5c>] (dump_stack+0x0/0x1c) from [<c025e450>] (xrun+0xc8/0xdc)
    [<c025e388>] (xrun+0x0/0xdc) from [<c025edbc>] (snd_pcm_update_state+0xb4/0x120)
     r6:0000678f r5:60000093 r4:0000678f
    [<c025ed08>] (snd_pcm_update_state+0x0/0x120) from [<c025f4ac>] (snd_pcm_update_hw_ptr0+0x684/0x6e0)
     r4:0000678f
    [<c025ee28>] (snd_pcm_update_hw_ptr0+0x0/0x6e0) from [<c025f5a8>] (snd_pcm_period_elapsed+0xa0/0x158)
    [<c025f508>] (snd_pcm_period_elapsed+0x0/0x158) from [<c026bf68>] (davinci_pcm_dma_irq+0xb8/0xc4)
     r6:c7851600 r5:00000001 r4:c7a4a000
    [<c026beb0>] (davinci_pcm_dma_irq+0x0/0xc4) from [<c00390e8>] (dma_irq_handler+0x154/0x1a0)
     r7:00002068 r6:00002050 r5:00000001 r4:00000001
    [<c0038f94>] (dma_irq_handler+0x0/0x1a0) from [<c0076324>] (handle_IRQ_event+0x2c/0xfc)
    [<c00762f8>] (handle_IRQ_event+0x0/0xfc) from [<c0078880>] (handle_edge_irq+0x15c/0x1cc)
     r7:0000000b r6:c7819b00 r5:c7a4a000 r4:c0418538
    [<c0078724>] (handle_edge_irq+0x0/0x1cc) from [<c002e07c>] (asm_do_IRQ+0x7c/0xa0)
     r8:00000001 r7:00000002 r6:00200800 r5:00000000 r4:0000000b
    [<c002e000>] (asm_do_IRQ+0x0/0xa0) from [<c002ebec>] (__irq_svc+0x4c/0x9c)
    Exception stack(0xc7a4bdf8 to 0xc7a4be40)
    bde0:                                                       00000001 0000077f
    be00: 00005e00 60000013 00005681 c7072000 00000081 c7a4a000 c7851600 0000077f
    be20: 0000017f c7a4be94 c70720ac c7a4be40 c025ff20 c025ffcc 60000013 ffffffff
     r5:febfd000 r4:ffffffff
    [<c025fda8>] (snd_pcm_lib_write1+0x0/0x430) from [<c02602b0>] (snd_pcm_lib_write+0x6c/0x78)
    [<c0260244>] (snd_pcm_lib_write+0x0/0x78) from [<c025becc>] (snd_pcm_playback_ioctl1+0xc4/0x518)
     r6:c7851600 r5:00000000 r4:00000000
    [<c025be08>] (snd_pcm_playback_ioctl1+0x0/0x518) from [<c025c358>] (snd_pcm_playback_ioctl+0x38/0x3c)
     r8:beeaf9fc r7:00000004 r6:400c4150 r5:c7a3a800 r4:00000000
    [<c025c320>] (snd_pcm_playback_ioctl+0x0/0x3c) from [<c00bdd4c>] (do_vfs_ioctl+0x570/0x5e0)
    [<c00bd7dc>] (do_vfs_ioctl+0x0/0x5e0) from [<c00bde14>] (sys_ioctl+0x58/0x7c)
    [<c00bddbc>] (sys_ioctl+0x0/0x7c) from [<c002efe0>] (ret_fast_syscall+0x0/0x2c)
     r8:c002f164 r7:00000036 r6:00000000 r5:0002e6b8 r4:0002e668
    davinci-pcm: Prepare PCM
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a0000 period_size=400
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a0400 period_size=400
    davinci-mcasp davinci-mcasp.0: Cancel delayed work
    davinci-mcasp davinci-mcasp.0: Stream start
    davinci-mcasp davinci-mcasp.0: Digital Mute
    tlv320aic14k-codec 1-0040: Un-muting Codec
    davinci-mcasp davinci-mcasp.0: End of preparations
    davinci-pcm: PCM trigger
    davinci-mcasp davinci-mcasp.0: Starting up McASP
    PCM: Lost interrupts? (stream=0, delta=820, new_hw_ptr=820, old_hw_ptr=0)
    Backtrace:
    [<c0032698>] (dump_backtrace+0x0/0x10c) from [<c031bb74>] (dump_stack+0x18/0x1c)
     r7:c7072000 r6:00000334 r5:c7072000 r4:00000000
    [<c031bb5c>] (dump_stack+0x0/0x1c) from [<c025f3e4>] (snd_pcm_update_hw_ptr0+0x5bc/0x6e0)
    [<c025ee28>] (snd_pcm_update_hw_ptr0+0x0/0x6e0) from [<c025f674>] (snd_pcm_update_hw_ptr+0x14/0x18)
    [<c025f660>] (snd_pcm_update_hw_ptr+0x0/0x18) from [<c025fe84>] (snd_pcm_lib_write1+0xdc/0x430)
    [<c025fda8>] (snd_pcm_lib_write1+0x0/0x430) from [<c02602b0>] (snd_pcm_lib_write+0x6c/0x78)
    [<c0260244>] (snd_pcm_lib_write+0x0/0x78) from [<c025becc>] (snd_pcm_playback_ioctl1+0xc4/0x518)
     r6:c7851600 r5:00000000 r4:00000000
    [<c025be08>] (snd_pcm_playback_ioctl1+0x0/0x518) from [<c025c358>] (snd_pcm_playback_ioctl+0x38/0x3c)
     r8:beeaf9fc r7:00000004 r6:400c4150 r5:c7a3a800 r4:00000000
    [<c025c320>] (snd_pcm_playback_ioctl+0x0/0x3c) from [<c00bdd4c>] (do_vfs_ioctl+0x570/0x5e0)
    [<c00bd7dc>] (do_vfs_ioctl+0x0/0x5e0) from [<c00bde14>] (sys_ioctl+0x58/0x7c)
    [<c00bddbc>] (sys_ioctl+0x0/0x7c) from [<c002efe0>] (ret_fast_syscall+0x0/0x2c)
     r8:c002f164 r7:00000036 r6:00000000 r5:0002e6b8 r4:0002e668
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a0800 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a0c00 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a1000 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a1400 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a1800 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a1c00 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a2000 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a2400 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a2800 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a2c00 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a3000 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a3400 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a3800 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a3c00 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a4000 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a4400 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a4800 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a4c00 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a5000 period_size=400
    PCM: Lost interrupts? [Q] (stream=0, delta=23957, new_hw_ptr=33812, old_hw_ptr=9855)
    Backtrace:
    [<c0032698>] (dump_backtrace+0x0/0x10c) from [<c031bb74>] (dump_stack+0x18/0x1c)
     r7:c7072000 r6:00008414 r5:60000093 r4:c7851600
    [<c031bb5c>] (dump_stack+0x0/0x1c) from [<c025f3e4>] (snd_pcm_update_hw_ptr0+0x5bc/0x6e0)
    [<c025ee28>] (snd_pcm_update_hw_ptr0+0x0/0x6e0) from [<c025f5a8>] (snd_pcm_period_elapsed+0xa0/0x158)
    [<c025f508>] (snd_pcm_period_elapsed+0x0/0x158) from [<c026bf68>] (davinci_pcm_dma_irq+0xb8/0xc4)
     r6:c7851600 r5:00000001 r4:c7a4a000
    [<c026beb0>] (davinci_pcm_dma_irq+0x0/0xc4) from [<c00390e8>] (dma_irq_handler+0x154/0x1a0)
     r7:00002068 r6:00002050 r5:00000001 r4:00000001
    [<c0038f94>] (dma_irq_handler+0x0/0x1a0) from [<c0076324>] (handle_IRQ_event+0x2c/0xfc)
    [<c00762f8>] (handle_IRQ_event+0x0/0xfc) from [<c0078880>] (handle_edge_irq+0x15c/0x1cc)
     r7:0000000b r6:c7819b00 r5:c7a4a000 r4:c0418538
    [<c0078724>] (handle_edge_irq+0x0/0x1cc) from [<c002e07c>] (asm_do_IRQ+0x7c/0xa0)
     r8:00000001 r7:00000002 r6:00000800 r5:00000000 r4:0000000b
    [<c002e000>] (asm_do_IRQ+0x0/0xa0) from [<c002ebec>] (__irq_svc+0x4c/0x9c)
    Exception stack(0xc7a4bdf8 to 0xc7a4be40)
    bde0:                                                       00000001 000025fe
    be00: 00005e00 60000013 00000081 c7072000 00000081 c7a4a000 c7851600 000025fe
    be20: 0000017d c7a4be94 c7851600 c7a4be40 c025ff20 c025ffcc 60000013 ffffffff
     r5:febfd000 r4:ffffffff
    [<c025fda8>] (snd_pcm_lib_write1+0x0/0x430) from [<c02602b0>] (snd_pcm_lib_write+0x6c/0x78)
    [<c0260244>] (snd_pcm_lib_write+0x0/0x78) from [<c025becc>] (snd_pcm_playback_ioctl1+0xc4/0x518)
     r6:c7851600 r5:00000000 r4:00000000
    [<c025be08>] (snd_pcm_playback_ioctl1+0x0/0x518) from [<c025c358>] (snd_pcm_playback_ioctl+0x38/0x3c)
     r8:beeaf9fc r7:00000004 r6:400c4150 r5:c7a3a800 r4:00000000
    [<c025c320>] (snd_pcm_playback_ioctl+0x0/0x3c) from [<c00bdd4c>] (do_vfs_ioctl+0x570/0x5e0)
    [<c00bd7dc>] (do_vfs_ioctl+0x0/0x5e0) from [<c00bde14>] (sys_ioctl+0x58/0x7c)
    [<c00bddbc>] (sys_ioctl+0x0/0x7c) from [<c002efe0>] (ret_fast_syscall+0x0/0x2c)
     r8:c002f164 r7:00000036 r6:00000000 r5:0002e6b8 r4:0002e668
    davinci-pcm: PCM trigger
    davinci-mcasp davinci-mcasp.0: Shutting down McASP
    XRUN: pcmC0D0p:0
    Backtrace:
    [<c0032698>] (dump_backtrace+0x0/0x10c) from [<c031bb74>] (dump_stack+0x18/0x1c)
     r7:c7072000 r6:c7851600 r5:c7a4bc58 r4:00000000
    [<c031bb5c>] (dump_stack+0x0/0x1c) from [<c025e450>] (xrun+0xc8/0xdc)
    [<c025e388>] (xrun+0x0/0xdc) from [<c025edbc>] (snd_pcm_update_state+0xb4/0x120)
     r6:00008414 r5:60000093 r4:00008414
    [<c025ed08>] (snd_pcm_update_state+0x0/0x120) from [<c025f4ac>] (snd_pcm_update_hw_ptr0+0x684/0x6e0)
     r4:00008414
    [<c025ee28>] (snd_pcm_update_hw_ptr0+0x0/0x6e0) from [<c025f5a8>] (snd_pcm_period_elapsed+0xa0/0x158)
    [<c025f508>] (snd_pcm_period_elapsed+0x0/0x158) from [<c026bf68>] (davinci_pcm_dma_irq+0xb8/0xc4)
     r6:c7851600 r5:00000001 r4:c7a4a000
    [<c026beb0>] (davinci_pcm_dma_irq+0x0/0xc4) from [<c00390e8>] (dma_irq_handler+0x154/0x1a0)
     r7:00002068 r6:00002050 r5:00000001 r4:00000001
    [<c0038f94>] (dma_irq_handler+0x0/0x1a0) from [<c0076324>] (handle_IRQ_event+0x2c/0xfc)
    [<c00762f8>] (handle_IRQ_event+0x0/0xfc) from [<c0078880>] (handle_edge_irq+0x15c/0x1cc)
     r7:0000000b r6:c7819b00 r5:c7a4a000 r4:c0418538
    [<c0078724>] (handle_edge_irq+0x0/0x1cc) from [<c002e07c>] (asm_do_IRQ+0x7c/0xa0)
     r8:00000001 r7:00000002 r6:00000800 r5:00000000 r4:0000000b
    [<c002e000>] (asm_do_IRQ+0x0/0xa0) from [<c002ebec>] (__irq_svc+0x4c/0x9c)
    Exception stack(0xc7a4bdf8 to 0xc7a4be40)
    bde0:                                                       00000001 000025fe
    be00: 00005e00 60000013 00000081 c7072000 00000081 c7a4a000 c7851600 000025fe
    be20: 0000017d c7a4be94 c7851600 c7a4be40 c025ff20 c025ffcc 60000013 ffffffff
     r5:febfd000 r4:ffffffff
    [<c025fda8>] (snd_pcm_lib_write1+0x0/0x430) from [<c02602b0>] (snd_pcm_lib_write+0x6c/0x78)
    [<c0260244>] (snd_pcm_lib_write+0x0/0x78) from [<c025becc>] (snd_pcm_playback_ioctl1+0xc4/0x518)
     r6:c7851600 r5:00000000 r4:00000000
    [<c025be08>] (snd_pcm_playback_ioctl1+0x0/0x518) from [<c025c358>] (snd_pcm_playback_ioctl+0x38/0x3c)
     r8:beeaf9fc r7:00000004 r6:400c4150 r5:c7a3a800 r4:00000000
    [<c025c320>] (snd_pcm_playback_ioctl+0x0/0x3c) from [<c00bdd4c>] (do_vfs_ioctl+0x570/0x5e0)
    [<c00bd7dc>] (do_vfs_ioctl+0x0/0x5e0) from [<c00bde14>] (sys_ioctl+0x58/0x7c)
    [<c00bddbc>] (sys_ioctl+0x0/0x7c) from [<c002efe0>] (ret_fast_syscall+0x0/0x2c)
     r8:c002f164 r7:00000036 r6:00000000 r5:0002e6b8 r4:0002e668
    davinci_pcm: link=1, status=0x1
    davinci-pcm: Prepare PCM
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a0000 period_size=400
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a0400 period_size=400
    davinci-mcasp davinci-mcasp.0: Cancel delayed work
    davinci-mcasp davinci-mcasp.0: Stream start
    davinci-mcasp davinci-mcasp.0: Digital Mute
    tlv320aic14k-codec 1-0040: Un-muting Codec
    davinci-mcasp davinci-mcasp.0: End of preparations
    davinci-pcm: PCM trigger
    davinci-mcasp davinci-mcasp.0: Starting up McASP
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a0800 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a0c00 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a1000 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a1400 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a1800 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a1c00 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a2000 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a2400 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a2800 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a2c00 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a3000 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a3400 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a3800 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a3c00 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a4000 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a4400 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a4800 period_size=400
    davinci_pcm: link=1, status=0x1
    davinci_pcm: audio_set_dma_params_play channel = 81 dma_ptr = c79a4c00 period_size=400
    davinci-pcm: PCM trigger
    davinci-mcasp davinci-mcasp.0: Shutting down McASP
    davinci-pcm: Freeing PCM hardware
    davinci-pcm: Freeing PCM hardware
    tlv320aic14k-codec 1-0040: Muting Codec
    tlv320aic14k-codec 1-0040: Locking tlv320aic14k registers for read
    tlv320aic14k-codec 1-0040: Reading Register 5B
    tlv320aic14k-codec 1-0040: Register index 5A = 39
    tlv320aic14k-codec 1-0040: Register index 5B = 30
    tlv320aic14k-codec 1-0040: Register index 5C = 32
    tlv320aic14k-codec 1-0040: Register index 5D = 02
    tlv320aic14k-codec 1-0040: Un-locking tlv320aic14k registers
    tlv320aic14k-codec 1-0040: Locking tlv320aic14k registers for write
    tlv320aic14k-codec 1-0040: Writing Register 5B = 3f
    tlv320aic14k-codec 1-0040: Reading Register 5B
    tlv320aic14k-codec 1-0040: Register index 5A = 39
    tlv320aic14k-codec 1-0040: Register index 5B = 3f
    tlv320aic14k-codec 1-0040: Register index 5C = 32
    tlv320aic14k-codec 1-0040: Register index 5D = 02
    tlv320aic14k-codec 1-0040: Un-locking tlv320aic14k registers
    davinci-mcasp davinci-mcasp.0: Shutting down the McASP
    tlv320aic14k-codec 1-0040: Shutting Down Codec
    tlv320aic14k-codec 1-0040: Requesting unlock for dac mutex
    tlv320aic14k-codec 1-0040: Locking tlv320aic14k registers for read
    tlv320aic14k-codec 1-0040: Reading Register 3A
    tlv320aic14k-codec 1-0040: Register index 3A = 01
    tlv320aic14k-codec 1-0040: Un-locking tlv320aic14k registers
    tlv320aic14k-codec 1-0040: Setting Bias Level
    tlv320aic14k-codec 1-0040: Locking tlv320aic14k registers for write
    tlv320aic14k-codec 1-0040: Writing Register 3A = c1
    tlv320aic14k-codec 1-0040: Reading Register 3A
    tlv320aic14k-codec 1-0040: Register index 3A = c1
    tlv320aic14k-codec 1-0040: Un-locking tlv320aic14k registers
    davinci-pcm: Close PCM

    It looks like to me that's its saying that the DMA interrupts stop and so it resets the McASP.  Any thoughts on why that might be happening?

    Thanks,

    David

  • David,

    I am facing a similar issue on DM8168 which have MCASP to connect audio interfaces.

    Whether you have resolved this issue?

    If resolved, can you please help us.

    Regards,

    Nitish James

  • James,

        Even i am facing the similar issue after which i am hearing the delay in the audio.Are you also hearing the delay?Or did you find any fix to this issue?

    Regards

    Charan

  • Bump. I'm seeing the same issue. For some reason the hw_ptr stops advancing so the underrun condition is detected.

    Has anyone found a solution to this problem?

    Thanks,

    -Craig

  • Craig,

    The Audio underrun conditions can happen due to many reason.

    1. Incorrect of insufficient hardware params passed from the applications side. (verify the buffer size and period size params)

    2. High CPU utilization block the applications application thread may result in XRUN (make sure that the audio thread high privority and cpu not overloaded)

    3. EDMA will not able to deliver the data in the proper intervals (change the edma priority )

    Could you please provide more information about the setup and the hw_params passed from the app to get a better understanding of the issue ?