ΣSigmaStudio Ask AI Русский Log in

"level" of an i2s signal

SigmaDSP & SigmaStudio maettu49 May 19, 2025 00:00 2 replies Original on forum ↗
Subscribe
maettu49 Question
May 19, 2025 00:00

hello everyone

i am a mechanical engineer dabbling in electronics. so my question may seem nonsensical and my idea cannot be realised.

i have connected an Up2Strem Pro via I2S to an APM2 (ADAU1701) and would like to expand an Technics SU-C800S with it.

i would like to install a few features. to do this, however, it should be possible to "ignore" the volume set in the spotify connect (example) so that i always have the same level as input.

Question: can the audio track and the volume (the information about how loud the audio track should be played) be separated from the digital signal at all? how is this function/information named?
if this is possible, I'm sure it has already been solved 100x and I just can't find the right post because I don't know the name of the function.
if it is not possible with an ADAU1701, would it be possible with another DAC?

Kind regards
maettu

Audio Signal Processors

software

Rev 1831

sigmastudio

SigmaDSP Audio Processors

Sigma Studio 4.7. Build 0

adau1701

dac

Show More

DaveThib Reply
May 20, 2025 00:00

Hello maettu,

What you are describing is all done in the software codec that decodes any data compression that is done during the transmission over the internet. If it includes volume to play it at then that would be handled by this software codec. Then it just outputs a digital signal to the DSP. I2S is really simple. There are no commands or other data that is sent along. Only LRCLK, BCLK and Serial Data. The bit clock is there to clock in the bits being transmitted. The LRCLK is there to provide the sampling rate and "tell" the receiving device when the start of the frame is and therefore where the first bit will be. The first bit is the sign bit followed by 23 bits of data. The format is 2's compliment. I have a video on YouTube talking about 2's compliment. Then there is eight empty bits. Then the LRCLK will go high signaling the right channel data. Although, most hardware will only look for the falling edge to signal the start of the frame and the left channel data. Then it reads in the next 64 bits to include the right channel. The format is rather simple.

It does not change the level unless something is wrong with the settings. Then the audio will either be 6dB too loud and clip or it will miss the sign bit and be very distorted.

This goes for any DAC or DSP. I2S is a standard and does not include any volume commands. The level of the audio is simply the level being transmitted with relation to 0dBFS. Zero DB Full Scale/

Dave T

maettu49 Reply
May 20, 2025 00:00

Hello Dave T

Thanks for the detailed answer. I had hoped that I could divide the signal "losslessly". These are the dreams of a machine engineer.
That makes my project more complex. But I think there is a solution with the UART interface of the Up2Stream Pro.
I will read the API parameter VOL[:{volume}] with an Arduino and generate a gain on the I2S channel with an analogue signal.
The parameter should also adjust the motorised Alps potentiometer on the preamplifier and set the main volume on the ADAU1701 via a second analogue signal.
I hope to be able to use the IR remote control, the control on the preamplifier and the mobile phone to adjust the volume.
I will probably use the parameter VOL[:{volume}] in such a way that I only allow up to approx. 35% of the maximum amplification.
That way, I can be sure that I'm not inadvertently playing much too loud.
If I ever want to "really turn it up", I can do this on the preamp's control and have the "full signal quality" on the I2S channel.

Programming the "alternating controller/target"
(case 1: volume is adjusted in the app and the alps potentiometer must be adjusted,
case 2: the potentiometer is adjusted and the API parameter VOL[:{volume}] is to be updated)
will certainly require a few lines of code in the Arduino.

Tuning the gain and main in Sigma Studio will probably also require a few iterations.
But I have already seen the necessary posts in this forum.

Kind regards
maettu