Spdif-out overlay

overlay to enable the spdif interface on GPIO0_C1

https://raw.githubusercontent.com/eragefe/Rockpi-S/master/spdif_out.dts

2 Likes

You can send a PR on github and put it into the kernel overlay.

Did that today.

@jack could you please also add the overlay for I2S playback?

it was posted in another thread by @eragefe

Both are merged now.

1 Like

Hi @eragefe , I just tried your overlay to activate spdif out, however I had no success. I connected a scope to the spdif out/GPIO0_C1 pin but it seems to be dead, only a straight zero line.
Any idea what might be missing? I just added the spdif-out overlay in uEnv.txt, booted and tried to play some audio.
aplay -L shows the spdif-out, kernel is 4.4.134b from the eragefe github. i2s works without any problems.

Hej Tobias.
Honestly I have never tried The spdif overlay with that kernel I build that kernel mainly for I2S and IR purposes I have modified the I2S driver to keep the signals on even when a track is stopped or paused to get rid of those pops and clicks that driving me crazy between the tracks, and I have build the IR modules that are missing in the official kernel in it. So you shouldnt have any benefits using that kernel with spdif.
BUT if you see the card with aplay -l it should work unless another overlay uses that pin. There is a guide in this forum for example to enable IR with lirc and that guide uses the spdif pin for the IR sensor.
Are you using the overlay on my github repo or the overlay I have sent to the radxa repo?
Are you using the radxa image or Armbian?

Hi,
I am using the radxa image, I did not find any Armbian with 4.4 kernel and your overlays are not included in the 5.x kernel.
Tried both your kernel and the one from raxda packages with the bundled overlays. It was a fresh install, so I guess the pin should not be in use by anything else but I will check it again later today. Thanks for your response!

Hi eragefe,
tonight I tried the 4.4.143-61-rockchip… Kernel from radxa image. After activating spdif-out overlay (no other suspicious overlays active) I see the spdifout audio device (and a lot of loopback devices).
“aplay -D plughw:CARD=spdifout /dev/urandom” works, the scope on the spdif pin shows a signal. No idea what went wrong last time, but thank you for responding and I’m sorry for bothering you!

Hi @eragefe … a bit cheeky, but would you know how to adapt your overlay to enable SPDIF on the Rock 5b?

I’ve tried but no luck… thread here .

I think I’m stuck with the i2s bit.

Thanks.