Closed SparkMike77 closed 6 years ago
There is a way to just get BPM number. Please check out the PulseSensor Playground Tools https://github.com/WorldFamousElectronics/PulseSensorPlayground/blob/master/resources/PulseSenaor%20Playground%20Tools.md
a call to getBeatsPerMinute() will return the latest BPM value (int). You can simply comment out the call to pulseSensor.outputBeat() and just do you own thing instead.
SparkMike77, I drafted some code here for you. It's not pretty, but it does the behavior you requested. Try this code in a new Sketch, or just run it as an ".ino" file in Arduino. https://github.com/yury-g/ReadMePlayground/blob/master/PulseSensor_BPM_Serial_Print.ino
This is a screengrab of it working correctly: Let me know if it helps!
Mike, Try the sketch at this link. It is BPM and BPM-only via our new Library. ; )
Thanks Guys, I had completely forgotten to check back and was hammering on my own library (really poorly). This looks exactly like what I need!
Is there somewhere that I can see the code for the function
getBeatsPerMinute()
Thanks!
The actual function is pretty simple, and it's on line 87 here https://github.com/WorldFamousElectronics/PulseSensorPlayground/blob/master/src/utility/PulseSensor.cpp
The function that determines BPM is called processLatestSample, on line 122 of the same file.
Thank you, Joel. I appreciate this. -Shawn Haarer
On Wed, Jul 18, 2018 at 10:46 AM, Joel Murphy notifications@github.com wrote:
The actual function is pretty simple, and it's on line 87 here https://github.com/WorldFamousElectronics/PulseSensorPlayground/blob/ master/src/utility/PulseSensor.cpp
The function that determines BPM is called processLatestSample, on line 122 of the same file.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/WorldFamousElectronics/PulseSensorPlayground/issues/29#issuecomment-405978980, or mute the thread https://github.com/notifications/unsubscribe-auth/Ak6kbCR5Q7ZAbQcx6sADxHgspVH9OPlhks5uH1hzgaJpZM4RKrmC .
I'm looking for how to just pull the BPM number, not plot it on a graph but all the BPM sketches have a graphing output.
I'm assuming instead of calling pulseSensor.outputBeat() there's a way just to call for the numeric BPM?