Wiring the SparkFun Pulse OximeterSensor to an Adafruit Feather HUZZAH with ESP8266

I’ve purchased a SparkFun Pulse Oximeter and Heart Rate Sensor - MAX30101 & MAX32664 board and I’m trying to get it working with an Adafruit Feather HUZZAH with ESP8266. I have an attached PEMENOL OLED 128 x 64 Display Module connected via I2C where I’d love to display bio info goodness. The OLED display was easy to wire - but the Pulse module has two additional wiring requirements: RST and MFIO. I’ve referred to both the SparkFun Pulse Oximeter and Heart Rate Monitor Hookup Guide and I’m using the sample program available https://github.com/sparkfun/SparkFun_Bi … _Mode1.ino on the github repo.

I’m not sure what I’m missing. BTW, I did use a multi-meter to check wiring connectivity. All good there.

Here’s the pinout to the Adafruit board I’m using:

https://cdn-learn.adafruit.com/assets/a … 1504885873

Hi cjus.

I don’t have a Huzzah here to test with, but this board works just fine with our ESP8266 Thing Dev board so it should work with the Huzzah.

Have you tried connecting RST and MFIO to physical pins 4 and 5 on the Huzzah? You will need to consult your diagram as the pins on the actual board are not labeled 4 and 5.

Chris thanks for the reply. I haven’t tried pins 4 and 5 because I’m using them for SCL and SDA for I2C.

Look at the physical pin labels in your diagram, not the silkscreen on the board.

Thanks Chris. I tried going by the physical pin labels rather than the silkscreen ones. No luck there either.

So I decided to connect the sensor to a basic Arduino Uno. See attached photo.

In the photo above I also tried using I2C using the two upper left pins.

So even this basic test doesn’t seem to work either. I received errorcode 254. I’m beginning to suspect I have a bad board. I’m happy to eat the costs and order another - but can you post a known basic setup (wiring) which does’t use QWIIC?

Give this a try on your Uno, it works for me.

Board - Uno

MFIO → D5

RST → D4

SCL → SCL

SDA → SDA

3V3 → 3.3V (Do NOT connect to 5V, that will damage the board.)

GND → GND

Chris thanks for the diagram! I wired up the same - trying to use the same wire colors for visual reference.

I tested with both the Example1_config_BPM_Mode1 and Example2_config_BPM_Mode2 sample programs.

In both cases I get the following error.

14:44:51.517 → Sensor started!

14:44:51.517 → Configuring Sensor…

14:44:51.587 → Error configuring sensor.

14:44:51.587 → Error: 254

14:44:51.587 → Loading up the buffer with data…

If the board were damaged would the code still return error 254? Also, if I end up having to purchase another board is there a way for me to rush delivery?

example2.png

Chris, also what version of the sample program are you using to test?

Is there a chance I’m using the wrong library?

I’m using the library right out of our hookup guide, and the example code I was using was the first example that comes with that library. (Example_1_config_BPM_Mode1)

Error 254 isn’t defined and I don’t know what it is supposed to mean.

Can you send a photo of the bottom of your board and your invoice/order number?

The board I’m working with in this post is the first one I ordered:

Order number: 5915008

Order date: Tuesday, January 14, 2020

I also ordered a second board in case there was an issue with the first. That order number is:

Order number: 5915042

Date shipped: Monday, January 20, 2020

Shipping method: FedEx 2Day

Shipped by: SparkFun - CO

boardside1.png

boardside2.png

Actually it was your solder joints I was wanting to see.

Does the second board work OK or do you get the same results?

I took a look at the solder joints - under a microscope - and can see a less than perfect solder. I did do a conductivity test using a multimeter so I didn’t really suspect the solder as being an issue. I’ll clean up the solder joints later today - also the new board should arrive today so I’ll check on that one too. In the meantime I did have some luck with a “Heart Rate Click GY-MAX30102 Sensor Optical Heart-Rate Monitor Module for Arduino” so that has helped me with my immediate demo needs.

The new sensor arrived today. So I soldered headers and ran a quick test. Works like a charm!

I re-soldered the headers on the earlier board and it now runs but returns a body.status code of 16 and Heartrate and Oxygen remain at zero.

Thoughts?

oh and I forgot to mention that the older device the proximity sensor doesn’t seem active since it doesn’t turn on when my finger approaches the sensor.

Glad the new one works, but I’m not sure what’s causing you trouble with the old one. Since the symptoms change after re-soldering the joints, I’m thinking something with the soldering may be causing the trouble. You might try cleaning any solder residue off the board with some 99% isopropyl alcohol and see if that clears things up. Make sure the board is completely dry before applying power again though.

OK, I had the same “254” error on a SparkFun Redboard Turbo with the Pulse Oximeter.

My workaround fix was to increase one of the initialization delays.

So in Sparkrun_Bio_Sensort_Hub_Library.h I changed this line to get things working…

#define ENABLE_CMD_DELAY 90 // was 45 Milliseconds

The RedBoard Turbo also has some other quirks: To get the standard examples working I added at the top …

#define Serial SerialUSB

to get past the linker error (The RedBoard Turbo has a few serial ports, none are named Serial).

And then, after initializing the Serial device, you need to delay(1000): if you immediately print “Hello, World!” it gets lost somewhere. So it was only after I did that that the Error 254 appeared, and I could start tracking. Faster processors seem to be tripping up the library.

I’d be interested to know if this fixes other 254 errors.

Peter

YES! That fixed mine. Thank you so much for sharing that solution! I’m using a Aruino Mega 2560 and I’ve been searching forever for a way to get around that 254 error. I seem to get some 0 values from time to time but finally I’m able to receive sensable values at all.