Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
6 years ago.
I2C interface for SHT1X
we have to replace the sensor Si7021 with SHT10 from Sensirion https://cdn-shop.adafruit.com/datasheets/Sensirion_Humidity_SHT1x_Datasheet_V5.pdf https://www.adafruit.com/product/1298
I do not see any I2C activity on scope when I send command using i2c.start() and i2c.stop(). i2c,write() etc..
i2c.start(); i2c.stop();
i2c.start(); i2c.write(addr); wait_ms(wait);
i = i2c.read(1) << 8; i |= i2c.read(1); i2c.read(0); i2c.stop();
Is this API deprecated?
Hi Amit,
Check the I2C api in the version of mbed you are using to determine support.
The xdot pin names for the external I2C are I2C_SDA & I2C_SCL. I want to make sure you used the correct pin names when you defined your I2C.
The mdot pinout is described here https://os.mbed.com/platforms/MTS-mDot-F411/#mdot-pinout-diagram. I want to make sure you are on the correct pins.
Lastly, I2C interfaces requires pull up resistors. Typically 10K ohm. Please make sure you provide these.
Kind regards, Leon
posted by Leon Lindenfelser 17 Apr 2018