2024-01-26 07:13 PM
Hi all,
I'm using an STM32F746 Disco board. I'm not sure if the code (below) for this codec came from one of the examples for this board or other disco or nucleo board but it is from an STM32 example or board or github.
There are three lines for "WM8994 Errata Work-Arounds". I tried to look for the errata sheet for the WM8994 but I can't find it. The datasheet says not to write to register not shown in the map. The registers being addressed in the "Work-Arounds" are not shown in the map. What do the "Work-Arounds" lines fix or do?
Here is the beginning lines of wm8994_Init:
uint32_t wm8994_Init(uint16_t DeviceAddr, uint16_t OutputInputDevice, uint8_t Volume, uint32_t AudioFreq)
{
uint32_t counter = 0;
uint16_t output_device = OutputInputDevice & 0xFF;
uint16_t input_device = OutputInputDevice & 0xFF00;
uint16_t power_mgnt_reg_1 = 0;
/* Initialize the Control interface of the Audio Codec */
AUDIO_IO_Init();
/* wm8994 Errata Work-Arounds */
counter += CODEC_IO_Write(DeviceAddr, 0x102, 0x0003); <----- This line
counter += CODEC_IO_Write(DeviceAddr, 0x817, 0x0000); <----- this line
counter += CODEC_IO_Write(DeviceAddr, 0x102, 0x0000); <----- and this line
Thanks.
2024-01-30 05:10 AM
Hello @Rodo ,
I'll check the functionality of these lines of code.
But, do you encounter any issues when using wm8994.c?
Thank you.
Kaouthar
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
2024-01-30 10:28 AM
2024-01-30 10:52 AM
Probably details you'd need to source from Wolfson/Cirrus directly TBH