Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- STMicroelectronics Community
- STM32 MCUs
- STM32 MCUs products
- Re: Software digital low pass filter (40Hz)?

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page

Software digital low pass filter (40Hz)?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

2009-09-13 05:57 PM

Software digital low pass filter (40Hz)?

6 REPLIES 6

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

2011-05-17 04:23 AM

I want to use a Software digital low pass filter(3db freq=40Hz) in my STM32F103CB. The filter will be fed the data of ADC output and the filter will output data that is 40Hz filtered.

Does anyone have the software low pass filter sample code that can be added to my project and can be run on STM32F103CB MCU? Thanks a lot!- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

2011-05-17 04:23 AM

Have you tried the DSP library available on the STM32 downloads page:

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

2011-05-17 04:23 AM

Can you tell me which file or sample code is about the low pass filter design? Thanks a lot!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

2011-05-17 04:23 AM

hi,

If you do a search on DSP on forum main page you find a lot of topics. Take a look in one of my earlier posts: -G- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

2011-05-17 04:23 AM

This is a handy site:

http://www.dsptutor.freeuk.com/index.htm I used the FIR filter designer to come up with some coefficients for a low pass filter, and had a look at some of the java source to figure out how to apply them.- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

2011-05-17 04:23 AM

Hi guyvo67, thank you!

Now I knoe how to generate the coefficients I need. I download the source code of FIR Digital Filter Design Applet fromhttp://www.dsptutor.freeuk.com/FIRFilterDesign/FIRFilterDesign.html

I need 360Hz sample rate. Should I change the ''rate'' of FIRFilterDesign.java from 8000.0f to 360.0f? And should I change the ''fN'', ''f1'' and ''f2'' of FIRFilter.java for 360Hz setting? How to change? On the other hand, I want to use fir_16by16_stm32 function to filter my data from ADC output. The data from ADC output is a data array that is ''unsigned short x[360]''. I find that for fir_16by16_stm32 the length of input vector ahould be equal to M+N-1. (output vector of length N, coefficients vector of length M). I want to input 360 16-bit data to fir_16by16_stm32 and get 360 16-bit filtered data from fir_16by16_stm32. Can you tell me how to design for fir_16by16_stm32 to fit my need? Thank you very much!
Related Content

- If I, call "HAL_ADC_Start_DMA();" outside of while loop, it's not working. If I, call it inside the while loop, it's working. in STM32CubeIDE (MCUs)
- STM32F407 Ethernet LwIP + FREERTOS ping break Hard fault in STM32 MCUs products
- Nucleo STM32H723ZG - CAN not working in STM32 MCUs products
- STM32F373 Sigma Delta ADC: Filter Specs & FFT plots ? in STM32 MCUs products
- STM32L432KC Timer interrupt only triggers once in STM32 MCUs Embedded software