Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Code on RPi Pico #4

Closed
ebolisa opened this issue May 20, 2021 · 8 comments
Closed

Code on RPi Pico #4

ebolisa opened this issue May 20, 2021 · 8 comments
Assignees
Labels
good first issue Good for newcomers

Comments

@ebolisa
Copy link

ebolisa commented May 20, 2021

Hi,
Testing the library code (no changes made) on a Pico board and getting pretty much a linear output.
What is possible wrong?
TIA

Cap

@n-elia
Copy link
Owner

n-elia commented May 20, 2021

Hi ebolisa!
First of all, let me know which is your particular board, and which is your sensor (the original Maxim, or a clone?).
Then, please try to scale the y-axis, e.g., plot the Columna B only with an y-axis ranging from 18000 to 22000.
Thank you!

@ebolisa
Copy link
Author

ebolisa commented May 20, 2021

Thanks for getting back to me.
I'm using the Raspberry Pi Pico and the sensor board may be a clone: https://www.pantechsolutions.net/max30102-pulse-oximeter-heart-rate-sensor-module-i2c-interface.
As for the graph, I'm using OpenOffice and I don't control it that well so I'm attaching some raw data.
data.csv
Cap
EDIT:
Updated sensor's link.

@ebolisa
Copy link
Author

ebolisa commented May 20, 2021

Ok, Made progress. Had a crash course on Calc.
But how do I output in a range from 0 to 100% for Oxy. And < 200 for HR?
TIA
Cap

@n-elia
Copy link
Owner

n-elia commented May 20, 2021

You're very welcome.

So, as I could see in your link, this is a MAX30100, so I am not sure that this library will work. However, we can further investigate. Let's check something:

  1. The csv that you posted contains 26 points only. if I remember well, with the default settings, the sensor will provide 50 samples per second, therefore you should plot at least 200 samples (4 seconds) to see an heart signal that makes sense.
  2. You can easily check the acquisition frequency with the code proposed in the readme; please make sure to have at least 50Hz
# Get the estimated acquisition rate
acquisition_rate = sensor.getAcquisitionFrequency()
  1. How are you logging data? Is it fast enough to get all the samples?

Let me know!

@n-elia
Copy link
Owner

n-elia commented May 20, 2021

Nice to see that it works well!

You have to do some math to obtain SpO2 and HR. I put some hints in the last lines of the readme, here.

Please share your code if you manage to perform those computations locally, I am interested, too!

@ebolisa
Copy link
Author

ebolisa commented May 20, 2021

Sorry, I posted the wrong sensor's link so, I updated my post.

@ebolisa
Copy link
Author

ebolisa commented May 20, 2021

Will do. Thanks again.

@n-elia
Copy link
Owner

n-elia commented May 20, 2021

Fine! Then, I'm going to close this issue.

Please feel free to open a topic in the "Discussion" section if you want to look for help for implementing HR/SPO2 evaluation, or if you want to share some progresses.

Bye,
Nicola

@n-elia n-elia closed this as completed May 20, 2021
@n-elia n-elia self-assigned this May 20, 2021
@n-elia n-elia added the good first issue Good for newcomers label May 20, 2021
Repository owner locked and limited conversation to collaborators Jul 17, 2021

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants