i used an ic2 scanner to verify the module is functional, and it says:
"17:10:45.780 -> Scanning...
17:10:45.780 -> I2C device found at address 0x57 !
17:10:45.780 -> done"
however, when i plug it into the sparkfun libraries example sketch, it is not recognized. is there any way to fix this?
- Please read How to get the best out of this forum
- Post your sketch.
RV mineirin
#include <Wire.h>
#include "MAX30105.h"
MAX30105 particleSensor;
#define debug Serial //Uncomment this line if you're using an Uno or ESP
//#define debug SerialUSB //Uncomment this line if you're using a SAMD21
void setup()
{
debug.begin(9600);
debug.println("MAX30105 Basic Readings Example");
// Initialize sensor
if (particleSensor.begin() == false)
{
debug.println("MAX30105 was not found. Please check wiring/power. ");
while (1);
}
particleSensor.setup(); //Configure sensor. Use 6.4mA for LED drive
}
void loop()
{
debug.print(" R[");
debug.print(particleSensor.getRed());
debug.print("] IR[");
debug.print(particleSensor.getIR());
debug.print("] G[");
debug.print(particleSensor.getGreen());
debug.print("]");
debug.println();
}
keeps saying not recogized. maybe becuse i am using mega and not the regular arduino uno
Which arduino/ESP are you using?
i am using arduino mega 2560.
Replace this line :
if (particleSensor.begin() == false)
with this one:
if (!particleSensor.begin(Wire, I2C_SPEED_FAST)) //Use default I2C port, 400kHz speed
i'm sorry but it says it is not found. the sensor board did not flash either
This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.