Thanks for the advice Robert, I purchased the logic level converter and finally got it connected earlier today. I ran the I2C scanner tool on the sensor and got a hit at 0X10 address.
When i run the below code, i get the values 87,232,103,29 on the serial monitor. What i find strange is blowing gently on the sensor does not cause any data value variation, which leads me to believe its bogus data, is that a correct assumption ?
Is this just a timing issue, advice ?
Thanks,
Pete
#include "Wire.h"
#define addrs 0x10 // I2C bus address
void setup()
{
Wire.begin();
Serial.begin(9600);
}
void loop()
{
byte lobyte;
byte hibyte;
Wire.requestFrom(addrs, 4); // contents of your first four registers
while(Wire.available() < 4 ); // Check for data from slave
{
delay(5000);
lobyte = Wire.read(); // Read hum high byte
Serial.println(lobyte, DEC);
hibyte = Wire.read(); // Read hum low byte
Serial.println(hibyte, DEC);
// Hum = toHumidity(hibyte, lobyte);
// Serial.print("Humidity: ");
// Serial.println(Hum);
lobyte = Wire.read(); // Read temp high byte
Serial.println(lobyte, DEC);
hibyte = Wire.read(); // Read temp low byte
Serial.println(hibyte, DEC);
// Temp= toTemperature(hibyte, lobyte);
// Serial.print("Temperature: ");
// Serial.println(Temp);
delay(1000);
}
}