Thank you for your donation!


Cloudsmith graciously provides open-source package management and distribution for our project.


S/PDIF input with parametric EQ?
#1
Hi folks,

I am keen to add S/PDIF input, so that I can route my CD player through Moode in order to benefit from room correction that I implement using the parametric EQ.

I understand that at present, the only supported S/PDIF input option is the Audiophonics ES9038 board, but I if I understand these posts correctly, the audio is not (cannot be?) routed via the parametric EQ.

Is there a way (even at the command line) to adjust the routing for the Audiophonics board to achieve my aim? Or has anybody else implemented a different S/PDIF input HAT (e.g. the HiFiBerry Digi I/O) to feed S/PDIF input into the Moode playback path and could share their configuration?

Many thanks,

Ian
Reply
#2
The only two input capable I2S audio devices that were integrated into moOde's WebUI were the Audiophonics ES9038 DAC (S/PDIF) and the Hifiberry DAC+ ADC (Analog). They each use different ALSA commands to switch to their input port.

- Audiophonics: amixer -c 0 sset "I2S/SPDIF Select" SPDIF.
- Hifiberry: alsaloop

The Audiophonics device does hardware level routing between S/PDIF in and analog out and thus it's not possible to perform DSP on the signal. The Hifiberry device routes the audio using ALSA so there might be an ALSA configuration that could route the audio first to a DSP plugin then to analog out but I have no idea what that config might look like.

I think Hifiberry has a guide on how to use ALSA with their I/O devices so you might want to ask about this in their Forum.

Another option would be to use a multi-io USB audio device and CamillaDSP in moOde. I don't have experience with this but @bitlab has a nice article on his blog https://www.bitlab.nl/page_id=1103
Enjoy the Music!
moodeaudio.org | Mastodon Feed | GitHub
Reply
#3
Thanks Tim,

I'll look into the Bitlab article to see what's what.

As for S/PDIF-in HATs, if I'm understanding correctly the key question to ask manufacturers is whether audio switching is done in software? I.e. can the digital signal be fed over the I2S bus to the rPi so as to be manipulated in software before output?

Thanks,

Ian
Reply
#4
The question is not really how the switching is done but rather can the audio coming in via the input port be captured by either ALSA or CamillaDSP and then processed before being sent to the analog outs.
Enjoy the Music!
moodeaudio.org | Mastodon Feed | GitHub
Reply
#5
Thanks for the clarification - I'll start some research.
Reply
#6
https://hifimediy.com/product/hifime-ur2...converter/

Hi Dr Diem, you can use this cheap device to "add" a spdif input to MOode. However even with the link provided by bitlab,https://www.bitlab.nl/page_id=1103 I could not manage to capture the hifimediy in alsa. It would be a nice to have in MoOde, but I have zero skill, maybe you will be more successfulSmile
Reply
#7
Thanks for the info Tantor!

I would guess you would need to experiment with lsusb to try to 'connect' the USB output of that convertor to something that ALSA could read. My current idea is to try this board. I need to email the vendor to understand how the S/PDIF digital signal is 'presented' to the RaspberryPi to determine whether ALSA can pick it up.

I'll report back when I know,

Ian
Reply
#8
Well, bad news for this idea (No! See update below...). According to Ian Canada, whose wide array of properly hi-fi rPi HATs suggest that he should know what he's talking about, HATs that provide an old-school digital input (S/PDIF, AES/EBU, TOSLink, etc.) cannot be routed to Linux running on the rPi host due to the clocking requirements of the interface. They can only be routed to other HATs - a DAC for example. This fits with Tim's explanation for the sole currently-supported digital-in HAT.

Ah well, it was a nice idea, but not one that can be implemented via the OS on an rPi.


UPDATE Feb 2024: Re-reading the thread and the links provided by others who've contributed, I think I misunderstood Ian Canada's offline explanation to me. I now think he was telling me that his S/PDIF input product (the ReceiverPi) cannot be used in the way I would like, not that S/PDIF input to rPi for DSP processing is entirely impossible. The corollary though, given the apparent technical quality of his products, is that the potential solutions will not be able to be reclocked to reduce/eliminate jitter, meaning that top-end audiophile quality will not be possible. This hypothesis is supported by HifiBerry's FAQ about their digital input products (see "Q: But I read a lot about jitter problems…") . Still, worth continuing to experiment..
Reply
#9
(08-04-2023, 06:52 PM)dr.diem Wrote: Well, bad news for this idea. According to Ian Canada, whose wide array of properly hi-fi rPi HATs suggest that he should know what he's talking about, HATs that provide an old-school digital input (S/PDIF, AES/EBU, TOSLink, etc.) cannot be routed to Linux running on the rPi host due to the clocking requirements of the interface. They can only be routed to other HATs - a DAC for example. This fits with Tim's explanation for the sole currently-supported digital-in HAT.

Ah well, it was a nice idea, but not one that can be implemented via the OS on an rPi.

Well it is possible:

https://www.audiosciencereview.com/forum...ial.29656/
Reply
#10
I need SPDIF input to my Allo Usbridge Signature with Moode Player. And be able to route the captured signal to CamillaDSP. I found Bitlabs manual how to do it. It looks great and exactly what I need. Iam new owner of Usbridge and have no skills with linux and programmng as well. But Iam quickly learning linux commands. I found some strange and I need help.

Iam using Allo Usbridge Signature and Moode Player. In future I will buy some good external USB DAC. But at this moment Iam using Axagon 7.1 soundbox as external usb soundacrd and dac. Sound output from this device is working. But Iam not able to capture the sound from coaxSPDIF or tosSPDIF input.

arecord -l
...it gives me info that the external usb soundcard is CARD 1, DEVICE 0

arecord -D hw:1,0 dump-hw-params
...it gives me info that format is S16_LE, channels 2, sample rate 44100 - 48000

sudo arecord -f s16_LE -c2 -r44100 -D dsnoop:1,0 test.wav
...instead of capturing a playing CD, linux write me back: Warning: rate is not accurate (requested = 44100Hz, got = 48000Hz)                    please, try the plug plugin

It seems that the usb soundcared is running on sample rate 48000 instead od CD sample rate 44100. How I can set the device to sample rate 44100hz. I will be using it just for playing CDs.
Reply


Forum Jump: