从模式的时候需不需要设置ALB?我怎么进不了DMA中断。
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.
谢谢您的回复,不是为了测试,我是要用DM3730的McBSP3接口连接蓝牙的PCM,McBSP3是Slave模式。
Linux下的驱动我看了一下,按照它的例子添加了McBSP3接口的驱动(sound/soc/omap/omap3stalker.c)。
但是现在用aplay/arecord进行测试发现无法进入DMA中断。
蓝牙那端的PCM是Master:
(DM3730) (蓝牙)
MCBSP3_CLKX <--- PCM_CLOCK
MCBSP3_DR ---- PCM_OUTPUT
MCBSP3_DX ---- PCM_INPUT
MCBSP3_FSX <--- PCM_SYNC
我看到官方的数据手册(dm3730.pdf)里写着
4-pin mode: dx and dr as data pins; clkx and fsx pins as control pins. The clkx and fsx pins are
internally looped back, via software configuration, respectively to the clkr and fsr internal signals for
data receive.
这是说clkx、fsx驱动clkr、fsr需要软件配置(寄存器)吗?这个和DLB、ALB有关系吗?
我对照着技术手册(sprugn4r.pdf),看了一下Linux下的McBSP驱动,寄存器配置是对的。
还有我用示波器看到PCM_SYNC、PCM_CLOCK、PCM_OUTPUT有波形,和sprugn4r.pdf中说的PCM Mode 1相似。
我是有什么地方没有配置正确吗?
这个是测试打印信息(我把寄存器的值打印出来了)
root@dm37x-evm:~# arecord -D hw:0,1 -f S16_LE -r 8000 -c 1 abc.pcm
Recording WAVE 'abc.pcm' : Signed 16 bit Little Endian, Rate 8000 Hz, Mono
[16390.700134] config->spcr2 560
[16390.704559] config->spcr1 32816
[16390.707702] config->rcr2 65
[16390.710510] config->rcr1 64
[16390.713592] config->xcr2 65
[16390.716369] config->xcr1 64
[16390.719207] config->srgr2 15
[16390.722351] config->srgr1 1792
[16390.725402] config->mcr2 0
[16390.728302] config->mcr1 0
[16390.731018] config->pcr0 0
[16390.733734] config->xccr 4105
[16390.736968] config->rccr 2057
hw_readi: frames = 112, result = -5, err = -5
arecord: pcm_read:2096: read error: Input/output error