Can the ADAU1450 be used to data compress digital I2S microphone output from 24 bits to 16 bits?
Well, at the risk of sounding like a wise guy, I don't mean to. What do you get when you truncate the bottom 8 bits? well, ... 8 bits less resolution! You still will have the same voltage out but just have fewer steps in the data. Each bit is a 16 bit step size rather than a 24 bit step size.
To put it another way, you are dividing the full scale voltage by 2^16 rather than 2^24. Each increment will be larger with the upper 16 bits of a 24 bit data word. You are truncating the steps between each 16 bit number. You will lose some SNR performance.
Here is what the bottom 10 bits will do for a 24 bit number:
Then when you truncate the data you will get:
You lost all the smaller steps in-between the number 1 and 2 of the binary 16 bit word. You will not lose the signal level as long as it was loud enough of a signal to turn on the LSB of a 16 bit number. You will lose anything below a 16 bit level. With a 16 bit signal you can only represent a signal that is -96 dBFS. (16 bits x 6db/bit) So a -100dBFS signal is truncated. That said, a "24 bit" converter is not able to obtain the theoretical -144 dBFS of SNR. Most DACs will not come close to -120 dBFS which is 20 bits of resolution. So by truncating down to 16 bits you are getting the full 16 bits of performance.
For serial port 0, you will can change the word length register to 16 bits and the truncation will be done automatically in the serial port. No need to do it with the DSP. I tested it this morning on this part to make sure it worked. I looked at the actual digital data and it was truncating the incoming data to 16 bits.
Register 0xF200 bits 6:5 is the register that needs to be changed from 0b00 to 0b01.
What do you mean by compress? If you simply truncate the bottom 8-bits you will have 16 bit output from the microphone.
This can be done with the DSP but you can also do it right at the serial input port. Just set it for 16 bits. Another way may be to set the microphone output to 16 bits if it is an option.
Now, I have not tried to set the serial ports on this part to 16 bits and feed it 24 bit audio but I have done it on other parts. I can try this and get back to you about it.
We are connecting the INMP441 (I2S output) to the ADAU1450. We want to be able to use 16-bit sample size audio instead of the 24-bit that INMP441 outputs by default.
What is lost if the bottom 8-bits are truncated?
Yes, I am seeing that in SIgma Studio now. Looks like you have us a couple of options to get to 16 bits.
I was also wondering about the sampling rate while using Sigma Studio. If I use a sampling rate at the top of Sigma Studio and propagate it, will that sampling rate still exist when I save the hex file that will be used to load the ADAU1452? Or do I still have to set that in the register control options for Serial data input?
The Serial Ports tab option as Fs/4, which would be 48 KHz/4 = 12 Khz. How would I get that to 8 KHz in the DSP without having Sigma Studio do that at the top?
Retrieving data ...