Go Down

Topic: Melexis mlx90615 (Read 4191 times) previous topic - next topic


Hi... I am having difficulty reading the mlx90615 sensor... Nothing I do seems to produce output.  (P.S. I'm wiring it the same way as was described for the 90614.)  I'm using 2 different duemilanove just to make sure either one works - with arduino v18. I also have 2 90615 sensors.

For wiring, I'm using 4.7k pullup resistors on mlx90615 leads 1 and 2 going to analog pins 5 & 4, a cap across the 2 leads 3 & 4), and using the 3.3v supply from the duemilanove. Grounds are tied.

I'm using the sample code and library from Fluery - i2cmaster, but after the setup up, it stalls after executing  i2c_rep_start(dev+I2C_READ);

Has anyone been able to get this to work - and/or can help guide to me to solve this perplexing problem.  I would really appreciate it.


Shoot - I just read the mlx90615 datasheet and they changed the pins!!!

So I rewired the thing:
mlx90615 lead 1 -> sda pin4
                       -> 4.7k -> 3.3v
              lead 2 -> .1uf -> grnd
              lead 3 -> scl pin5
                       -> 4.7k -> 3.3v
              lead 4 -> vss/3.3v

Still stuck at init...


check out this site for me it worked  http://wiki.wiring.co/wiki/Connecting_Infrared_Thermometer_MLX90614_to_Wiring/es


code plsss ? where is the code ?


Feb 04, 2015, 11:22 am Last Edit: Feb 04, 2015, 11:25 am by beach986
Hi, i have problem with mlx90615 sensor and Arduino uno. The reading in output from the sensor is always the same. I think I have some problem with the I2C but I'm not sure.
Here is the code that I implement:

#include <i2cmaster.h>

void setup()
i2c_init(); //Initialise the i2c bus
Serial.println("Return from i2c_init");
PORTC = (1 << PORTC4) | (1 << PORTC5);//enable pullups
void loop()
double tempFactor = 0.02; // 0.02 degrees per LSB
double tempData = 0x0000;
int frac;
float celcius=0;
int dev = 0x00<<1;
int data_low = 0;
int data_high = 0;
int pec = 0;
data_low = i2c_readAck(); //Read 1 byte and then send ack
data_high = i2c_readAck(); //Read 1 byte and then send ack
pec = i2c_readNak();

// This masks off the error bit of the high byte, then moves it left 8 bits and adds the low byte.
tempData = (double)(((data_high & 0x007F) << 8 )+ data_low);
tempData = (tempData * tempFactor)-0.01;
tempData = tempData - 273.15;// Temperatura in gradi Celsius
//float fahrenheit = (celcius*1.8) + 32;
Serial.print((int)tempData); //Print temp in degrees C to serial


Is there anyone who can give me some advice about the error?

Attached the i2c library that currently I use.


Try this new library just posted to the Playground http://playground.arduino.cc/Code/MLX90614
This uses the Wire library. See example code for useage.


I am working on a project that uses the Melexis mlx90615 sensor and an Arduino UNO R3. I was wondering if anyone here has actually been able to use this sensor with the Uno, and if they have any sample code or libraries they could share. We have searched many forums and tried modifying a few libraries that say they are for mlx90614 with no luck. We have little experience with these kinds of libraries, so any help is appreciated.

Thanks and best wishes

Go Up