cancel
Showing results for 
Search instead for 
Did you mean: 

Please improve DFSDM section of reference manual.

gregstm
Senior III

I've managed to get the DFSDM working with a PDM microphone (on a STM32L496 board) - using direct access to registers. But the documentation often made things more difficult than they needed to be. Just a few extra sentences, less ambiguous language and better graphs could have made the whole process a lot easier, for example -

  • mention that a sinc filter is essentially a moving average
  • explain that sinc2, sinc3... are just cascaded sections of a sinc filter
  • check whether the graph of the sinc3 is not actually a sinc5 filter (which it seems to be in other docunentation I've seen)
  • change the X-axis of the graph from "Normalized frequency (Fin/Fdata)" to the simpler, less confusing "F (data rate)
  • Have a graph showing the frequency response of the different order filters together
  • highlight the fact that regular conversions offer a faster data rate, independent of filter order
  • recommend that when using regular conversions, you choose the oversampling rate to get the data rate you want then select the filter order to get the resolution you want
  • in the data rate sections - don't just say the ambiguous/confusing "FAST=0", maybe say "Fast mode disabled (FAST=0)"

Besides all of the above, I'm looking forward to being able to use the greater variety of PDM microphones, because the I2S microphones I tried all had poor low frequency response for my application.

9 REPLIES 9
Imen.D
ST Employee

Hello @Community member​ ,

Thank you for your reports here. We really appreciate your help to improve our documentation.

I raised your feedback internally to the appropriate team for further review. I will keep you informed about the taken actions/explanation if needed.

Best Regards,

Imen

When your question is answered, please close this topic by clicking "Accept as Solution".
Thanks
Imen
gregstm
Senior III

Glad to assist. Sometimes as an engineer you have a part in your hand ( a PDM microphone), and you want to get it up and running as fast as you can. For those of us who prefer the simplicity and efficiency of writing direct to registers, even a simple trace of the registers that need to be initialised to get a microphone running would have saved me hours. Anyway, my PDM microphones that supposedly have a flat frequency response down to 28Hz arrived today - let's see how they go.

Clear examples and appnotes.

I'm crying for these here for years.

We've got Cubes instead.

JW

Igor Cesko
ST Employee

Hi gregstm , waclawek.jan ,

We produced application note for better explanation of the DFSDM peripheral (AN4990) - there is written in more "easy" or "less technical" style (less "digital signal processing" theory and more "simple" explanation) how sigma delta modulator works, how works the following filter (averaging), comparison with PWM, understanding the "noise shaping" (with comparison with PWM), graph examples of signals in sigma delta modulator, graphs from digital filters outputs (various filter orders explanation practically), ... and something else. There is also attached XLS file with simulation of DFSDM peripheral and there is XLS sheet for DFSDM peripheral configuration according customer needs (to choose appropriate filter parameters with given input and output parameters of application).

Please try to look on this application note - AN4990:

https://www.st.com/resource/en/application_note/an4990-getting-started-with-sigmadelta-digital-interface-on-applicable-stm32-microcontrollers-stmicroelectronics.pdf .

I hope this AN can offer better understanding of DFSDM with less theory.

The description in reference manual is more technical and more strict according "higher level" theory - for more experienced users. We let more space for simple explanation for less experienced users in application note AN4990.

Regards

Igor

Hi Igor,

> There is also attached XLS

Where?

[EDIT] This one https://www.st.com/content/ccc/resource/technical/document/technical_article/group0/1b/40/1d/43/1b/8d/47/65/dfsdm_tutorial/files/dfsdm_tutorial.xlsx/jcr:content/translations/en.dfsdm_tutorial.xlsx ? While in pdf the [TUTORIAL] is highlighted, it does not appear to contain a valid link. [/EDIT]

Thanks,

Jan

@Igor Cesko​ 

Igor Cesko
ST Employee
gregstm
Senior III

Hi Igor,

thanks for the update. Between the reference manual and the application note, the one thing I think would have helped the most is a simple trace/list of values to write to the DFSDM to get it up and running quickly - then I could study (reverse engineer?) the values and make sense of it that way.

Anyway, the DFSDM works great, and with a high quality PDM microphone it is very sensitive (so sensitive in fact, that I might have to build a soundproof container to try and figure out the noise floor).

> That one thing I think would have helped the most is a simple trace/list of values to write to the DFSDM

That's exactly what I meant by clear examples.

AN4990 may be a good introductory material, but it should be followed by "executive" ANs ("dozens of AN per peripheral") and accompanying register-based examples. No, Cubes are not a palatable substitute.

But even then, AN4990/xls could/should refer directly to registers and their fields when talking about individual features, as gregstm said above.

JW

Igor Cesko
ST Employee

Hi waclawek.jan

Yes - we offer examples for DFSDM usage based on HAL functions only (but this is no simple direct write to DFSDM registers). The DFSDM acts as ADC - so its functionality is similar: load into DFSDM registers filters parameters, some clock speed and some optional config parameters and start it as ADC. XLS is designed to help with filter values : what to load into DFSDM registers (filter parameters) according user requirements (for beginners with digital filters).

But we have no simple example which manipulates directly with DFSDM registers. So - some "reverse engineering" for HAL DFSDM examples should be done.

Regards

Igor