diff options
author | Shengjiu Wang <shengjiu.wang@nxp.com> | 2020-04-29 17:38:44 +0800 |
---|---|---|
committer | Shengjiu Wang <shengjiu.wang@nxp.com> | 2020-04-29 18:35:44 +0800 |
commit | 326442c3276b2e852fb147cd752b62ab7de81ad2 (patch) | |
tree | c090c4c6270b4b9f14ce44ed17b674cbafb59c41 /sound/soc/fsl/imx-cdnhdmi.c | |
parent | 81875f6f91bfa6a74fa52ad766d9f3d4366af785 (diff) |
MLK-23642-2: ASoC: hdmi-codec: Add iec958 kcontrol
Add iec958 controls, then user can set the AES from user space.
The command is "iecset", which is in alsa-utils.
For HBR test, we need do below steps
1. Generate iec61937 mat stream by ffmpeg.
ffmpeg -i input.mlp -acodec copy -f spdif output.spd
2. Add iec60958 header by iec958 plugin in alsa-lib
<confdir:pcm/iec958.conf>
IMX-CDNHDMI.pcm.iec958.0 {
@args [ CARD AES0 AES1 AES2 AES3 ]
@args.CARD {
type string
}
@args.AES0 {
type integer
}
@args.AES1 {
type integer
}
@args.AES2 {
type integer
}
@args.AES3 {
type integer
}
type iec958
slave {
format IEC958_SUBFRAME_LE
pcm {
type file
slave.pcm null
file "output.spd.iec958"
format "raw"
}
}
status [ $AES0 $AES1 $AES2 $AES3 ]
preamble.z 0x1
preamble.x 0x0
preamble.y 0x0
}
aplay -Diec958:3,AES0=0x06,AES1=0x80,AES2=0x02,AES3=0x09 -r 192000 -c 2 -f S16_LE output.spd
3. Enable non-linear pcm.
iecset -c 3 audio off
4. aplay -Dcdnhdmi8ch -r 192000 -c 8 -f S32_LE output.spd.iec958
pcm.cdnhdmi8ch {
type dshare
slave {
pcm "hw:3,0"
channels 8
rate 192000
format S32_LE
}
ipc_key 5144458
bindings.0 0
bindings.1 4
bindings.2 1
bindings.3 5
bindings.4 2
bindings.5 6
bindings.6 3
bindings.7 7
}
5. Test is finished, disable non-linear pcm
iecset -c 3 audio on
Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com>
Reviewed-by: Viorel Suman <viorel.suman@nxp.com>
Diffstat (limited to 'sound/soc/fsl/imx-cdnhdmi.c')
0 files changed, 0 insertions, 0 deletions