Skip to main content
Visitor II
March 2, 2021
Solved

Hello Experts of ST community, I have mems mic and stm32f4xx nucleo board and collected the pcm format data in a log files. Now my query is how to convert them into .WAV format ? and How to validate the the values are exactly accurate?

  • March 2, 2021
  • 1 reply
  • 812 views

Can someone help me figuring out how do we conclude the obtain pcm values are accurate and can there be any references to validate it and test it back?

Any suggestions please help?

    This topic has been closed for replies.
    Best answer by Ozone

    > ...how to convert them into .WAV format ?

    WAV is a simple container format. There are many good libraries available, like portaudio, asoundlib, alsa, or bass.

    I would do that on PC side, but you could port one of those libs to the MCU if you like.

    > ... and How to validate the the values are exactly accurate?

    Specify "exactly accurate".

    Sound is differential air pressure. Unless you can produce an exact quantity of this non-electrical unit, there is no "exactly accurate".

    You can record with a reference system, and compare both recordings.

    1 reply

    OzoneAnswer
    Explorer
    March 2, 2021

    > ...how to convert them into .WAV format ?

    WAV is a simple container format. There are many good libraries available, like portaudio, asoundlib, alsa, or bass.

    I would do that on PC side, but you could port one of those libs to the MCU if you like.

    > ... and How to validate the the values are exactly accurate?

    Specify "exactly accurate".

    Sound is differential air pressure. Unless you can produce an exact quantity of this non-electrical unit, there is no "exactly accurate".

    You can record with a reference system, and compare both recordings.