This article was reproduced from: http://blog.csdn.net/kris_fei/article/details/70053135
Platform:rockchip
Os:android 6.0
kernel:3.10.92
Taking rt5631 as an example, subsequent encounters are further increased.
Use the Tinyalsa tool to determine if the playback tone problem is in the drive layer
1| [Email protected]:/data # tinycap Test.wav
Capturing Sample:2 ch, 44100 Hz, + bit
^ccaptured 167936 Frames
[Email protected]:/data # tinyplay Test.wav
Playing sample:2 ch, 44100 Hz, + bit
View codec registers and the normal comparison :
[Email Protected]:/data # Cat/sys/kernel/debug/asoc/rk_rt5631/rt5631.2-001a/codec_reg <
00:0000
01:0000
Omitted...
View I2S registers and normal comparisons:
[Email Protected]:/data # cat/sys/kernel/debug/regmap/ff890000.rockchip-i2s/registers
00:0000000f
04:00000000
08:00033f3f
0c:00000000
10:000f0010
14:00000000
18:00000000
1c:00000000
20:00000000
28:00000000
View the SW/HW parameters when playing or recording:(Note that it is only valid at work)
[Email protected]:/proc/asound/card0/pcm0p/sub0 # cat Sw_params
Tstamp_mode:enable
Period_step:1
Avail_min:1
start_threshold:1536
stop_threshold:3072
silence_threshold:0
silence_size:0
boundary:1610612736
[Email protected]:/proc/asound/card0/pcm0p/sub0 # cat Hw_params
Access:rw_interleaved
Format:s16_le
Subformat:std
Channels:2
RATE:44100 (44100/1)
period_size:512
buffer_size:3072
The hardware part uses the oscilloscope to measure the i2s whether there is a signal
[RK3288] [Android6.0] Audio Debugging Method Summary "Go"