HDMI audio out?


#1

Hi.

I am very happy to have my second rock960 from seeed. I mounted it inside a mechanical keyboard for an all-in-one solution, and I like it a lot. I have an issue though.

In both the built-in Android or Debian on SD card, I get no audio from HDMI.

  1. In Android settings, the audio device choices are SPDIF or HDMI Bitstream. I tried both, but did not have luck, even after rebooting. The first time I opened this setting, neither one was selected.

  2. In Debian, in PulseAudio volume control, the only output device shown is “ROCKCHIP,SPDIF Analog Stereo” … turning the volume all the way up and playing a song, I see a level indicator moving, but no sound.

I can’t try this on my other board because I accidentally damaged it while desoldering some connectors.

Any advice is appreciated!

Craig


#2

I can confirm at least on Android HDMI audio is working fine, no matter which audio setting you choose? How do you test it? The default RKMC works fine if you open some audio files from the storage.


#3

Sorry, I was testing Android wrong. I thought I would hear something while adjusting the volume and clicking on things. After your message, I tried more and played a video… I did hear it.

I wonder if anyone else has had luck playing audio in Debian. That is the OS I want to use. I think I am testing that right. Can anyone confirm? I do get sound in Debian using a USB headphone, but not HDMI.

Thanks,
Craig


#4

I can confirm that HDMI audio does not work in Debian but I do not know why.


#5

we are looking at it now, will update soon.


#6

I’ve been looking at the device tree files for some other RK3399 boards. I wonder if the ROCK960 DTS files are somewhere online, and whether they contain something like the following, of if some is missiing or not applicable. ( I don’t know much about this but am trying to learn so I can help.)

hdmi_sound: hdmi-sound {
	status = "disabled";
	compatible = "simple-audio-card";
	simple-audio-card,format = "i2s";
	simple-audio-card,mclk-fs = <256>;
	simple-audio-card,name = "rockchip,hdmi";

	simple-audio-card,cpu {
		sound-dai = <&i2s2>;
	};
	simple-audio-card,codec {
		sound-dai = <&dw_hdmi_audio>;
	};
};

hdmi_codec: hdmi-codec {
	compatible = "simple-audio-card";
	simple-audio-card,format = "i2s";
	simple-audio-card,mclk-fs = <256>;
	simple-audio-card,name = "HDMI-CODEC";

	simple-audio-card,cpu {
		sound-dai = <&i2s2>;
	};

	simple-audio-card,codec {
		sound-dai = <&hdmi>;
	};
};

spdif-sound {
	status = "okay";
	compatible = "simple-audio-card";
	simple-audio-card,name = "ROCKCHIP,SPDIF";
	simple-audio-card,cpu {
		sound-dai = <&spdif>;
	};
	simple-audio-card,codec {
		sound-dai = <&spdif_out>;
	};
};

spdif_out: spdif-out {
	status = "okay";
	compatible = "linux,spdif-dit";
	#sound-dai-cells = <0>;
};

#7

Thanks for sharing. You are right. That part is indeed missing. Now it’s updated.

https://github.com/96rocks/kernel/commit/1bbc6c266324425d3709924be253976a19da83b7

For how to build the Debian image for rock960, instructions can be found here:

https://github.com/96rocks/manifests/blob/master/README.md


#8

Thanks for the update! I wished I found that repo yesterday. I spent hours with the wrong dts files. :expressionless: