32 bit ES9038 #1098
DJ202
started this conversation in
Show and tell
32 bit ES9038
#1098
Replies: 1 comment
-
Thanks for your contribution. For all others who also want to use such a DAC, I have added your solution to the examples. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
There are some great sounding and cheap 32 bit decoders available like boards with the ES9038Q2M that don't work because the library outputs 16 bits data.
You only need to change 3 lines lines of code to change it to 32bit:
Audio.cpp
in Audio::Audio
m_i2s_std_cfg.slot_cfg = I2S_STD_PHILIPS_SLOT_DEFAULT_CONFIG(I2S_DATA_BIT_WIDTH_32BIT, I2S_SLOT_MODE_STEREO);
in Audio::resampleTo48kStereo:
m_samplesBuff48K[outputIndex * 2] = clipToInt16(outLeft);
m_samplesBuff48K[outputIndex * 2 + 1] = 0x00;
m_samplesBuff48K[outputIndex * 2 + 2] = clipToInt16(outRight);
m_samplesBuff48K[outputIndex * 2 + 3] = 0x00;
Beta Was this translation helpful? Give feedback.
All reactions