Hi All,
I'm fully new to Arduino, I just got an Arduino UNO R3 and bought a HDC1008 temperature/humidity sensor to get startet. (GitHub - watterott/HDC100X-Breakout: Breakout with TI HDC1000 or HDC1008 Humidity and Temperature Sensor)
I wired the breakout board to GND, 3,3V and on SCL and SDA, but I did not connect the DRDY pin (No idea what that is for)
I tried to use the I2C scanner, but both did not display anything (does it take long?)
Is there another way to check if the sensor is working fine?
Did I wired the sensor correctly?
Furthermore, I found this here: https://forums.electricimp.com/discussion/3404/error-writing-16-bits-to-i2c-register-code-for-hdc1008-hdc1000-humidity-sensor-from-ti
[UPDATE]
I rewired to A4(SDA) and A5(SCL) and did not use the pins next to AREF (. Once today I had the sensor up and running, it was found as address 67 by Gammon's I2C scanner (still at 3,3V). It gave me -39° and 2,5% humidity.
Now I am not able to get it running again, the I2C scanner fails at "if (Wire.endTransmission () == 0)"
// I2C Scanner
// Written by Nick Gammon
// Date: 20th April 2011
#include <Wire.h>
void setup() {
Serial.begin (115200);
// Leonardo: wait for serial port to connect
while (!Serial)
{
}
Serial.println ();
Serial.println ("I2C scanner. Scanning ...");
byte count = 0;
Wire.begin();
Serial.println ("wire.begin");
for (byte i = 8; i < 120; i++)
{
Serial.println ("for loop");
Wire.beginTransmission (i);
Serial.println ("begin Transmission");
//delay(6.35);
if (Wire.endTransmission () == 0)
{
Serial.println ("endTransmission");
Serial.print ("Found address: ");
Serial.print (i, DEC);
Serial.print (" (0x");
Serial.print (i, HEX);
Serial.println (")");
count++;
Serial.println ("for loop");
delay (1); // maybe unneeded?
} // end of good response
Serial.println ("after IF == 1");
if (Wire.endTransmission () == 1)
{
Serial.println ("1:data too long to fit in transmit buffer");
}
if (Wire.endTransmission () == 2)
{
Serial.println ("2:received NACK on transmit of address");
}
if (Wire.endTransmission () == 3)
{
Serial.println ("3:received NACK on transmit of data");
}
if (Wire.endTransmission () == 4)
{
Serial.println ("4:other error");
}
} // end of for loop
Serial.println ("Done.");
Serial.print ("Found ");
Serial.print (count, DEC);
Serial.println (" device(s).");
} // end of setup
void loop() {}
[UPDATE - 2]
As soon as I remove the SDA and SCL (A4 and A5) pins while running the program, the scan starts and finds nothing.
Does anyone have an Idea why the I2C scan fails at that point?
thank you all