I have recently purchased an Arduino Nano 33 IOT together with two sensors:
However, so far I have not succeeded in reaching any of these two sensors. For example I connect the SHT31 sensor like this:
- +3.3V to Vin
- GND to GND
- A4 to SDA
- A5 to SCL
I have tried the default Adafruit SHT31-D example without success, the program appears to hang. I have tried a standard I2C scanner but it does not find any devices with the sensor connected. When the sensor is disconnected, it does find two devices (the IMU and something else I guess).
I believe there is something funky going on with the I2C connection of the internal sensors and the external ones but I have no idea how to troubleshoot this issue. I read some stuff about TwoWire (extern TwoWire Wire1; after the #include) but I am having a hard time figuring out if this is what I need and how to implement it.
I found these topics:
https://forum.arduino.cc/index.php?topic=639188.0
https://forum.arduino.cc/index.php?topic=658967.0
Bump, would really like to know if anybody has had similar issues or if somebody has ideas to test!
I have the same problem. I see the 2 internal I2c
I2C device found at address 0x60 !
I2C device found at address 0x6A !
but i can not see any external connected I2C device (on A4 / A5)
Any hint what can be wrong?
Same problem with the Arduino Nano 33 BLE and the Adafruit SHT31-D. If you look in the library, there is another command: reset(). Adding sht31.reset() at the end of setup fixed the problem for me with the the Adafruit SHT31test example.
Update:
That was just a fluke. Address detector sees both 0x44 and 0x45 ok. But SHT31 just doesn't work most of the time. Resetting the Nano with reset low on the SHT31 seems to work every time. SDA and SCL on the Nano have internal pullups, and the SHT31 has 10k pullups as well. Just resetting the SHT31 after resetting the Nano also fails.
Update2;
I redid portions of the Adafruit SHT31-D code with direct Wire (only Wire.h is needed) calls in a new test sketch, it works fine. I can get the temp data and status data w/o issue. Haven't checked humidity yet.
texas_reddy:
I redid portions of the Adafruit SHT31-D code with direct Wire (only Wire.h is needed) calls in a new test sketch, it works fine. I can get the temp data and status data w/o issue. Haven't checked humidity yet.
Hi Reddy, could you share your code with me so I can test it?
edit: so I just found out my silly mistake. The power bus on my breadboard has a left/right side and of course the sensors were on the other side of the bus... Works flawlessly now.