A�DE
board_cs4344_initialize: minor 1
stm32_i2sbus_initialize: port: 2
i2s_dump_regs: I2S2: After initialization
i2s_dump_regs: CR1:0000 CR2:0700 SR:0002 DR:0000
i2s_dump_regs: I2SCFGR:0000 I2SPR:0002
i2s_dump_regs: PLLI2SCFGR:44013000
cs4344_reset: WARNING: MCLK could not be set on lower half
i2s_mckdivider: Entry
i2s_dump_regs: I2S2: After i2s_mckdivider
i2s_dump_regs: CR1:0000 CR2:0700 SR:0002 DR:0000
i2s_dump_regs: I2SCFGR:0e00 I2SPR:020d
i2s_dump_regs: PLLI2SCFGR:20003540
cs4344_setbitrate: sample rate=16000 nchannels=1 bpsamp=16
audio_register: Registering /dev/audio/pcm1
NuttShell (NSH) NuttX-12.5.1
nsh> upload
Registering romdisk at /dev/ram0
Mounting ROMFS filesystem at target=/data with source=/dev/ram0
nsh> nxplayer
NxPlayer version 1.05
h for commands, q to exit
nxplayer> play /data/yes.wav
nxplayer_playinternal: ==============================
nxplayer_playinternal: Playing file /data/yes.wav
nxplayer_playinternal: ==============================
audio_open: crefs: 0
audio_ioctl: cmd: 4097 arg: 537390872
audio_ioctl: AUDIOIOC_GETCAPS: Device=0
cs4344_getcaps: type=0 ac_type=0
audio_ioctl: cmd: 4098 arg: 0
audio_ioctl: AUDIOIOC_RESERVE
pcm_reserve: Defer to lower reserve
audio_ioctl: cmd: 4097 arg: 537390872
audio_ioctl: AUDIOIOC_GETCAPS: Device=2
cs4344_getcaps: type=2 ac_type=2
audio_ioctl: cmd: 4106 arg: 537390840
audio_ioctl: Forwarding unrecognized cmd: 4106 arg: 537390840
pcm_ioctl: Defer to lower ioctl, cmd=4106 arg=537390840
cs4344_ioctl: Ignored
audio_ioctl: cmd: 4110 arg: 4
audio_ioctl: AUDIOIOC_REGISTERMQ
nxplayer_playthread: Entry
audio_ioctl: cmd: 4106 arg: 537393600
audio_ioctl: Forwarding unrecognized cmd: 4106 arg: 537393600
pcm_ioctl: Defer to lower ioctl, cmd=4106 arg=537393600
cs4344_ioctl: Ignored
audio_ioctl: cmd: 4107 arg: 537393616
audio_ioctl: AUDIOIOC_ALLOCBUFFER
audio_ioctl: cmd: 4107 arg: 537393616
audio_ioctl: AUDIOIOC_ALLOCBUFFER
nxplayer_fill_common: Closing audio file, nbytes=4300 errcode=25
audio_ioctl: cmd: 4109 arg: 537393568
audio_ioctl: AUDIOIOC_ENQUEUEBUFFER
pcm_enqueuebuffer: Received buffer 0x20000010, streaming=0
pcm_enqueuebuffer: curbyte=0 nbytes=4300 nmaxbytes=8192 bytesleft=4300
pcm_dump: Wave file header
pcm_dump: Header Chunk:
pcm_dump: Chunk ID: 0x46464952
pcm_dump: Chunk Size: 4292
pcm_dump: Format: 0x45564157
pcm_dump: Format Chunk:
pcm_dump: Chunk ID: 0x20746d66
pcm_dump: Chunk Size: 16
pcm_dump: Audio Format: 0x0001
pcm_dump: Num. Channels: 1
pcm_dump: Sample Rate: 8000
pcm_dump: Byte Rate: 16000
pcm_dump: Block Align: 2
pcm_dump: Bits Per Sample: 16
pcm_dump: Data Chunk:
pcm_dump: Chunk ID: 0x61746164
pcm_dump: Chunk Size: 4256
cs4344_configure: ac_type: 2
cs4344_configure: AUDIO_TYPE_OUTPUT:
cs4344_configure: Number of channels: 1
cs4344_configure: Sample rate: 8000
cs4344_configure: Sample width: 16
cs4344_configure: ERROR: Unsupported combination of sample rate anddata width
stm32_i2s_txdatawidth: Data width bits of tx = 16
i2s_mckdivider: Entry
i2s_dump_regs: I2S2: After i2s_mckdivider
i2s_dump_regs: CR1:0000 CR2:0700 SR:0002 DR:0000
i2s_dump_regs: I2SCFGR:0e00 I2SPR:021a
i2s_dump_regs: PLLI2SCFGR:20003540
cs4344_setbitrate: sample rate=8000 nchannels=1 bpsamp=16
pcm_enqueuebuffer: Begin streaming: apb=0x20000010 curbyte=44 nbytes=4300
pcm_enqueuebuffer: Pass to lower enqueuebuffer: apb=0x20000010 curbyte=44 nbyte0
cs4344_enqueuebuffer: Enqueueing: apb=0x20000010 curbyte=44 nbytes=4300 flags=08
nxplayer_playthread: 2 buffers queued, running=1 streaming=0
audio_ioctl: cmd: 4102 arg: 0
audio_ioctl: AUDIOIOC_START
pcm_start: Defer to lower start
cs4344_start: Entry
cs4344_start: Starting worker thread
cs4344_workerthread: Entry
cs4344_sendbuffer: Sending apb=0x20000010, size=4300 inflight=0
stm32_i2s_send: apb=0x20000010 nbytes=4256 arg=0x2007dcc0 timeout=55
stm32_dmasetup: paddr: 4000380c maddr: 20000068 ntransfers: 2128 scr: 00002c40
i2s_txdma_callback: Inside callback!
cs4344_start: Created worker thread
nxplayer_playthread: Playing...
i2s_tx_worker: tx.act.head=0 tx.done.head=0x2007dca4
i2s_txdma_sampledone: result: 48
stm32_dmadump: DMA Registers: TX: Initial Registers
stm32_dmadump: LISR[40026000]: 00000000
stm32_dmadump: HISR[40026004]: 00000000
stm32_dmadump: SCR[40026070]: 00000000
stm32_dmadump: SNDTR[40026074]: 00000000
stm32_dmadump: SPAR[40026078]: 00000000
stm32_dmadump: SM0AR[4002607c]: 00000000
stm32_dmadump: SM1AR[40026080]: 00000000
stm32_dmadump: SFCR[40026084]: 00000021
stm32_dmadump: DMA Registers: TX: After DMA Setup
stm32_dmadump: LISR[40026000]: 00000000
stm32_dmadump: HISR[40026004]: 00000000
stm32_dmadump: SCR[40026070]: 00002c40
stm32_dmadump: SNDTR[40026074]: 00000850
stm32_dmadump: SPAR[40026078]: 4000380c
stm32_dmadump: SM0AR[4002607c]: 20000068
stm32_dmadump: SM1AR[40026080]: 00000000
stm32_dmadump: SFCR[40026084]: 00000027
stm32_dmadump: DMA Registers: TX: After DMA Start
stm32_dmadump: LISR[40026000]: 00000000
stm32_dmadump: HISR[40026004]: 00000000
stm32_dmadump: SCR[40026070]: 00002c4d
stm32_dmadump: SNDTR[40026074]: 00000850
stm32_dmadump: SPAR[40026078]: 4000380c
stm32_dmadump: SM0AR[4002607c]: 20000068
stm32_dmadump: SM1AR[40026080]: 00000000
stm32_dmadump: SFCR[40026084]: 0000002f
stm32_dmadump: DMA Registers: TX: At DMA callback
stm32_dmadump: LISR[40026000]: 00000000
stm32_dmadump: HISR[40026004]: 00000000
stm32_dmadump: SCR[40026070]: 00002c4c
stm32_dmadump: SNDTR[40026074]: 00000000
stm32_dmadump: SPAR[40026078]: 4000380c
stm32_dmadump: SM0AR[4002607c]: 20000068
stm32_dmadump: SM1AR[40026080]: 00000000
stm32_dmadump: SFCR[40026084]: 00000027
stm32_dmadump: DMA Registers: TX: At End-of-Transfer
stm32_dmadump: LISR[40026000]: 00000000
stm32_dmadump: HISR[40026004]: 00000000
stm32_dmadump: SCR[40026070]: 00002c4c
stm32_dmadump: SNDTR[40026074]: 00000000
stm32_dmadump: SPAR[40026078]: 4000380c
stm32_dmadump: SM0AR[4002607c]: 20000068
stm32_dmadump: SM1AR[40026080]: 00000000
stm32_dmadump: SFCR[40026084]: 00000027
i2s_dump_regs: I2S2: TX: At End-of-Transfer
i2s_dump_regs: CR1:0000 CR2:0702 SR:0002 DR:0000
i2s_dump_regs: I2SCFGR:0e00 I2SPR:021a
i2s_dump_regs: PLLI2SCFGR:20003540
cs4344_senddone: apb=0x20000010 inflight=1 result=48
_assert: Current Version: NuttX 12.5.1 675153a502-dirty Apr 23 2024 19:40:13 am
_assert: Assertion failed panic: at file: :0 task: hpwork process: Kernel 0x8005
up_dump_register: R0: 00000000 R1: 00000000 R2: 00000000 R3: 00000000
up_dump_register: R4: 2007fa64 R5: 00000001 R6: 2007c140 FP: 00000001
up_dump_register: R8: 00000000 SB: 2007dce0 SL: 00000000 R11: 00000000
up_dump_register: IP: 00000004 SP: 2007cc48 LR: 0801786f PC: 0800257a
up_dump_register: xPSR: 41000000 PRIMASK: 00000001 CONTROL: 00000000
up_dump_register: EXC_RETURN: ffffffe9
dump_stack: User Stack:
dump_stack: base: 0x2007c550
dump_stack: size: 00001984
dump_stack: sp: 0x2007cc48
stack_dump: 0x2007cc28: 00000000 00000000 00000000 00000000 00000000 00000000 08
stack_dump: 0x2007cc48: 08005fa7 2007d7f0 2007fa18 0801786f 2007d7f0 20022138 20
stack_dump: 0x2007cc68: 2007cca8 00000008 00000001 0801769d 00000001 2007cca8 00
stack_dump: 0x2007cc88: 20000010 00000030 080041a1 20021224 20021210 080041fd 00
stack_dump: 0x2007cca8: 20070008 00000030 2007da20 2007dca4 2007da6c 080082bd 20
stack_dump: 0x2007ccc8: 080081f1 00000000 2002121c 20021208 00000000 080025dd 00
stack_dump: 0x2007cce8: 2007c520 08002585 00000000 00000000 00000000 00000000 05
stack_dump: 0x2007cd08: 00000000 00000000 00000000 00000000 00000000 00000000 00
dump_tasks: PID GROUP PRI POLICY TYPE NPX STATE EVENT SIGMASK D
dump_task: 0 0 0 FIFO Kthread - Ready 000000000000k
dump_task: 1 1 224 RR Kthread - Running 000000000000c
dump_task: 10 10 100 RR Task - Ready 000000000000r
dump_task: 3 3 100 RR Task - Waiting Semaphore 000000000000n
dump_task: 12 10 246 RR pthread - Waiting MQ empty 0000000000008
dump_task: 13 10 252 RR pthread - Waiting MQ empty 0000001200000
The DMA TX Timeout was happening because I was using the DMA Channel of I2S3, but in the menuconfig I was selecting I2S2.