Skip to main content
SG.4
Associate III
February 22, 2021
Question

Hello ST community Experts , MEMS mic + STM32f4xx evaluation board I am trying to stream PCM data serially on UART . Some issues please help?

  • February 22, 2021
  • 7 replies
  • 1264 views

Configurations :- STM32CubeMX M4-F446RE+ICS43432 mic

sysclk-168MHz HSE, DMA- circular,SPI2_RX ,half word

I2S2 - half duplex ,master receive mode 32KHz audio frequency

USART2 - 9600 B/s

PDM2PCM middleware use for conversion

..

1)Can Anyone suggest is there anything wrong with the configuration?

2) Now how do I acquire the PCM streaming data to print serially over UART?

3) And how I interface the BSP package before generating the code in the cubeMX

....

Thanks in advance.

This topic has been closed for replies.

7 replies

Vangelis Fortounas
Associate II
February 22, 2021

Hello

9600 bps is not adequate rate for this job

32khz sample rate with 16 bit samples need at least 640kbps rate .

SG.4
SG.4Author
Associate III
February 22, 2021

Hi @Vangelis Fortounas​ ,

Appreciate your reply thank you .

ok will look into it.

..

Further of the question any ideas answers if you have any experience please support.

Vangelis Fortounas
Associate II
February 22, 2021

Hello

I have no experience for audio over async serial transportation but i use serial ports.

UART can't send 16 bits and how the receiver will handle the situation that one byte is missing ? (everything is shifted and garbaged )

A "sync pattern" added every some words is fair solution for synchronization between transmitter and receiver but adds some data overhead.

if data integrity is crucial need a second layer tranportation protocol with packet counting , checksums, ACKs, resend, etc.