AnsweredAssumed Answered

STM32F746-DISCO Struggling to make a working pass-through Audio

Question asked by aaa.aaa.002 on Jan 10, 2016
Hello everyone,

I wanted to make some applications on STM32F746-DISCO with use of WM8994 codec and I decided to start with making a working pass through audio - connect to jack input sound source and listen to it on output one.

I read the examples and made a simple code

#define AUDIO_PBUFFER_SIZE 128

uint32_t *buffer[AUDIO_PBUFFER_SIZE];
int main(void){

HAL_Init();

SystemClock_Config();

BSP_AUDIO_IN_Init(INPUT_DEVICE_INPUT_LINE_1, 100, AUDIO_FREQUENCY_22K);
BSP_AUDIO_OUT_Init(OUTPUT_DEVICE_HEADPHONE, 100, AUDIO_FREQUENCY_22K);

BSP_AUDIO_IN_Record( (uint16_t *)buffer, AUDIO_PBUFFER_SIZE);
BSP_AUDIO_OUT_Play( (uint16_t *)buffer, AUDIO_PBUFFER_SIZE);

while(1)
  {
    // Infinite loop
  }
}

I have received data on receiver data register, but there is no transfer to transmiter data register - I used the debugger and there is no change in it and also the is a OVRUDR - underrun flag and FREQ - FIFO request.

I have made few variants of code - including a one, where I just took the hex address of data registers and copied the data from one address to another - but it didn't change a thing.

Clearly, I am lost. Could someone please suggest me where I am making an error? Any help appreciated.

Outcomes