How to set USB sound card as the default sound card

USB sound card is installed on the Android system of hikey970 . How to set the USB sound card as the default sound card so that the ordinary audio player can play audio with the USB sound card.

With tinyplay, we need to specify a USB sound card when playing now, or HDMI will be used.

In ADB shell, we need to input tinyplay filename.wav - D 1 like this. How can you play with No. 1 sound card without - D parameter?

Try to add the following in / etc / asround.conf:
defaults.ctl.card 1
defaults.pcm.card 1
defaults.pcm.device 0

I still didn’t play it on the No.1 sound card

The kernel already supports USB sound card. The specified No.1 USB sound card plays. The sound is normal. Now the question is how to set the No. 1 sound card as the default sound card.

If I don’t want to modify the Android source code, can I do it by modifying the configuration file?


Were you able to solve the issue ?

If not, could you try setting CARD_OUT to 1 in device/linaro/hikey/audio/audio_hw.c file and check the results ?