I have a board configured as follows:
- Chip: iM8MP
- RAM: 4GB
- EMMC: 8GB.
- Audio Codec: TLV320DAC3100IRHBRYocto BSP: https://github.com/nxp-imx/imx-manifest/blob/imx-linux-mickledore/imx-6.1.36-2.1.0.xml
I have successfully brought up the Audio codec and tested it with a wave file.
$ aplay 24_48k_PerfectTest.wav
Playing WAVE '24_48k_PerfectTest.wav' : Signed 24 bit Little Endian in 3bytes, Rate 48000 Hz, Stereo
The sound comes out accurately and clearly. I continued testing using gst-play-1.0, because I wanted to play many other audio formats. I have a problem here. Take a look at the log below.
gst-play-1.0 24_48k_PerfectTest.wav
[ 26.593952] audit: type=1701 audit(1672502419.824:18): auid=4294967295 uid=0 gid=0 ses=4294967295 pid=440 comm="vsidaemon" exe="/usr/bin/vsidaemon" sig=6 res=1
[ 36.834279] audit: type=1701 audit(1672502430.068:19): auid=4294967295 uid=0 gid=0 ses=4294967295 pid=441 comm="vsidaemon" exe="/usr/bin/vsidaemon" sig=6 res=1
[ 37.718446] audit: type=1334 audit(1672502430.952:20): prog-id=10 op=UNLOAD
[ 37.725453] audit: type=1334 audit(1672502430.952:21): prog-id=9 op=UNLOAD
Press 'k' to see a list of keyboard shortcuts.
Now playing /home/root/24_48k_PerfectTest.wav
Redistribute latency...
Redistribute latency...
0:00:05.5 / 0:00:13.2
/usr/bin/vsidaemon crashed multiple time, and after about one minute the sound is emitted. I would like some suggestions to trouble shoot this problem? I think the correct case should be: vsidaemon doesn't crash and the sound is emitted immediately.
I tried gplay-1.0 and got them same problem
gplay-1.0 24_48k_PerfectTest.wav
FSL_GPLAY2_01.00_LINUX build on Aug 4 2023 01:42:29
[ 82.101677] audit: type=1701 audit(1672502470.392:20): auid=4294967295 uid=0 gid=0 ses=4294967295 pid=507 comm="vsidaemon" exe="/usr/bin/vsidaemon" sig=6 res=1
[ 92.133255] audit: type=1701 audit(1672502480.424:21): auid=4294967295 uid=0 gid=0 ses=4294967295 pid=508 comm="vsidaemon" exe="/usr/bin/vsidaemon" sig=6 res=1
playbin3 is enabled
=========== fsl_player_play() ==================
FSL_GPLAY2_01.00_LINUX build on Aug 4 2023 01:42:29
[h]display the operation Help
[p]Play
[s]Stop
[e]Seek
[a]Pause when playing, play when paused
[v]Volume
[m]Switch to mute or not
[>]Play next file
[<]Play previous file
[r]Switch to repeated mode or not
[u]Select the video track
[d]Select the audio track
[b]Select the subtitle track
[n]Select adaptive playback track
[f]Set full screen
[z]resize the width and height
[t]Rotate
[c]Setting play rate
[i]Display the metadata
[x]eXit
State changed: buffering
State changed: playing
[Playing (No Repeated)][Vol=1.0][00:00:00/00:00:13]
I attched my audio file.
where do you need get audio? I tested gstreamer command as below, and can get audio from headphone,
when use gplay-1.0, get the message as below, which means gplay uses imxaudioxcvr codec, this codec isn't supported by current gstreamer, so I use another command to replace
firstly you need use aplay -l to check all of codecs current bsp support
then I used command to test by wm8960 codec as below
gst-launch-1.0 playbin uri=file:///media/24_48k_PerfectTest.wav audio-sink="alsasink device=hw:1,0"