Reputation: 31
I'm a beginner in STM32 MCU's and I need to record an ECG signal with 1000 Hz sampling rate.
As an autonomous student, I have been reading a lot of online tutorials, but I can't understand what are the best practices to do this...I mean, should I continue learning the basics of STM32 with HALs library? And how people change the sampling rate of a signal? What are the right steps (the best practices)?
I'm a little confused about all the information that I have been learning on the internet.
Upvotes: 0
Views: 1237
Reputation: 66
Should I continue learning the basics of STM32 with HALs library? Yes, otherwise you would get into details of the ADC registers that are not that relevant to you.
What are the right steps (the best practices)? No sure about right steps but here some useful ones:
Use STM32CubeMX
Get a basic program working , blink led or reading a button...etc
Implement a simple ADC program by Enabling your ADC module trough STM32CUbeMX , read a constant voltage and store it in a variable that you can read using debug mode.
Implement a simple Timer program
Combine them both timer providing your sample rate and ADC sampling your EKG channels
Once you start doing progress more specific questions would pop up, then you can continue asking on this site :)
Recommend readings Mastering STM32 by Carmine Noviello and STM32 user manual
Upvotes: 1
Reputation: 68009
Use timer event to trigger the ADC conversion. It is 100% precise.
Upvotes: 0